PyANGKernel.GKFilePath¶
- class GKFilePath¶
A path of the filesystem. Can be a directory path or a path + filename. Relative (to the project folder) and absolute paths are supported.
Synopsis¶
Methods¶
def
__init__()def
exists()def
fileName()def
getModel()def
getProjectPath()def
isAbsolute()def
isEmpty()def
isRelative()def
mkpath()def
path()def
setPath()def
string()def
toAbsolutePath()def
toRelativePath()
Note
This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE
- __init__()¶
- __init__(model, path)
- Parameters:
model –
GKModelpath – str
Returns true if the file path exists.
Returns the name of the file, excluding the path.
Returns the file name and path as an absolute path. @remark If the path is relative, it will be interpreted as relative to the Project folder.
Returns the model.
Return the path of the Project folder.
Returns true if the path is absolute.
Check if the path is empty.
Returns true if the path is inside the Project folder or if it’s relative.
Returns true if the path is relative.
Creates the directory and all parent directories. * @arg isFile true to interpret the text after the last separator (/) as the name of a file, not a folder. * @return true if the directory path exists at the end of the call, false otherwise.
Returns the file’s path. This doesn’t include the file name.
See also
- setPath(path)¶
- Parameters:
path – str
Set the model and path. * @remark The model needs to have been set before.
See also
- setPath(model, path)
- Parameters:
model –
GKModelpath – str
Set the model and path.
Returns the file name, including the path (which may be absolute or relative).
- toAbsolutePath()¶
Changes the path to an absolute path.
Changes the path to a relative path if it’s inside the Project folder. * @return true if successful, false otherwise.