Package concurrent_tree_crawler :: Package common :: Module resources :: Class Resources
[hide private]
[frames] | no frames]

Class Resources

source code

Static Methods [hide private]
 
open(_name_, relative_file_path)
Safe way of accessing the resource file (it will work even in code enclosed in *.egg/*.zip package)
source code
 
path(_file_, relative_path)
*Unsafe* way of getting path to a resource (dir/file) - it won't work inside code enclosed in *.egg/*.zip package
source code
Method Details [hide private]

open(_name_, relative_file_path)
Static Method

source code 

Safe way of accessing the resource file (it will work even in code enclosed in *.egg/*.zip package)

Parameters:
  • _name_ - __name__ variable (of the calling module)
Returns:
file-like object

path(_file_, relative_path)
Static Method

source code 

*Unsafe* way of getting path to a resource (dir/file) - it won't work inside code enclosed in *.egg/*.zip package

Parameters:
  • _file_ - __file__ variable of calling module
Returns:
absolute-like path to given resource