Method | Description | |
---|---|---|
__construct ( $name, |
||
delete ( $id ) | ||
getAllFiles ( ) : array | Get an array containing the path of all files in this repository | |
getFilename ( string $id ) : string | Gets just the filename for a document based on it's ID. | |
getPathForDocument ( string $id ) : string | Get the filesystem path for a document based on it's ID. |
Method | Description | |
---|---|---|
getFilesRecursive ( $dir, array &$result, $ext ) | ||
getIdFromPath ( $path, $ext ) | ||
isNestedId ( $id ) | ||
validateId ( string $id ) : boolean | Checks to see if a document ID is valid | |
write ( $path, $contents ) |
public getAllFiles ( ) : array | ||
return | array | An array, item is a file path. |
public getFilename ( string $id ) : string | ||
$id | string | The ID of the document. |
return | string | The filename of the document, including extension. |
protected getFilesRecursive ( $dir, array &$result, $ext ) | ||
$result | array |
public getPathForDocument ( string $id ) : string | ||
$id | string | The ID of the document. |
return | string | The full filesystem path of the document. |
protected validateId ( string $id ) : boolean | ||
$id | string | The ID to check |
return | boolean | True if valid, otherwise false |