XMLElement

An XML element.

Methods:

duplicate, exportFile, importXML, markup, move, placeXML, remove, select, untag, validate

Objects:

Characters, DTDs, EPSs, Images, InsertionPoints, Lines, Number, Object, PDFs, PICTs, PageItems, Paragraphs, SpecialCharacters, Stories, Story, String, TextColumns, TextStyleRanges, Texts, WMFs, Words, XMLAttributes, XMLComments, XMLElements, XMLInstructions, XMLItems, XMLTag

Hierarchy:

Superclass: XMLItem

Class: XMLElement

Property Listing

Property

Type

Access

Description

characters

Characters Character

readonly

A collection of characters.

contents

String

SpecialCharacters

SpecialCharacters.AUTO_PAGE_NUMBER

SpecialCharacters.BULLET_CHARACTER

SpecialCharacters.COLUMN_BREAK

SpecialCharacters.COPYRIGHT_SYMBOL

SpecialCharacters.DEGREE_SYMBOL

SpecialCharacters.DISCRETIONARY_HYPHEN

SpecialCharacters.DOUBLE_LEFT_QUOTE

SpecialCharacters.DOUBLE_RIGHT_QUOTE

SpecialCharacters.ELLIPSIS_CHARACTER

SpecialCharacters.EM_DASH

SpecialCharacters.EM_SPACE

SpecialCharacters.END_NESTED_STYLE

SpecialCharacters.EN_DASH

SpecialCharacters.EN_SPACE

SpecialCharacters.EVEN_PAGE_BREAK

SpecialCharacters.FIGURE_SPACE

SpecialCharacters.FLUSH_SPACE

SpecialCharacters.FORCED_LINE_BREAK

SpecialCharacters.FRAME_BREAK

SpecialCharacters.HAIR_SPACE

SpecialCharacters.INDENT_HERE_TAB

SpecialCharacters.NEXT_PAGE_NUMBER

SpecialCharacters.NONBREAKING_HYPHEN

SpecialCharacters.NONBREAKING_SPACE

SpecialCharacters.ODD_PAGE_BREAK

SpecialCharacters.PAGE_BREAK

SpecialCharacters.PARAGRAPH_SYMBOL

SpecialCharacters.PREVIOUS_PAGE_NUMBER

SpecialCharacters.PUNCTUATION_SPACE

SpecialCharacters.REGISTERED_TRADEMARK

SpecialCharacters.RIGHT_INDENT_TAB

SpecialCharacters.SECTION_MARKER

SpecialCharacters.SECTION_SYMBOL

SpecialCharacters.SINGLE_LEFT_QUOTE

SpecialCharacters.SINGLE_RIGHT_QUOTE

SpecialCharacters.THIN_SPACE

SpecialCharacters.TRADEMARK_SYMBOL

read/write

The contents of the text. Can return: String or SpecialCharacters enumerator.

dtds

DTDs DTD

readonly

A collection of DTDs.

epss

EPSs EPS

readonly

A collection of EPS files.

id

Number

readonly

The unique ID of the XMLElement.

images

Images Image

readonly

A collection of bitmap images in any bitmap file format (including TIFF, JPEG, or GIF).

index

Number

readonly

The index of the XMLElement within its containing object.

insertionPoints

InsertionPoints InsertionPoint

readonly

A collection of insertion points.

lines

Lines Line

readonly

A collection of lines.

markupTag

XMLTag

String

read/write

The XML tag applied to the element. Can also accept: String.

pageItems

PageItems PageItem

readonly

The page items collection, which can be used to process all page items in a container (such as a document, page, or group), regardless of type.

paragraphs

Paragraphs Paragraph

readonly

A collection of paragraphs.

parent

XMLElement

Document

XMLItem

readonly

The parent of the XMLElement (a Document, XMLElement or XMLItem).

parentStory

Story

readonly

The story that contains the text.

pdfs

PDFs PDF

readonly

A collection of PDF files.

picts

PICTs PICT

readonly

A collection of PICT graphics.

properties

Object

read/write

A property that allows setting of several properties at the same time.

stories

Stories Story

readonly

A collection of stories.

storyOffset

Number

readonly

The index of the character containing the table (from the beginning of the story).

textColumns

TextColumns TextColumn

readonly

A collection of text columns.

textStyleRanges

TextStyleRanges TextStyleRange

readonly

A collection of text style ranges.

texts

Texts Text

readonly

A collection of text objects.

wmfs

WMFs WMF

readonly

A collection of WMF graphics.

words

Words Word

readonly

A collection of words.

xmlAttributes

XMLAttributes XMLAttribute

readonly

A collection of XML attributes.

xmlComments

XMLComments XMLComment

readonly

A collection of XML comments.

xmlElements

XMLElements XMLElement

readonly

A collection of XML elements.

xmlInstructions

XMLInstructions XMLInstruction

readonly

A collection of XML instructions.

xmlItems

XMLItems XMLItem

readonly

A collection of XML items.

Method Listing

XMLElement duplicate ()

Duplicates the XMLElement.

undefined exportFile (format:Varies ExportFormat String, to:File, [showingOptions:Boolean=Boolean], using:PDFExportPreset)

Exports the object(s) to a file.

Parameter

Type

Description

format

ExportFormat

ExportFormat.EPS_TYPE

ExportFormat.INCOPY

ExportFormat.JPG

ExportFormat.PDF_TYPE

ExportFormat.RTF

ExportFormat.SVG

ExportFormat.SVG_COMPRESSED

ExportFormat.TAGGED_TEXT

ExportFormat.TEXT_TYPE

ExportFormat.XML

String

The export format. Can accept: ExportFormat enumerator or String.

to

File

The path of the export file.

showingOptions

Boolean

If true, prompts the user to select export options. (Optional)

(default: false)

using

PDFExportPreset

The export style to use. (Optional)

undefined importXML (from:File)

Imports an XML file.

Parameter

Type

Description

from

File

The path to the XML file.

undefined markup (using:Varies Story Text PageItem)

Associates the object with the specified XML element while preserving existing content.

Parameter

Type

Description

using

Story

Text

PageItem

The object to mark up. Can accept: Text, Story or PageItem.

XMLElement move (to:LocationOptions, reference:Varies XMLItem Text)

Move element before/after another element or text object, or to beginning/end

Parameter

Type

Description

to

LocationOptions

LocationOptions.AFTER

LocationOptions.AT_BEGINNING

LocationOptions.AT_END

LocationOptions.BEFORE

LocationOptions.UNKNOWN

Location

reference

XMLItem

Text

Before/after this object. Can accept: XMLItem or Text. (Optional)

undefined placeXML (using:Varies Story PageItem)

Places XML content into the story, replacing the existing content.

Parameter

Type

Description

using

Story

PageItem

The story into which to place the XML content. Can accept: Story or PageItem.

undefined remove ()

Deletes the XMLElement.

undefined select ([existingSelection:SelectionOptions=SelectionOptions])

Select this object.

Parameter

Type

Description

existingSelection

SelectionOptions

SelectionOptions.ADD_TO

SelectionOptions.REMOVE_FROM

SelectionOptions.REPLACE

How to handle the existing selection (Optional)

(default: SelectionOptions.REPLACE)

undefined untag ()

Untags an element.

ValidationError validate ([maximumErrors:Number=Number])

Validates the element against a DTD.

Parameter

Type

Description

maximumErrors

Number

The maximum number of validation errors to generate. (Optional)

(default: 250)

Object of

Document.associatedXMLElement

FormField.associatedXMLElement

Button.associatedXMLElement

Movie.associatedXMLElement

Sound.associatedXMLElement

PageItem.associatedXMLElement

Oval.associatedXMLElement

Rectangle.associatedXMLElement

GraphicLine.associatedXMLElement

Polygon.associatedXMLElement

Group.associatedXMLElement

Image.associatedXMLElement

EPS.associatedXMLElement

PDF.associatedXMLElement

WMF.associatedXMLElement

PICT.associatedXMLElement

TextFrame.associatedXMLElement

Text.associatedXMLElements

Character.associatedXMLElements

Word.associatedXMLElements

Line.associatedXMLElements

TextColumn.associatedXMLElements

Paragraph.associatedXMLElements

TextStyleRange.associatedXMLElements

InsertionPoint.associatedXMLElements

Story.associatedXMLElements

ValidationError.element

Character.parent

DTD.parent

EPS.parent

Image.parent

InsertionPoint.parent

Line.parent

PDF.parent

PICT.parent

PageItem.parent

Paragraph.parent

Story.parent

Text.parent

TextColumn.parent

TextStyleRange.parent

WMF.parent

Word.parent

XMLAttribute.parent

XMLComment.parent

XMLElement.parent

XMLInstruction.parent

XMLItem.parent

Return

XMLElements.add()

XMLElement.duplicate()

XMLElement.move()

XMLComment.move()

XMLInstruction.move()

XMLItem.move()

DTD.move()