Isomet Modular Synthesiser (iMS) API
v1.4.2
iMS API
|
Provides a mechanism for viewing the FileSystemTable associated with an iMS System. More...
#include <include\FileSystem.h>
Public Member Functions | |
Constructor | |
FileSystemTableViewer (const IMSSystem &ims) | |
Constructor for FileSystemTableViewer Object. More... | |
FileSystem Table Information | |
const bool | IsValid () const |
Indicates whether FileSystemTable object is valid. More... | |
const int | Entries () const |
Array operator for random access to FileSystemTableEntry s | |
const FileSystemTableEntry | operator[] (const std::size_t idx) const |
The FileSystemTable consists of a container of FileSysteTableEntry objects. Each object may be accessed by calling the viewer object through an array subscript. More... | |
Friends | |
LIBSPEC std::ostream & | operator<< (std::ostream &stream, const FileSystemTableViewer &) |
Stream operator overload to simplify debugging. More... | |
Provides a mechanism for viewing the FileSystemTable associated with an iMS System.
|
inline |
Constructor for FileSystemTableViewer Object.
The FileSystemTableViewer object requires an IMSSystem object, which will have had its FileSystemTable read back during initialisation. It must therefore exist before the FileSystemTableViewer object, and must remain valid (not destroyed) until the FileSystemTableViewer object itself is destroyed.
Once constructed, the object can neither be copied or assigned to another instance.
[in] | ims | A const reference to the iMS System whose FileSystemTable is to be viewed. |
const int iMS::FileSystemTableViewer::Entries | ( | ) | const |
const bool iMS::FileSystemTableViewer::IsValid | ( | ) | const |
Indicates whether FileSystemTable object is valid.
For a FileSystemTable stored on the Synthesiser to be considered valid, certain parameters need to be met. If the initialisation process is unable to establish validity of a FileSystemTable it will mark it as void and the user will not be able to work with it until a new FileSystem has been created and downloaded.
User code should therefore check that the FileSystemTable is valid before working with it.
const FileSystemTableEntry iMS::FileSystemTableViewer::operator[] | ( | const std::size_t | idx | ) | const |
The FileSystemTable consists of a container of FileSysteTableEntry objects. Each object may be accessed by calling the viewer object through an array subscript.
For example:
|
friend |
Stream operator overload to simplify debugging.
Example usage:
might produce the result:
where The index into the FileSystemTable (FST) is given followed by an asterisk if the entry is marked as Default (Execute on startup). Then the File Type is given (refer to FileSystemTypes), followed by the starting address in memory then the number of bytes occupied and finally the allocated filename.