VMime
|
Public Types | |
typedef utility::path | path |
typedef unsigned long | length_type |
Public Member Functions | |
virtual | ~file () |
virtual void | createFile ()=0 |
virtual void | createDirectory (const bool createAll=false)=0 |
virtual bool | isFile () const =0 |
virtual bool | isDirectory () const =0 |
virtual bool | canRead () const =0 |
virtual bool | canWrite () const =0 |
virtual length_type | getLength ()=0 |
virtual const path & | getFullPath () const =0 |
virtual bool | exists () const =0 |
virtual shared_ptr< file > | getParent () const =0 |
virtual void | rename (const path &newName)=0 |
virtual void | remove ()=0 |
virtual shared_ptr< fileWriter > | getFileWriter ()=0 |
virtual shared_ptr< fileReader > | getFileReader ()=0 |
virtual shared_ptr< fileIterator > | getFiles () const =0 |
Protected Member Functions | |
file () | |
Protected Member Functions inherited from object | |
object () | |
object (const object &) | |
object & | operator= (const object &) |
virtual | ~object () |
Abstract representation of a file or directory.
typedef unsigned long length_type |
typedef utility::path path |
|
virtual |
|
protected |
|
pure virtual |
Test whether this file is readible.
|
pure virtual |
Test whether this file is writeable.
|
pure virtual |
Create the directory pointed by this file object.
createAll | if set to true, recursively create all parent directories if they do not exist |
exceptions::filesystem_exception | if an error occurs |
|
pure virtual |
Create the file pointed by this file object.
exceptions::filesystem_exception | if an error occurs |
|
pure virtual |
Test whether this file/directory exists.
|
pure virtual |
Return an object capable of reading from this file.
|
pure virtual |
Enumerate files contained in this directory.
exceptions::not_a_directory | if this is not a directory, exceptions::filesystem_exception if another error occurs |
|
pure virtual |
Return an object capable of writing to this file.
|
pure virtual |
Return the full path of this file/directory.
Referenced by courierMaildirFormat::isSubfolderDirectory(), and kmailMaildirFormat::isSubfolderDirectory().
|
pure virtual |
Return the length of this file.
|
pure virtual |
Return the parent directory of this file/directory.
|
pure virtual |
Test whether this is a directory.
Referenced by courierMaildirFormat::isSubfolderDirectory(), and kmailMaildirFormat::isSubfolderDirectory().
|
pure virtual |
Test whether this is a file.
|
pure virtual |
Deletes this file/directory.
If this is a directory, it must be empty.
exceptions::filesystem_exception | if an error occurs |
|
pure virtual |
Rename the file/directory.
newName | full path of the new file |
exceptions::filesystem_exception | if an error occurs |