void CosDictXAPMetadataDidChangeProc(CosObj dict, ASText newMetadata, void *data);
dict | The Cos dictionary or stream representing an object whose describing XMP metadata has changed.
|
newMetadata | A serialized representation of the new describing XMP metadata You do not own this.
|
data | Notification data provided at notification registration time.
|
void PDDocXAPMetadataDidChangeProc(PDDoc pdDoc, ASText newMetadata, void *data);
pdDoc | The PDDoc whose describing XMP metadata has changed.
|
newMetadata | A serialized representation of the new describing XMP metadata. You do not own this.
|
data | Notification data provided at notification registration time.
|
void PDEContainerXAPMetadataDidChangeProc(PDEContainer container, ASText newMetadata, void *data);
container | The PDEContainer representing a marked content sequence whose describing XMP metadata has changed.
|
newMetadata | A serialized representation of the new describing XMP metadata You do not own this.
|
data | Notification data provided at notification registration time.
|
metadataASText. The ASText returned becomes the property of the client, which is free to alter or destroy it. Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
ASBool CosDictGetXAPMetadata(IN CosObj obj, OUT ASText *metadataASText);
obj | A dictionary or stream CosObj.
|
metadataASText | (Filled by the method) The ASText object from which the XMP metadata will be obtained.
|
true if obj has associated XMP metadata, false if it does not. It also returns false if obj is not a dictionary or stream. It returns true exactly when the Cos object obj has XMP metadata. Sets the XMP metadata associated with a Cos dictionary or stream. It replaces the XMP metadata associated with the Cos object obj with the XMP metadata stored in metadataASText.
The contents of metadataASText must be well-formed XML and Resource Description Format (RDF), as defined by the W3C (see http://www.w3.org/RDF), that also forms valid XMP. CosDictSetXAPMetadtata() will not destroy metadataASText or alter its text.
Note: CosDictSetXAPMetadtata() will raise an exception if the user does not have permission to change the document.
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
void CosDictSetXAPMetadata(IN CosObj obj, IN ASText metadataASText);
obj | The dictionary or stream Cos object whose associated XMP metadata is to be set.
|
metadataASText | The ASText object containing the metadata to be associated with
obj. |
Note: XMP properties can have an XML substructure; this method can only set a value for simple textual properties.
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
ASInt32 PDDocCountXAPMetadataArrayItems(PDDoc pdDoc, ASText namespaceName, ASText path);
pdDoc | The document containing the metadata.
|
namespaceName | The XML namespace URI for the schema in which the property is to be found.
|
path | The name of the simple property to be modified.
|
Gets the value of a key in a document's Info dictionary, or the value of this same key in the XMP metadata, whichever is later. However, it is preferable to use PDDocGetXAPMetadataProperty(), because it also allows accessing XMP properties that are not duplicated in the Info dictionary.
See the description of the Document Information Dictionary in the ISO 32000-1:2008, Document Management-Portable Document Format-Part 1: PDF 1.7, section 14.3.3, page 549.
You can find this document on the web store of the International Standards Organization (ISO).
All values in the Info dictionary should be strings; other data types such as numbers and booleans should not be used as values in the Info dictionary.
Users may define their own Info dictionary entries. In this case, it is strongly recommended that the key have the developer's prefix assigned by the Adobe Solutions Network.
Note: This text is stored in either PDFDocEncoding or in Unicode. If it is stored in Unicode, a valid Byte Order Mark must be present.
ASInt32 PDDocGetInfo(PDDoc doc, const char *infoKey, char *buffer, ASInt32 bufSize);
doc | The document whose Info dictionary key is obtained.
|
infoKey | The name of the Info dictionary key whose value is obtained.
|
buffer | (Filled by the method) The buffer containing the value associated with
infoKey. If buffer is NULL, the method will just return the number of bytes required. |
bufSize | The maximum number of bytes that can be written into
buffer. |
buffer is NULL, it returns the number of bytes in the specified key's value. If buffer is not NULL, it returns the number of bytes copied into buffer, excluding the terminating NULL. You must pass at least the length + 1 as the buffer size since the routine adds a '\\0' terminator to the data, even though the data is not a C string (it can contain embedded '\\0' values). void PDDocGetInfoASText(PDDoc doc, const ASText key, ASText value);
doc | The document whose Info dictionary key is obtained.
|
key | The name of the Info dictionary key whose value is obtained.
|
value | (Filled by the method) The text object containing the value associated with
key. The client must pass a valid ASText object value. The routine does not allocate it. |
Yields an ASText containing a semicolon-separated list of fields. The first such field is the entire contents of the pdf:Keywords property of the document XMP; the remaining fields are the contents of successive items in the xmp:Keywords bag of keyword items.
The document's metadata is not modified as a result of this call.
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
ASText PDDocGetMergedXAPKeywords(PDDoc pdDoc);
pdDoc | The document containing the metadata from which to extract the merged list of keywords.
|
Gets the XMP metadata associated with a document. It returns an ASText whose text is the XML text of the XMP metadata associated with the document pdDoc. The ASText becomes the property of the client, which is free to alter or destroy it.
The XMP metadata returned always represents all the properties in the pdDoc object's Info dictionary, and can also contain properties not present in the Info dictionary. This call is preferred to PDDocGetInfo(), which only returns properties that are in the Info dictionary (although the older function is supported for compatibility).
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
ASText PDDocGetXAPMetadata(IN PDDoc pdDoc);
pdDoc | The document containing the metadata.
|
pdDoc. The ASText object becomes the property of the client, which is free to alter or destroy it. Note: XMP properties can have an XML substructure; this method can only retrieve values from simple textual properties.
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
ASText PDDocGetXAPMetadataArrayItem(PDDoc pdDoc, ASText namespaceName, ASText path, ASInt32 index);
pdDoc | The document containing the metadata.
|
namespaceName | The XML namespace URI for the schema in which the property is to be found.
|
path | The name of the desired simple property.
|
index | The index in the metadata property array associated with the property.
|
pdDoc, or an empty ASText object if no such property is found. Gets the value of an XMP metadata property associated with a document. It returns an ASText whose text is the XML text of the value of the specified property in the XMP metadata associated with the document pdDoc. The ASText becomes the property of the client, which is free to alter or destroy it.
The XMP metadata can represent all properties in the pdDoc object's Info dictionary, as well as other properties. This call is preferred to PDDocGetInfo(), which only allows access to properties that are in the Info dictionary (although the latter is supported for compatibility).
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
ASText PDDocGetXAPMetadataProperty(PDDoc pdDoc, ASText namespaceName, ASText path);
pdDoc | The document containing the metadata.
|
namespaceName | The XML namespace URI for the schema in which the property is to be found.
|
path | The name of the desired simple property. Note that XMP properties can have an XML substructure; this method can only retrieve values from simple textual properties.
|
pdDoc, or an empty ASText if no such property is found. Causes a string produced as by PDDocGetMergedXAPKeywords() to be stored as the new value of the pdf:Keywords property, and the former value of the pdf:Keywords property to be stored as an item in the xmp:Keywords bag of keyword items.
The algorithm used to compute merged keywords lists detects the case in which the keywords lists have already been merged and makes no changes to the XMP metadata in this case.
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
void PDDocMergeXAPKeywords(PDDoc pdDoc);
pdDoc | The document containing the metadata that is to be modified to make the
pdf:Keywords and xmp:Keywords properties conform. |
Sets the value of a key in a document's Info dictionary. However, it is preferable to use PDDocSetXAPMetadataProperty(), because it also allows accessing XMP properties that are not duplicated in the Info dictionary.
See the description of the Document Information Dictionary in the ISO 32000-1:2008, Document Management-Portable Document Format-Part 1: PDF 1.7, section 14.3.3, page 549.
You can find this document on the web store of the International Standards Organization (ISO).
All values in the Info dictionary should be strings; other data types such as numbers and Boolean values should not be used as values in the Info dictionary. If an Info dictionary key is specified that is not currently in the Info dictionary, it is added to the dictionary.
Users may define their own Info dictionary entries. In this case, it is strongly recommended that the key have the developer's prefix assigned by the Adobe Developers Association.
Note: This text is stored in either PDFDocEncoding or in Unicode. If it is stored in Unicode, a valid Byte Order Mark must be present.
void PDDocSetInfo(PDDoc doc, const char *infoKey, const char *buffer, ASInt32 nBytes);
doc | The document whose Info dictionary key is set.
|
infoKey | The name of the Info dictionary key whose value is set.
|
buffer | The buffer containing the value to associate with
infoKey. |
nBytes | The number of bytes in
buffer. |
void PDDocSetInfoAsASText(PDDoc doc, const ASText infoKey, const ASText value);
doc | The document whose Info dictionary key is set.
|
infoKey | The name of the Info dictionary key whose value is set.
|
value | The text object containing the value to associate with
infoKey. |
Sets the XMP metadata associated with a document. It replaces the XMP metadata associated with the document pdDoc with the XMP metadata stored in metadataASText.
The contents of metadataASText must be well-formed XML and Resource Description Format (RDF), as defined by the W3C (see http://www.w3.org/RDF), that also forms valid XMP. If metadataASText is ill-formed, an error is raised.
The call does not destroy metadataASText or alter its text. This method copies the textual information it needs, so subsequent alteration or destruction of metadataASText does not affect the document XMP metadata.
Calling PDDocSetXAPMetadata() changes the contents of the pdDoc object's Info dictionary to reflect the values of corresponding metadata properties represented in metadataASText. The XMP metadata can also contain properties that are not reflected in the Info dictionary.
Note: This method raises an exception if the user does not have permission to change the document.
Note: If you use this method to set metadata that does not respect the requirement that aliased metadata items (such as pdf:Title and xap:Title) be equal, then the mechanism that maintains this equality when you set metadata via PDDocSetInfo() is disabled.
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
void PDDocSetXAPMetadata(IN PDDoc pdDoc, IN ASText metadataASText);
pdDoc | The document whose metadata is to be set.
|
metadataASText | An ASText object containing the metadata to be stored in the document.
|
is raised if
pdDoc is not writable. |
Note: XMP properties can have an XML substructure; this method can only set a value for simple textual properties.
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
void PDDocSetXAPMetadataArrayItem(PDDoc pdDoc, ASText namespaceName, ASText namespacePrefix, ASText path, ASInt32 index, ASText newValue);
pdDoc | The document containing the metadata.
|
namespaceName | The XML namespace URI for the schema in which the property is to be found.
|
namespacePrefix | A brief string to be used as an abbreviation when creating the XML representation of the property. This string must not be empty.
|
path | The name of the simple property to be modified.
|
index | The index in the metadata property array associated with the property.
|
newValue | The new XML text value for the property.
|
pdDoc object's Info dictionary, and can also contain properties that are not in the Info dictionary. This call is preferred to PDDocSetInfo(), which only allows access to properties that are in the Info dictionary (although the older function is supported for compatibility). Note: XMP properties can have an XML substructure; this method can only set a value for simple textual properties.
Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
void PDDocSetXAPMetadataProperty(PDDoc pdDoc, ASText namespaceName, ASText namespacePrefix, ASText path, ASText newValue);
pdDoc | The document containing the metadata.
|
namespaceName | The XML namespace URI for the schema in which the property is to be found.
|
namespacePrefix | A brief string to be used as an abbreviation when creating the XML representation of the property. This string must not be empty.
|
path | The name of the simple property to be modified.
|
newValue | The new XML text value for the property.
|
metadataASText. The ASText returned becomes the property of the client, which is free to alter or destroy it. Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
ASBool PDEContainerGetXAPMetadata(IN PDEContainer pdeContainer, OUT ASText *metadataASText);
pdeContainer | The container whose metadata is retrieved.
|
metadataASText |
true exactly when the pdeContainer has XMP metadata. pdeContainer with the XMP metadata stored in metadataASText. The contents of metadataASText must be well-formed XML and Resource Description Format (RDF), as defined by the W3C (see http://www.w3.org/RDF), that also forms valid XMP. PDEContainerSetXAPMetadtata() will not destroy metadataASText or alter its text. Note: The term XAP refers to an early internal code name for Adobe's Extensible Metadata Platform (XMP). For more information on this protocol, see the Adobe XMP specification.
void PDEContainerSetXAPMetadata(IN PDEContainer pdeContainer, IN PDDoc pdDoc, IN ASText metadataASText);
pdeContainer | The container whose metadata is set.
|
pdDoc | The document containing
pdeContainer. |
metadataASText | Well-formed XML and RDF that also forms valid XMP.
|