Save metadata
and mcols
for Annotated or Vector objects, respectively, to disk.
These are typically used inside saveObject
methods for concrete subclasses.
saveMetadata(x, metadata.path, mcols.path, ...)
String containing the path in which to save the metadata
.
If NULL
, no metadata
is saved.
String containing the path in which to save the mcols
.
If NULL
, no mcols
is saved.
Further arguments to be passed to altSaveObject
.
The metadata for x
is saved to metadata.path
, and similarly for the mcols
.
If mcols(x)
has no columns, nothing is saved by saveMcols
.
Similarly, if metadata(x)
is an empty list, nothing is saved by saveMetadata
.
This avoids creating unnecessary files with no meaningful content.
If mcols(x)
has non-NULL
row names, these are removed prior to staging.
These names are usually redundant with the names associated with elements of x
itself.
readMetadata
, which restores metadata to the object.