XMP Toolkit SDK  6.0.0
AdobeXMPCore::IMetadata_v1 Class Referenceabstract

Version1 of the interface that represents the whole xmp metadata for an asset. More...

#include <IMetadata.h>

Inheritance diagram for AdobeXMPCore::IMetadata_v1:
AdobeXMPCore::IStructureNode_v1 AdobeXMPCore::ICompositeNode_v1 AdobeXMPCore::INode_v1 AdobeXMPCommon::ISharedObject AdobeXMPCommon::IVersionable AdobeXMPCommon::IThreadSafe

Public Member Functions

virtual spcIUTF8String APICALL GetAboutURI () const =0
 Gets the about URI string for the XMP metadata. More...
 
virtual void APICALL SetAboutURI (const char *uri, sizet uriLength) __NOTHROW__=0
 Sets the about URI string for the XMP metadata. More...
 
virtual void APICALL EnableFeature (const char *key, sizet keyLength) const __NOTHROW__=0
 Enables support for a particular feature. More...
 
virtual void APICALL DisableFeature (const char *key, sizet keyLength) const __NOTHROW__=0
 Disables support for a particular feature. More...
 
- Public Member Functions inherited from AdobeXMPCore::IStructureNode_v1
virtual eNodeType APICALL GetChildNodeType (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const =0
 Gets the type of the node's child having specified namespace and name. More...
 
virtual void APICALL InsertNode (const spINode &node)=0
 Inserts a given node. More...
 
virtual spINode APICALL ReplaceNode (const spINode &node)=0
 Replaces a given node. More...
 
virtual spINode APICALL RemoveNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)=0
 Removes the node with the specified nameSpace and name. More...
 
XMP_PRIVATE spcINode GetNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const
 Gets the child of the node having specified namespace and name. More...
 
virtual spINode APICALL GetNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)=0
 
XMP_PRIVATE spcISimpleNode GetSimpleNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const
 Gets the node's child having specified name space and name as simple node. More...
 
XMP_PRIVATE spISimpleNode GetSimpleNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)
 
XMP_PRIVATE spcIStructureNode GetStructureNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const
 Gets the node's child having specified name space and name as structure node. More...
 
XMP_PRIVATE spIStructureNode GetStructureNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)
 
XMP_PRIVATE spcIArrayNode GetArrayNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const
 Gets the node's child having specified name space and name as an array node. More...
 
XMP_PRIVATE spIArrayNode GetArrayNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)
 
- Public Member Functions inherited from AdobeXMPCore::ICompositeNode_v1
virtual eNodeType APICALL GetNodeTypeAtPath (const spcIPath &path) const =0
 Get the node type specified by the path relative to the composite node. More...
 
virtual void APICALL AppendNode (const spINode &node)=0
 Appends a given node as the child of the node. More...
 
virtual void APICALL InsertNodeAtPath (const spINode &node, const spcIPath &path)=0
 Inserts a given node at the path relative to the composite node. More...
 
virtual spINode APICALL ReplaceNodeAtPath (const spINode &node, const spcIPath &path)=0
 Replaces an existing node with the given node at the path relative to the composite node.. More...
 
virtual spINode APICALL RemoveNodeAtPath (const spcIPath &path)=0
 Removes the node specified by the path relative to the composite node. More...
 
XMP_PRIVATE spcINode GetNodeAtPath (const spcIPath &path) const
 Get the node specified by the path relative to the composite node. More...
 
virtual spINode APICALL GetNodeAtPath (const spcIPath &path)=0
 
virtual spINodeIterator APICALL Iterator ()=0
 Get an iterator object to iterate over all the child nodes of the composite node. More...
 
XMP_PRIVATE spcINodeIterator Iterator () const
 
virtual sizet APICALL ChildCount () const __NOTHROW__=0
 Get the count of child nodes of the composite node. More...
 
XMP_PRIVATE spcISimpleNode GetSimpleNodeAtPath (const spcIPath &path) const
 Get a simple node specified by the path relative to the node. More...
 
XMP_PRIVATE spISimpleNode GetSimpleNodeAtPath (const spcIPath &path)
 
XMP_PRIVATE spcIStructureNode GetStructureNodeAtPath (const spcIPath &path) const
 Get a structure node specified by the path relative to the node. More...
 
XMP_PRIVATE spIStructureNode GetStructureNodeAtPath (const spcIPath &path)
 
XMP_PRIVATE spcIArrayNode GetArrayNodeAtPath (const spcIPath &path) const
 Get an array node specified by the path relative to the node. More...
 
XMP_PRIVATE spIArrayNode GetArrayNodeAtPath (const spcIPath &path)
 
- Public Member Functions inherited from AdobeXMPCore::INode_v1
virtual eNodeType APICALL GetNodeType () const =0
 Gets the node type of the node. More...
 
virtual eNodeType APICALL GetParentNodeType () const =0
 Gets the node type of the node's parent. More...
 
virtual void APICALL SetName (const char *name, sizet nameLength)=0
 Changes the local name of the node. More...
 
virtual spcIUTF8String APICALL GetName () const =0
 Gets the local name of the node. More...
 
virtual void APICALL SetNameSpace (const char *nameSpace, sizet nameSpaceLength)=0
 Changes the name space of the node. More...
 
virtual spcIUTF8String APICALL GetNameSpace () const =0
 Gets the name space of the node. More...
 
virtual spIPath APICALL GetPath () const =0
 Gets the path of the node from the root of the metadata. More...
 
virtual sizet APICALL QualifiersCount () const __NOTHROW__=0
 Gets the count of the qualifiers attached with the node. More...
 
virtual eNodeType APICALL GetQualifierNodeType (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const =0
 Gets the type of the node's qualifier having specified namespace and name. More...
 
virtual void APICALL InsertQualifier (const spINode &node)=0
 Inserts a given qualifier node. More...
 
virtual spINode APICALL ReplaceQualifier (const spINode &node)=0
 Replaces a given qualifier node. More...
 
virtual spINode APICALL RemoveQualifier (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)=0
 Removes the qualifier node with the specified nameSpace and name. More...
 
virtual bool APICALL IsArrayItem () const =0
 Indicates whether the node is a direct child of an array node. More...
 
virtual bool APICALL IsQualifierNode () const =0
 Indicates whether the node is a qualifier node. More...
 
virtual sizet APICALL GetIndex () const =0
 Returns the index of the node in case it is an array item. More...
 
virtual bool APICALL HasQualifiers () const =0
 Indicates whether the node has any qualifiers associated with it. More...
 
virtual bool APICALL HasContent () const =0
 Returns whether the node has any content or not. return A bool value indicating the presence of contents in the node apart from qualifiers. More...
 
virtual bool APICALL IsEmpty () const =0
 Returns whether the node is empty. return A bool value indicating whether the contents and qualifiers of a node are empty. More...
 
virtual bool APICALL HasChanged () const =0
 Returns the status about any change done to the node or its children or qualifiers. returns a bool value indicating whether some changes have been performed on the node or its children or qualifiers. for a simple node, true will be returned in scenarios like when the node's value or qualifiers are modified. for an array node or a structure node, true will be returned in scenarios like when the node's children or the node's qualifiers are modified. More...
 
virtual void APICALL AcknowledgeChanges () const __NOTHROW__=0
 Acknowledges that changes for the node and its children and qualifiers have been taken care of. for a simple node, changes that will be acknowledged in scenarios like when the node's value or node's qualifiers were modified. for an array node or a structure node, changes will be acknowledged in scenarios like when the node's children were or the node's qualifiers were modified. More...
 
virtual void APICALL Clear (bool contents=true, bool qualifiers=true)=0
 Clear the contents of the node. More...
 
virtual spINode APICALL Clone (bool ignoreEmptyNodes=false, bool ignoreNodesWithOnlyQualifiers=false) const =0
 Virtual copy constructor. More...
 
XMP_PRIVATE spcINode GetParent () const
 Gets the parent node of the node. More...
 
virtual spINode APICALL GetParent ()=0
 
XMP_PRIVATE spcINodeIterator QualifiersIterator () const
 
virtual spINodeIterator APICALL QualifiersIterator ()=0
 
XMP_PRIVATE spcINode GetQualifier (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const
 Gets the qualifier of the node having specified namespace and name. More...
 
virtual spINode APICALL GetQualifier (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)=0
 
XMP_PRIVATE spcISimpleNode GetSimpleQualifier (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const
 Get the node's qualifier having specified name space and name as simple node. More...
 
XMP_PRIVATE spISimpleNode GetSimpleQualifier (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)
 
XMP_PRIVATE spcIStructureNode GetStructureQualifier (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const
 Get the node's qualifier having specified name space and name as structure node. More...
 
XMP_PRIVATE spIStructureNode GetStructureQualifier (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)
 
XMP_PRIVATE spcIArrayNode GetArrayQualifier (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength) const
 Get the node's qualifier having specified name space and name as an array node. More...
 
XMP_PRIVATE spIArrayNode GetArrayQualifier (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)
 
XMP_PRIVATE spcISimpleNode ConvertToSimpleNode () const
 Converts Node to a simple node, if possible. More...
 
virtual spISimpleNode APICALL ConvertToSimpleNode ()=0
 
XMP_PRIVATE spcIStructureNode ConvertToStructureNode () const
 Converts Node to a structure node type, if possible. More...
 
virtual spIStructureNode APICALL ConvertToStructureNode ()=0
 
XMP_PRIVATE spcIArrayNode ConvertToArrayNode () const
 Converts Node to an array node type, if possible. More...
 
virtual spIArrayNode APICALL ConvertToArrayNode ()=0
 
XMP_PRIVATE spcIMetadata ConvertToMetadata () const
 Converts Node to a metadata node type, if possible. More...
 
virtual spIMetadata APICALL ConvertToMetadata ()=0
 
- Public Member Functions inherited from AdobeXMPCommon::ISharedObject
virtual void APICALL Acquire () const __NOTHROW__=0
 Called by the clients of the object to indicate that he has acquired the shared ownership of the object. More...
 
virtual void APICALL Release () const __NOTHROW__=0
 Called by the clients of the object to indicate he has released his shared ownership of the object. If this being the last client than this function should call Destroy to delete and release the memory. More...
 
- Public Member Functions inherited from AdobeXMPCommon::IVersionable
template<typename requestedInterface >
XMP_PRIVATE requestedInterface * GetInterfacePointer ()
 Get the raw pointer to an interface object implementing the requested version. More...
 
template<typename requestedInterface >
const XMP_PRIVATE requestedInterface * GetInterfacePointer () const
 Get the raw pointer to a const interface object implementing the requested version. More...
 
- Public Member Functions inherited from AdobeXMPCommon::IThreadSafe
virtual void APICALL EnableThreadSafety () const __NOTHROW__=0
 Enables the thread safety on an object. More...
 
virtual void APICALL DisableThreadSafety () const __NOTHROW__=0
 Disables the thread safety on an object. More...
 
virtual bool APICALL IsThreadSafe () const =0
 Informs whether object can be used across multiple threads or not. More...
 

Static Public Member Functions

static XMP_PRIVATE spIMetadata CreateMetadata ()
 Creates an empty IMetadata object. More...
 
- Static Public Member Functions inherited from AdobeXMPCore::IStructureNode_v1
static XMP_PRIVATE spIStructureNode CreateStructureNode (const char *nameSpace, sizet nameSpaceLength, const char *name, sizet nameLength)
 Creates a structure node which is not part of any metadata document. More...
 

Protected Member Functions

virtual ~IMetadata_v1 () __NOTHROW__
 
XMP_PRIVATE spcINode GetParent () const
 Hiding some functions from derived classes. More...
 
virtual spINode APICALL GetParent ()=0
 Hiding some functions from derived classes. More...
 
virtual spcIUTF8String APICALL GetNameSpace () const=0
 Gets the name space of the node. More...
 
virtual void APICALL SetNameSpace (const char *nameSpace, sizet nameSpaceLength)=0
 Changes the name space of the node. More...
 
virtual spcIUTF8String APICALL GetName () const=0
 Gets the local name of the node. More...
 
virtual void APICALL SetName (const char *name, sizet nameLength)=0
 Changes the local name of the node. More...
 
- Protected Member Functions inherited from AdobeXMPCore::IStructureNode_v1
virtual ~IStructureNode_v1 () __NOTHROW__
 
- Protected Member Functions inherited from AdobeXMPCore::ICompositeNode_v1
virtual ~ICompositeNode_v1 () __NOTHROW__
 
- Protected Member Functions inherited from AdobeXMPCore::INode_v1
virtual ~INode_v1 () __NOTHROW__
 
- Protected Member Functions inherited from AdobeXMPCommon::ISharedObject
virtual ~ISharedObject () __NOTHROW__=0
 
 REQ_FRIEND_CLASS_DECLARATION ()
 
- Protected Member Functions inherited from AdobeXMPCommon::IVersionable
virtual ~IVersionable ()
 
 REQ_FRIEND_CLASS_DECLARATION ()
 
- Protected Member Functions inherited from AdobeXMPCommon::IThreadSafe
 REQ_FRIEND_CLASS_DECLARATION ()
 

Additional Inherited Members

- Public Types inherited from AdobeXMPCore::INode_v1
enum  eNodeType {
  kNTNone = 0, kNTSimple = 1, kNTArray = 1 << 1, kNTStructure = 1 << 2,
  kNTAll = kAllBits
}
 Indicates various types of node available in XMP Data Model like simple, array and structure. More...
 

Detailed Description

Version1 of the interface that represents the whole xmp metadata for an asset.

Provides all the functions to add or remove nodes to and from metadata.

Attention
Support multi threading through locks but can be enabled/disabled by the client. By default every object created does not support multi-threading.

Definition at line 26 of file IMetadata.h.

Constructor & Destructor Documentation

◆ ~IMetadata_v1()

virtual AdobeXMPCore::IMetadata_v1::~IMetadata_v1 ( )
inlineprotectedvirtual

Destructor

Definition at line 126 of file IMetadata.h.

126 {}

Member Function Documentation

◆ CreateMetadata()

static XMP_PRIVATE spIMetadata AdobeXMPCore::IMetadata_v1::CreateMetadata ( )
static

Creates an empty IMetadata object.

Returns
A shared pointer to an empty #IMetadata object.

◆ DisableFeature()

virtual void APICALL AdobeXMPCore::IMetadata_v1::DisableFeature ( const char *  key,
sizet  keyLength 
) const
pure virtual

Disables support for a particular feature.

Parameters
[in]keyA const char buffer containing key for the feature.
[in]keyLengthNumber of characters in key.

◆ EnableFeature()

virtual void APICALL AdobeXMPCore::IMetadata_v1::EnableFeature ( const char *  key,
sizet  keyLength 
) const
pure virtual

Enables support for a particular feature.

Parameters
[in]keyA const char buffer containing key for the feature.
[in]keyLengthNumber of characters in key.
Note
Following keys are supported:
  • alias Enable support for aliases on the metadata object.

◆ GetAboutURI()

virtual spcIUTF8String APICALL AdobeXMPCore::IMetadata_v1::GetAboutURI ( ) const
pure virtual

Gets the about URI string for the XMP metadata.

Returns
A shared pointer to const #AdobeXMPCommon::IUTF8String object containing URI string.
Note
By default this is an empty string.

◆ GetName()

virtual spcIUTF8String APICALL AdobeXMPCore::INode_v1::GetName
protected

Gets the local name of the node.

Returns
a shared pointer to const #AdobeXMPCommon::IUTF8String representing the name of the node.

◆ GetNameSpace()

virtual spcIUTF8String APICALL AdobeXMPCore::INode_v1::GetNameSpace
protected

Gets the name space of the node.

Returns
A shared pointer to const #AdobeXMPCommon::IUTF8String representing the name space of the node.

◆ GetParent() [1/2]

XMP_PRIVATE spcINode AdobeXMPCore::INode_v1::GetParent
inlineprotected

Hiding some functions from derived classes.

Definition at line 75 of file INode.h.

75  {
76  return const_cast< INode_v1 * >( this )->GetParent();
77  }

◆ GetParent() [2/2]

virtual spINode APICALL AdobeXMPCore::INode_v1::GetParent
protected

Hiding some functions from derived classes.

◆ SetAboutURI()

virtual void APICALL AdobeXMPCore::IMetadata_v1::SetAboutURI ( const char *  uri,
sizet  uriLength 
)
pure virtual

Sets the about URI string for the XMP metadata.

Parameters
[in]uriPointer to a constant char buffer containing uri string.
[in]uriLengthNumber of characters in uri. In case name is null terminated set it to #AdobeXMPCommon::npos.

◆ SetName()

virtual void APICALL AdobeXMPCore::INode_v1::SetName
protected

Changes the local name of the node.

Parameters
[in]namePointer to a constant char buffer containing local name of the node.
[in]nameLengthNumber of characters in name. In case name is null terminated set it to #AdobeXMPCommon::npos.
Attention
Error can be thrown in case
  • name is NULL pointer or its contents are empty
  • name is not valid XML property name.
  • Sibling with the same combination of name and nameSpace is present.

◆ SetNameSpace()

virtual void APICALL AdobeXMPCore::INode_v1::SetNameSpace
protected

Changes the name space of the node.

Parameters
[in]nameSpacePointer to a constant char buffer containing name space URI of the node.
[in]nameSpaceLengthNumber of characters in nameSpace. In case nameSpace is null terminated set it to #AdobeXMPCommon::npos.
Attention
Error can be thrown in case
  • nameSpace is NULL pointer or its contents are empty
  • Sibling with the same combination of name and nameSpace is present.

The documentation for this class was generated from the following file:
AdobeXMPCore::INode_v1::GetParent
XMP_PRIVATE spcINode GetParent() const
Gets the parent node of the node.
Definition: INode.h:75