AdobeBridgeCS5SDK

Class SnpModifyMetadata

Object
   |
   +--SnpModifyMetadata

class SnpModifyMetadata


Shows how to acquire and update metadata for a selected thumbnail using XMP external object.

Usage

  1. In Bridge, select a single thumbnail that has XMP-based metadata, such as a Adobe Photoshop CS5 (PSD), Adobe PDF or Adobe InDesign CS5 (INDD) file.
  2. Run the snippet in the ExtendScript Toolkit (see Readme.txt)
  3. Inspect the Metadata panel and the File Properties section; note how the Application has been modified by this snippet.
  4. Inspect the metadata panel and the IPTC Core section; note how the Title has been modified by this snippet.
  5. Select File > File Info... > Advanced
  6. Expand the node http://ns.adobe.bridge.sdk/ and inspect the newly added metadata.
  7. Inspect the JavaScript console to view information about all modifications made by this snippet to the XMP metadata.

Description

Shows how to acquire XMP metadata for a selected thumbnail and modify the existing data. Several properties are updated using the XMPMeta object, as well as some custom properties being added, including arrays, qualifiers and structures. This snippet also demonstrates how to delete a property, delete all properties from a namespace and delete all properties from the XMPMeta object.

The selected thumbnail's metadata is collected and serialised to give the XMP packet which is used to construct a new instance of an XMPMeta object. The XMPMeta object is used to modify existing metadata as well as add custom data. After all modifications are made the XMP packet is serialized and written back to the selected thumbnail's metadata property.

To add the custom data a new namespace (http://ns.adobe.bridge.sdk/) and prefix (nssdk) is registered, the namespace and prefix have no relevance outwith the scope of this snippet. To view the newly added custom data then use the select File > File Info... > Advanced and expand the 'http://ns.adobe.bridge.sdk/' element.

Note: The selected file will have its metadata over written.

See the JavaScript Tools Guide for more details.

See:

Defined in SnpModifyMetadata.jsx


Field Summary
 String requiredContext
          The context in which this snippet can run.
 
Constructor Summary
SnpModifyMetadata()
           
 
Method Summary
 boolean canRun()
           Determines whether snippet can be run given current context.
 boolean run()
           Functional part of this snippet.

Field Detail

requiredContext

String requiredContext

Constructor Detail

SnpModifyMetadata

SnpModifyMetadata()

Method Detail

canRun

boolean canRun()

run

boolean run()

AdobeBridgeCS5SDK

http://www.adobe.com/devnet/bridge
Documentation generated by JSDoc on Tue Apr 27 10:21:34 2010