iopc::AdditionalMetadataHolder Class Reference
[iopccommon]

A MetadataHolder wrapper. More...

#include <metadataHolder.h>

Inheritance diagram for iopc::AdditionalMetadataHolder:

Inheritance graph
[legend]

List of all members.

Public Member Functions

 AdditionalMetadataHolder (const MetadataHolder &primary, bool invert=false)
virtual const MetadatagetMeta (const std::string &key, bool searchDefaults=true, bool searchSecondary=true) const
 Returns Metadata of the specified key.
virtual bool hasMeta (const std::string &key, bool searchDefaults=true, bool searchSecondary=true) const
 Asks the wrapper and the wrapped MetadataHolder instance if they contain metadata of the specified key.


Detailed Description

A MetadataHolder wrapper.

This class can be used to specify additional metadata to an existing MetadataHolder instance if we don't want to modify its contents.


Constructor & Destructor Documentation

iopc::AdditionalMetadataHolder::AdditionalMetadataHolder ( const MetadataHolder primary,
bool  invert = false 
) [inline]

Parameters:
primary The MetadataHolder instance being wrapped
invert Specifies the search order. If invert is false (by default), the wrapped instance is searched first, otherwise this wrapper is searched before the wrapped MetadataHolder.


Member Function Documentation

virtual const Metadata& iopc::AdditionalMetadataHolder::getMeta ( const std::string &  key,
bool  searchDefaults = true,
bool  searchSecondary = true 
) const [virtual]

Returns Metadata of the specified key.

Parameters:
key Key of the requested metadata
searchDefaults Allows to skip the default metadata search
searchSecondary Allows to skip the secondary location of both this wrapper and the wrapped MetadataHolder instance
Returns:
A Metadata instance found under the specified key.
Exceptions:
IopcIncorrectUsageException if no metadata of such key is found

Reimplemented from iopc::MetadataHolder.

bool iopc::AdditionalMetadataHolder::hasMeta ( const std::string &  key,
bool  searchDefaults = true,
bool  searchSecondary = true 
) const [virtual]

Asks the wrapper and the wrapped MetadataHolder instance if they contain metadata of the specified key.

Parameters:
key Key of the requested metadata
searchDefaults Allows to skip the default metadata search
searchSecondary Allows to skip the secondary location metadata search
Returns:
true - this wrapper or the wrapped MetadtaHolder instance contain the key

Reimplemented from iopc::MetadataHolder.


The documentation for this class was generated from the following files:

Generated on Tue Apr 14 16:46:35 2009 for IOPC 2 by  doxygen 1.5.6