|
Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members
PmtXmlAccessor Class ReferenceProvides access to metadata stored as XML in text files.
More...
#include <PmtXmlAccessor.h>
Inheritance diagram for PmtXmlAccessor: [legend]Collaboration diagram for PmtXmlAccessor:[legend]List of all members.
Detailed Description
Provides access to metadata stored as XML in text files.
One should never have to include this header file, nor use this interface directly. All access to this class' functionality should be through the PmtAccessor base class interface.
Constructor & Destructor Documentation
PmtXmlAccessor::PmtXmlAccessor |
( |
|
) |
[inline] |
|
virtual PmtXmlAccessor::~PmtXmlAccessor |
( |
|
) |
[virtual] |
|
Member Function Documentation
virtual PmtAccessorPtr PmtXmlAccessor::clone |
( |
|
) |
const [inline, virtual] |
|
|
This method returns a copy of the accessor.
Implements PmtAccessor. |
void PmtXmlAccessor::close |
( |
|
) |
[virtual] |
|
|
Close the file.
This is a pure virtual function that is to be implemented by the derived classes.
Reimplemented from PmtAccessor. |
virtual void PmtXmlAccessor::getMdValue |
( |
PmtMetadataPtr & |
md |
) |
[inline, protected, virtual] |
|
bool PmtXmlAccessor::open |
( |
const char * |
name, |
|
|
PmtOpenMode |
mode = PMT_READONLY |
|
) |
[virtual] |
|
|
Opens a XML text file for reading / writing (depending on the mode).
Implements PmtAccessor. |
|
Read the specified metadata from the storage format.
Reimplemented from PmtAccessor. |
|
Read all existing metadata and return a root metadata.
Reimplemented from PmtAccessor. |
bool PmtXmlAccessor::recognize |
( |
const SPmtString & |
name |
) |
const [protected, virtual] |
|
|
Used by the getAccessor() method to determine the file type.
The derived accessor classes that want to be created from the getAccessor() method should provide an implementation for this method.
Implements PmtAccessor. |
virtual void PmtXmlAccessor::setMdValue |
( |
const PmtMetadataPtr & |
md |
) |
[inline, protected, virtual] |
|
bool PmtXmlAccessor::setNSPrefix |
( |
const SPmtString & |
nsPrefix |
) |
|
|
void PmtXmlAccessor::writeMetadata |
( |
const PmtMetadataPtr & |
md, |
|
|
bool |
bWriteValid = false |
|
) |
[virtual] |
|
|
Request the accessor to write the given metadata to the storage media.
The argument is a pointer to an instance of either an PmtMetadata (for a single metadata item) or an PmtCompositeMetadata (for multiple metadata items). If throwErrors() is set to false and an error occurs, one of two things will happen. First, if the write is for a single metadata, then the write will just be aborted. Second, if the write is for a composite, then the write of the current metadatum is aborted and the writing of the composite contiues with the next element. If throwErrors() is set to true, then the write operation is always aborted by throwing the error. If bWriteValid is false then only the given metadata (including its childern) will be written; otherwise, the whole metadata tree starting from the out-most parent will be written.
Reimplemented from PmtAccessor. |
Member Data Documentation
The documentation for this class was generated from the following files:
|