Path

class cgp_generic_utils.files.Path(path)

Bases: object

path object that manipulates any kind of entity on the file system

baseName(withExtension=True)

the baseName of the path

Parameters:withExtension (bool) – True : baseName with extension - False : baseName without extension
Returns:the baseName of the path
Return type:str
directory()

the parent directory of the path

Returns:the directory of the path
Return type:cgp_generic_utils.files.Directory
extension()

the extension of the path

Returns:the extension of the path
Return type:str
isDirectory()

check if the path is a directory

Returns:True : the path is a directory - False the path is not a directory
Return type:bool
isFile()

check if the path is a file

Returns:True : the path is a file - False the path is not a file
Return type:bool
path()

the path of the entity on the file system

Returns:the path of the entity
Return type:str
pathType()

the type of the path

Returns:the type of the path
Return type:str