Packagecom.adobe.indesign
Classpublic class Link
InheritanceLink Inheritance CSHostObject Inheritance flash.utils.Proxy



Public Properties
 PropertyDefined By
  AFTER_ATTRIBUTE_CHANGED : String
[static] [read-only] Dispatched when the value of a property changes on this Link.
Link
  AFTER_DELETE : String
[static] [read-only] Dispatched after a Link is deleted.
Link
  AFTER_EMBED : String
[static] [read-only] Dispatched after a Link is embedded.
Link
  AFTER_MOVE : String
[static] [read-only] Dispatched after a Link is relocated from one object to another.
Link
  AFTER_NEW : String
[static] [read-only] Dispatched after a Link is created.
Link
  AFTER_UNEMBED : String
[static] [read-only] Dispatched after a Link is unembedded.
Link
  AFTER_UPDATE : String
[static] [read-only] Dispatched after a Link is updated.
Link
  assetID : String
[read-only] The asset ID of the linked object.
Link
  assetURL : String
[read-only] The asset URL of the linked object.
Link
  BEFORE_DELETE : String
[static] [read-only] Dispatched before a Link is deleted.
Link
  BEFORE_EMBED : String
[static] [read-only] Dispatched before a Link is embedded.
Link
  BEFORE_MOVE : String
[static] [read-only] Dispatched before a Link is relocated from one object to another.
Link
  BEFORE_UNEMBED : String
[static] [read-only] Dispatched before a Link is unembedded.
Link
  BEFORE_UPDATE : String
[static] [read-only] Dispatched before a Link is updated.
Link
  date : Date
[read-only] The date and time the Link was created.
Link
  edited : Boolean
[read-only] If true, indicates the linked object has been edited in the current document but the source file has not been updated.
Link
  editingState : EditingState
[read-only] The Version Cue editing state of the file.
Link
  eventListeners : EventListeners
[read-only] A collection of event listeners.
Link
  events : Events
[read-only] A collection of events.
Link
  filePath : String
[read-only] The file path (colon delimited on the Mac OS).
Link
 InheritedhostObjectDelegate : HostObject
Getter for the delegate
CSHostObject
  id : Number
[read-only] The unique ID of the Link.
Link
  index : Number
[read-only] The index of the link in the links collection.
Link
  isValid : Boolean
[read-only] Returns true if the object specifier resolves to valid objects.
Link
  label : String
A property that can be set to any string.
Link
  links : Links
[read-only] A collection of links.
Link
  linkType : String
[read-only] The file type of the linked object.
Link
  linkXmp : LinkMetadata
[read-only] XMP data for the link source file.
Link
  name : String
[read-only] The name of the Link.
Link
  needed : Boolean
[read-only] If true, indicates a link to a full-resolution version of the source file is needed.
Link
  parent : Object
[read-only] The linked object.
Link
  preferences : Preferences
[read-only] A collection of preferences objects.
Link
  properties : Object
A property that allows setting of several properties at the same time.
Link
  size : Number
[read-only] The size of the Link file.
Link
  status : LinkStatus
[read-only] The status of the link.
Link
  versionState : VersionState
[read-only] The Version Cue version state of the file.
Link
Public Methods
 MethodDefined By
  
addEventListenerLink(eventTypeParam:String = null, handlerParam:Object = null, capturesParam:Boolean = false):EventListener
Adds an event listener.
Link
  
checkIn(versionCommentsParam:String = null, forceSaveParam:Boolean = false):void
Check in to Version Cue.
Link
  
copyLink(toParam:File = null, versionCommentsParam:String = null, forceSaveParam:Boolean = false):void
Copies the link file to the specified location.
Link
  
Opens the source file of the link in the default editor for the source file type.
Link
  
extractLabel(keyParam:String = null):String
Gets the label value associated with the specified key.
Link
 Inherited
filterArgsForHBAPI(args:Array):Array
[static] Function to clean up the argument list and put it into a format that makes sense for HBAPI.
CSHostObject
 Inherited
filterSingleObjectForHBAPI(value:Object):Object
[static]
CSHostObject
 Inherited
getClassObjectForName(className:String):HostObject
[static] This returns a "Class" object, meaning, a HostObject that can be used to make static function calls or get static properties
CSHostObject
  
getElements():Object
Resolves the object specifier, creating an array of object references.
Link
 Inherited
getSpecialTranslation(className:String, ho:HostObject, expectedReturnType:Class, ownerName:String):*
[static]
CSHostObject
 Inherited
hostCall(name:String, expectedReturnType:Class, rawargs:Array):*
Encapsulates a function call to the host
CSHostObject
 Inherited
hostCallStatic(className:String, methodName:String, expectedReturnType:Class, rawargs:Array):*
[static] Implements a safe call of a static method on the host
CSHostObject
 Inherited
hostGet(name:String, expectedReturnType:Class):*
Encapsulates a property get to the host
CSHostObject
 Inherited
hostGetIndex(idx:Object, expectedReturnType:Class):*
Encapsulates a indexed get to the host
CSHostObject
 Inherited
hostGetStatic(className:String, propertyName:String, expectedReturnType:Class):*
[static] Implements a safe get of a static property on the host Used by for instance, all the enum implementations.
CSHostObject
 Inherited
hostSet(name:String, rawvalue:*):void
Encapsulates a property set to the host
CSHostObject
 Inherited
hostSetStatic(className:String, propertyName:String, rawvalue:*):*
[static] Implements a safe set of a static property on the host
CSHostObject
  
insertLabel(keyParam:String = null, valueParam:String = null):void
Sets the label to the value associated with the specified key.
Link
 Inherited
isDescendedFrom(clz:Class, ancClass:Class):Boolean
[static] Efficiently determines whether or not one class descends from another in inheritance hierarchy- class relationships are cached by the ClassUtils implementation- (uses org.as3commons lib to quickly discover class hierarchy.
CSHostObject
  
relink(toParam:Object = null):void
Points the link to a new source file.
Link
  
removeEventListenerLink(eventTypeParam:String = null, handlerParam:Object = null, capturesParam:Boolean = false):Boolean
Removes the event listener.
Link
 Inherited
replaceDefaultArgs(args:Array, defaultArgs:Array):Array
Function to tidy up arguments prior to call.
CSHostObject
  
Opens Adobe Bridge and selects the source file of the link.
Link
  
Opens the file system to the folder that contains the source file of the link, and selects the file.
Link
  
show():void
Selects the link.
Link
  
toSpecifier():String
Retrieves the object specifier.
Link
  
unembed(toParam:File = null, versionCommentsParam:String = null, forceSaveParam:Boolean = false):void
Unembeds the source file.
Link
  
unlink():void
Embeds the source file in the document.
Link
  
Updates the link if the source file has been changed.
Link
 Inherited
wrapReturnedHostObject(rawObject:Object, expectedReturnType:Class, client:CSHostObject, propertyName:String):*
[static] Method used on static/normal get/ hostcalls
CSHostObject
Protected Methods
 MethodDefined By
 Inherited
createWithArgs(args:Array):void
CSHostObject
 Inherited
hostCreate(args:Array):void
CSHostObject
Property Detail
AFTER_ATTRIBUTE_CHANGEDproperty
AFTER_ATTRIBUTE_CHANGED:String  [read-only]

Dispatched when the value of a property changes on this Link. This event bubbles. This event is not cancelable.


Implementation
    public static function get AFTER_ATTRIBUTE_CHANGED():String
AFTER_DELETEproperty 
AFTER_DELETE:String  [read-only]

Dispatched after a Link is deleted. This event bubbles. This event is not cancelable.


Implementation
    public static function get AFTER_DELETE():String
AFTER_EMBEDproperty 
AFTER_EMBED:String  [read-only]

Dispatched after a Link is embedded. This event bubbles. This event is not cancelable.


Implementation
    public static function get AFTER_EMBED():String
AFTER_MOVEproperty 
AFTER_MOVE:String  [read-only]

Dispatched after a Link is relocated from one object to another. This event bubbles. This event is not cancelable.


Implementation
    public static function get AFTER_MOVE():String
AFTER_NEWproperty 
AFTER_NEW:String  [read-only]

Dispatched after a Link is created. This event bubbles. This event is not cancelable.


Implementation
    public static function get AFTER_NEW():String
AFTER_UNEMBEDproperty 
AFTER_UNEMBED:String  [read-only]

Dispatched after a Link is unembedded. This event bubbles. This event is not cancelable.


Implementation
    public static function get AFTER_UNEMBED():String
AFTER_UPDATEproperty 
AFTER_UPDATE:String  [read-only]

Dispatched after a Link is updated. This event bubbles. This event is not cancelable.


Implementation
    public static function get AFTER_UPDATE():String
assetIDproperty 
assetID:String  [read-only]

The asset ID of the linked object.


Implementation
    public function get assetID():String
assetURLproperty 
assetURL:String  [read-only]

The asset URL of the linked object.


Implementation
    public function get assetURL():String
BEFORE_DELETEproperty 
BEFORE_DELETE:String  [read-only]

Dispatched before a Link is deleted. This event bubbles. This event is cancelable.


Implementation
    public static function get BEFORE_DELETE():String
BEFORE_EMBEDproperty 
BEFORE_EMBED:String  [read-only]

Dispatched before a Link is embedded. This event bubbles. This event is cancelable.


Implementation
    public static function get BEFORE_EMBED():String
BEFORE_MOVEproperty 
BEFORE_MOVE:String  [read-only]

Dispatched before a Link is relocated from one object to another. This event bubbles. This event is cancelable.


Implementation
    public static function get BEFORE_MOVE():String
BEFORE_UNEMBEDproperty 
BEFORE_UNEMBED:String  [read-only]

Dispatched before a Link is unembedded. This event bubbles. This event is cancelable.


Implementation
    public static function get BEFORE_UNEMBED():String
BEFORE_UPDATEproperty 
BEFORE_UPDATE:String  [read-only]

Dispatched before a Link is updated. This event bubbles. This event is cancelable.


Implementation
    public static function get BEFORE_UPDATE():String
dateproperty 
date:Date  [read-only]

The date and time the Link was created.


Implementation
    public function get date():Date
editedproperty 
edited:Boolean  [read-only]

If true, indicates the linked object has been edited in the current document but the source file has not been updated.


Implementation
    public function get edited():Boolean
editingStateproperty 
editingState:EditingState  [read-only]

The Version Cue editing state of the file.


Implementation
    public function get editingState():EditingState
eventListenersproperty 
eventListeners:EventListeners  [read-only]

A collection of event listeners.


Implementation
    public function get eventListeners():EventListeners
eventsproperty 
events:Events  [read-only]

A collection of events.


Implementation
    public function get events():Events
filePathproperty 
filePath:String  [read-only]

The file path (colon delimited on the Mac OS). Can also accept: File.


Implementation
    public function get filePath():String
idproperty 
id:Number  [read-only]

The unique ID of the Link.


Implementation
    public function get id():Number
indexproperty 
index:Number  [read-only]

The index of the link in the links collection.


Implementation
    public function get index():Number
isValidproperty 
isValid:Boolean  [read-only]

Returns true if the object specifier resolves to valid objects.


Implementation
    public function get isValid():Boolean
labelproperty 
label:String

A property that can be set to any string.


Implementation
    public function get label():String
    public function set label(value:String):void
linksproperty 
links:Links  [read-only]

A collection of links.


Implementation
    public function get links():Links
linkTypeproperty 
linkType:String  [read-only]

The file type of the linked object.


Implementation
    public function get linkType():String
linkXmpproperty 
linkXmp:LinkMetadata  [read-only]

XMP data for the link source file.


Implementation
    public function get linkXmp():LinkMetadata
nameproperty 
name:String  [read-only]

The name of the Link.


Implementation
    public function get name():String
neededproperty 
needed:Boolean  [read-only]

If true, indicates a link to a full-resolution version of the source file is needed. If false, indicates the object is embedded.


Implementation
    public function get needed():Boolean
parentproperty 
parent:Object  [read-only]

The linked object. Can return: Story, Graphic, Movie or Sound.


Implementation
    public function get parent():Object
preferencesproperty 
preferences:Preferences  [read-only]

A collection of preferences objects.


Implementation
    public function get preferences():Preferences
propertiesproperty 
properties:Object

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


Implementation
    public function get properties():Object
    public function set properties(value:Object):void
sizeproperty 
size:Number  [read-only]

The size of the Link file.


Implementation
    public function get size():Number
statusproperty 
status:LinkStatus  [read-only]

The status of the link.


Implementation
    public function get status():LinkStatus
versionStateproperty 
versionState:VersionState  [read-only]

The Version Cue version state of the file.


Implementation
    public function get versionState():VersionState
Method Detail
addEventListenerLink()method
public function addEventListenerLink(eventTypeParam:String = null, handlerParam:Object = null, capturesParam:Boolean = false):EventListener

Adds an event listener.

Parameters

eventTypeParam:String (default = null) — (String) The event type.
 
handlerParam:Object (default = null) — (Object) The event handler. Can accept: File or JavaScript Function.
 
capturesParam:Boolean (default = false) — (Boolean) This parameter is obsolete. (Optional)

Returns
EventListener
checkIn()method 
public function checkIn(versionCommentsParam:String = null, forceSaveParam:Boolean = false):void

Check in to Version Cue.

Parameters

versionCommentsParam:String (default = null) — (String) The comment for this version (Optional)
 
forceSaveParam:Boolean (default = false) — (Boolean) Forcibly save a version (Optional)

copyLink()method 
public function copyLink(toParam:File = null, versionCommentsParam:String = null, forceSaveParam:Boolean = false):void

Copies the link file to the specified location.

Parameters

toParam:File (default = null) — (File) The file or folder to which to copy the file.
 
versionCommentsParam:String (default = null) — (String) The comment for this version. (Optional)
 
forceSaveParam:Boolean (default = false) — (Boolean) If true, forcibly saves a version. (Optional)

editOriginal()method 
public function editOriginal():void

Opens the source file of the link in the default editor for the source file type.

extractLabel()method 
public function extractLabel(keyParam:String = null):String

Gets the label value associated with the specified key.

Parameters

keyParam:String (default = null) — (String) The key.

Returns
String
getElements()method 
public function getElements():Object

Resolves the object specifier, creating an array of object references.

Returns
Object
insertLabel()method 
public function insertLabel(keyParam:String = null, valueParam:String = null):void

Sets the label to the value associated with the specified key.

Parameters

keyParam:String (default = null) — (String) The key.
 
valueParam:String (default = null) — (String) The value.

relink()method 
public function relink(toParam:Object = null):void

Points the link to a new source file.

Parameters

toParam:Object (default = null) — (Object) The full path name of the new source file. Can accept: File or String.

removeEventListenerLink()method 
public function removeEventListenerLink(eventTypeParam:String = null, handlerParam:Object = null, capturesParam:Boolean = false):Boolean

Removes the event listener.

Parameters

eventTypeParam:String (default = null) — (String) The registered event type.
 
handlerParam:Object (default = null) — (Object) The registered event handler. Can accept: File or JavaScript Function.
 
capturesParam:Boolean (default = false) — (Boolean) This parameter is obsolete. (Optional)

Returns
Boolean
revealInBridge()method 
public function revealInBridge():void

Opens Adobe Bridge and selects the source file of the link.

revealInSystem()method 
public function revealInSystem():void

Opens the file system to the folder that contains the source file of the link, and selects the file.

show()method 
public function show():void

Selects the link.

toSpecifier()method 
public function toSpecifier():String

Retrieves the object specifier.

Returns
String
unembed()method 
public function unembed(toParam:File = null, versionCommentsParam:String = null, forceSaveParam:Boolean = false):void

Unembeds the source file. If no folder is specified, creates a link to the original source file; if a folder is specified, copies the file to the folder and creates a link to the copied file.

Parameters

toParam:File (default = null) — (File) The folder to which to copy the unembedded file. (Optional)
 
versionCommentsParam:String (default = null) — (String) The comment for this version. (Optional)
 
forceSaveParam:Boolean (default = false) — (Boolean) If true, forcibly saves a version. (Optional)

unlink()method 
public function unlink():void

Embeds the source file in the document.

update()method 
public function update():Link

Updates the link if the source file has been changed.

Returns
Link