FileNameService
Implementation of the file name service
FileNameService
Canonical path: FileNameService.FileNameService
Definition of service class FileNameService
get_filename_without_root_path
staticmethod
Cuts the root_path of the filename
Parameters:
-
str_file_name
(str
) –Full file path
-
str_path
(str
) –Root directory path
Returns:
-
str
–File path relative to the root directory
Examples:
get_global_standard_path
staticmethod
Get the absolute path from a path relative to etc/std/prj directory
Parameters:
-
local_path
(str
) –local path
Returns:
-
str
–global path (empty if not exist)
Examples:
get_lib_pyp_sricpt_path
staticmethod
Searches the file_name in the parts (Cur_proj, Std, Etc )of the library Cuts the library_path of the filename
Parameters:
-
file_name
(str
) –name of file.
Returns:
-
str
–str_file_name without lib_path
Examples:
get_pyp_path_from_lib_struct
staticmethod
get_pyp_path_from_lib_struct(file_name: str) -> tuple[bool, str]
Searches the file_name in the parts (Cur_proj, Std, Etc ) of the library.
Parameters:
-
file_name
(str
) –name of file without lib_path
Returns:
-
bool
–True when file exist state, False otherwise
-
str
–str_file_name with lib_path
Examples:
search_pyp_file
staticmethod
search_pyp_file(file_name: str) -> tuple[bool, str]
Searches the pyp file_name in all library folders in the parts (Cur_proj, Std, Etc )
Parameters:
-
file_name
(str
) –name of file without lib_path
Returns:
-
bool
–True when file exist state, False otherwise
-
str
–str_file_name with lib_path
set_node_script_default_path
staticmethod
Set the default path of the node scripts
Parameters:
-
node_script_default_path
(str
) –description