This document covers the implementation details of files and directories in BASE.
See also
The DirectoryData
class stores information about
directories. A directory may have a parent directory
which is referenced by the parent
property.
The only directory that is allowed to have no parent is the
system defined root directory. All other files must have a parent.
The FileData
class stores information about directories.
The property action
tells if the file should be moved or
brought back from secondary storage. The actual moving of the file is
done by an external program. The mime-type of the file has no connection
to the class MimeTypeData
.
The FileTypeData
class holds information about file types.
It is used only to make it easier for users to organise their files.
This class is used to register mime types and map them to
file extensions. The information is only used to lookup values when needed. Given
the filename we can set the File.mimeType and File.fileType properties.
The extension
of a mime type must be unique. Extensions should be
registered without a dot, ie html
, not .html
.