Adobe InCopy CS5 (7.0) Object Model JS: XMLInstruction

InCopy CS5

Class

XMLInstruction

 An XML processing instruction. Base Class: XMLItem

QuickLinks

addEventListener, duplicate, getElements, move, remove, removeEventListener, select, toSource, toSpecifier

Hierarchy

Document | XMLElement
XMLItem
XMLInstruction
Event | EventListener | MutationEvent

Properties

PropertyTypeAccessDescription
datastring r/wA value that tells the application reading the exported XML file what to do with the processing instruction.
eventListenersEventListeners readonlyA collection of event listeners.
eventsEvents readonlyA collection of events.
idnumber readonlyThe unique ID of the XMLInstruction.
indexnumber readonlyThe index of the XMLInstruction within its containing object.
isValidbool readonlyReturns true if the object specifier resolves to valid objects.
parentDocumentXMLElement readonlyThe parent of the XMLInstruction (a Document or XMLElement).
propertiesObject r/wA property that allows setting of several properties at the same time.
storyOffsetInsertionPoint readonlyThe insertion point before the table in the story containing the table.
targetstring r/wA name that identifies the processing instruction to an application reading the exported XML file.

Methods

Instances

EventListener addEventListener (eventType: string, handler: varies[, captures: bool=false])
Adds an event listener.

ParameterTypeDescription
eventTypestringThe event type.
handlerFile
JavaScript Function
The event handler. Can accept: File or JavaScript Function.
capturesboolThis parameter is obsolete. (Optional) (default: false)

XMLInstruction duplicate ()
Duplicates the XMLInstruction.

Array of XMLInstruction getElements ()
Resolves the object specifier, creating an array of object references.

XMLInstruction move (to: LocationOptions[, reference: varies])
Moves the element to the specified location.

ParameterTypeDescription
toLocationOptions:
LocationOptions.BEFORE
LocationOptions.AFTER
LocationOptions.AT_END
LocationOptions.AT_BEGINNING
LocationOptions.UNKNOWN
The location in relation to the reference object or within the containing object.
referenceText
XMLItem
The reference object. Note: Required when the to parameter specifies before or after. . Can accept: XMLItem or Text. (Optional)

void remove ()
Deletes the XMLInstruction.

bool removeEventListener (eventType: string, handler: varies[, captures: bool=false])
Removes the event listener.

ParameterTypeDescription
eventTypestringThe registered event type.
handlerFile
JavaScript Function
The registered event handler. Can accept: File or JavaScript Function.
capturesboolThis parameter is obsolete. (Optional) (default: false)

void select ([existingSelection: SelectionOptions=SelectionOptions.REPLACE_WITH])
Selects the object.

ParameterTypeDescription
existingSelectionSelectionOptions:
SelectionOptions.ADD_TO
SelectionOptions.REMOVE_FROM
SelectionOptions.REPLACE_WITH
The selection status of the XMLInstruction in relation to previously selected objects. (Optional) (default: SelectionOptions.REPLACE_WITH)

string toSource ()
Generates a string which, if executed, will return the XMLInstruction.

string toSpecifier ()
Retrieves the object specifier.

Used in:

XMLInstruction XMLInstructions.nextItem (obj: XMLInstruction)

XMLInstruction XMLInstructions.previousItem (obj: XMLInstruction)

Return

XMLInstruction XMLInstruction.duplicate ()

Array of XMLInstruction XMLInstruction.getElements ()

XMLInstruction XMLInstruction.move (to: LocationOptions[, reference: varies])

XMLInstruction XMLInstructions.[] (index: number)

XMLInstruction XMLInstructions.add (target: string[, data: string=][, storyOffset: varies][, withProperties: Object])

XMLInstruction XMLInstructions.anyItem ()

Array of XMLInstruction XMLInstructions.everyItem ()

XMLInstruction XMLInstructions.firstItem ()

XMLInstruction XMLInstructions.item (index: varies)

XMLInstruction XMLInstructions.itemByID (id: number)

Array of XMLInstruction XMLInstructions.itemByRange (from: varies, to: varies)

XMLInstruction XMLInstructions.lastItem ()

XMLInstruction XMLInstructions.middleItem ()

XMLInstruction XMLInstructions.nextItem (obj: XMLInstruction)

XMLInstruction XMLInstructions.previousItem (obj: XMLInstruction)

Jongware, 23-Mar-2011 v3.0.3dContents :: Index