class ClassTools
Tools to support class & package inclusion and referencing.
Methods
static string |
classname(string $qualifiedName)
Gets just classname, given a dot-path to class. |
|
static string |
getFilePath(string $path, string $classname = null, string $extension = '.php')
Gets the path to be used in include()/require() statement. |
|
static string |
createFilePath(string $path, string $classname = null, string $extension = '.php')
This method replaces the `getFilePath()` method in OMBuilder as we consider `$path` as a real path instead of a dot-notation value. |
|
static string |
getBaseClass(Table $table)
Gets the baseClass path if specified for table/db. |
|
static string |
getInterface(Table $table)
Gets the interface path if specified for table. |
|
static string[] |
getPhpReservedWords()
Gets a list of PHP reserved words. |
Details
at line 28
static public string
classname(string $qualifiedName)
Gets just classname, given a dot-path to class.
at line 54
static public string
getFilePath(string $path, string $classname = null, string $extension = '.php')
Gets the path to be used in include()/require() statement.
Supports multiple function signatures:
(1) getFilePath($dotPathClass);
(2) getFilePath($dotPathPrefix, $className);
(3) getFilePath($dotPathPrefix, $className, $extension);
at line 71
static public string
createFilePath(string $path, string $classname = null, string $extension = '.php')
This method replaces the `getFilePath()` method in OMBuilder as we consider `$path` as a real path instead of a dot-notation value.
`$path` is generated by the `getPackagePath()`
method.
at line 89
static public string
getBaseClass(Table $table)
Gets the baseClass path if specified for table/db.
at line 99
static public string
getInterface(Table $table)
Gets the interface path if specified for table.
at line 109
static public string[]
getPhpReservedWords()
Gets a list of PHP reserved words.