Class to represent a file system node (directory, file etc)
More...
#include <FSNode.h>
|
|
using | Unique = std::unique_ptr<FSNode> |
| | Unique pointer.
|
| |
|
using | Shared = std::shared_ptr<FSNode> |
| | Unique pointer.
|
| |
|
|
static const utility::String | pathDelimiter |
| | The path delimiter expression for the current platform.
|
| |
Class to represent a file system node (directory, file etc)
◆ FSNode() [1/3]
◆ FSNode() [2/3]
| FSNode::FSNode |
( |
const Path & | path | ) |
|
Constructor
- Parameters
-
- Exceptions
-
| std::bad_alloc | Thrown if memory allocation fails |
◆ FSNode() [3/3]
| FSNode::FSNode |
( |
const FSNode & | source | ) |
|
|
noexcept |
Copy constructor
- Parameters
-
◆ ~FSNode()
| virtual active::file::FSNode::~FSNode |
( |
| ) |
|
|
virtualdefaultnoexcept |
◆ exists()
| virtual bool active::file::FSNode::exists |
( |
| ) |
const |
|
inlinevirtual |
Test if the node actually exists
- Exceptions
-
| std::bad_alloc | Thrown if memory allocation fails |
- Returns
- True if the node exists
◆ getModificationTime()
| utility::Time active::file::FSNode::getModificationTime |
( |
| ) |
const |
|
inline |
Get the node modification time
- Exceptions
-
| std::bad_alloc | Thrown if memory allocation fails |
- Returns
- The node modification time
◆ getPath()
| Path active::file::FSNode::getPath |
( |
| ) |
const |
|
inlinenoexcept |
Get the node path
- Returns
- The node path
◆ isDirectory()
| virtual bool active::file::FSNode::isDirectory |
( |
| ) |
const |
|
inlinevirtual |
Test if the node data points to a directory/folder
- Exceptions
-
| std::bad_alloc | Thrown if memory allocation fails |
- Returns
- True if this is a folder
◆ isMine()
| bool active::file::FSNode::isMine |
( |
| ) |
const |
|
inlineprotectednoexcept |
Determine if the node was created by this
- Returns
- True if the node was created by this
◆ moveTo()
| void FSNode::moveTo |
( |
const Path & | path | ) |
|
|
virtual |
Move/rename the node path
- Parameters
-
| path | The new path to assign to the node (moves/renames the node accordingly) |
- Exceptions
-
| std::bad_alloc | Thrown if memory allocation fails |
◆ operator=()
Assignment operator
- Parameters
-
- Returns
- A reference to this
◆ operator==()
| bool FSNode::operator== |
( |
const FSNode & | ref | ) |
const |
|
noexcept |
Equality operator
- Parameters
-
- Returns
- True if ref is identical to this
◆ remove()
| void FSNode::remove |
( |
bool | isRecursive = true | ) |
|
|
virtual |
Remove the node path
- Parameters
-
| isRecursive | True if any subnodes should also be recursively removed |
- Exceptions
-
| std::bad_alloc | Thrown if memory allocation fails |
Reimplemented in active::file::File.
◆ rename()
Rename the node (just the last part of the name, i.e. the file/directory name)
- Parameters
-
- Exceptions
-
| std::bad_alloc | Thrown if memory allocation fails |
◆ setMine()
| void active::file::FSNode::setMine |
( |
bool | state | ) |
|
|
inlineprotectednoexcept |
Set whether the node was created by this
- Parameters
-
| state | True if the node was created by this |
◆ setPath()
| void FSNode::setPath |
( |
const Path & | path | ) |
|
|
virtual |
Assign a node path (points to a new node without changing the previous node)
- Parameters
-
- Exceptions
-
| std::bad_alloc | Thrown if memory allocation fails |
The documentation for this class was generated from the following files:
- /Users/rwessel/Documents/Development/ActiveLib/Active/File/Interface/FSNode.h
- /Users/rwessel/Documents/Development/ActiveLib/Active/File/Interface/FSNode.cpp