Packagecom.adobe.portfolio.api
Interfacepublic interface INavigatorHost extends flash.events.IEventDispatcher

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

An INavigator instance uses this interface to communicate with its hosting environment.

See also

INavigator


Public Properties
 PropertyDefined By
  apiVersion : Array
[read-only] The API version number as recorded in the apiVersion field of the navigator's navigator.xml file.
INavigatorHost
  applicationFontList : Array
[read-only] Returns an array of Objects that describe fonts available on the system or to the hosting application Fonts that are not legally embeddable are filtered out.
INavigatorHost
  authoringMode : Boolean
[read-only] Returns a value of true when Acrobat is in collection authoring mode.
INavigatorHost
  collection : ICollection
[read-only] Retrieves the portfolio (an ICollection instance) on which the navigator is operating.
INavigatorHost
  collectionDropManager : ICollectionDropManager
[read-only] Gets the drop manager object used by flex developers to specify the target directory for drag and drop of files from the OS, and by flash developers to enable and control drag and drop functionality.
INavigatorHost
  commands : Object
[read-only] Returns the set of delivered ICommand instances as requested via requestCommands().
INavigatorHost
  currentFolder : IAttachment
The folder where new attachments will be added when Acrobat menu items such as "Add File...", "Add Folder...", and "New Folder..." are invoked.
INavigatorHost
  currentPropertyContext : IPropertyContext
[write-only] Sets the current IPropertyContext for the navigator, based on the user's interaction.
INavigatorHost
  locale : String
[read-only] Returns Acrobat's current runtime locale.
INavigatorHost
  navigatorColorPalette : Object
Returns a suggested palette of colors for the navigator.
INavigatorHost
  navigatorFont : Font
[read-only] Use this font to get the same look as the custom navigators that Adobe includes with Acrobat.
INavigatorHost
  propertyContexts : Array
[write-only] Sets an IPropertyContext array for properties supported by the navigator.
INavigatorHost
  rootDocument : IPDFDocument
[read-only] The portfolio's root document.
INavigatorHost
  selection : Array
The currently selected set of IAttachment instances.
INavigatorHost
  viewConfiguration : Object
[read-only] Describes the current configuration of the view in which the navigator is being displayed.
INavigatorHost
Public Methods
 MethodDefined By
  
getLocalizedString(key:String):String
Gets a localized string from Acrobat's resources.
INavigatorHost
  
requestCommands(commandNames:Array, callback:Function = null):void
Requests a set of named ICommand instances.
INavigatorHost
  
Updates Acrobat's next and previous attachment values.
INavigatorHost
  
Shows the portfolio's root document.
INavigatorHost
  
updateProperty(context:IPropertyContext, property:IProperty):void
A function to indicate that the navigator has changed the given IProperty in the context of the given IPropertyContext.
INavigatorHost
Events
 Event Summary Defined By
  An event that is dispatched for a change to a property value.INavigatorHost
  An event that is dispatched when the user right clicks in the PDF portfolio navigator window.INavigatorHost
Property Detail
apiVersionproperty
apiVersion:Array  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The API version number as recorded in the apiVersion field of the navigator's navigator.xml file.


Implementation
    public function get apiVersion():Array
applicationFontListproperty 
applicationFontList:Array  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Returns an array of Objects that describe fonts available on the system or to the hosting application Fonts that are not legally embeddable are filtered out. Each entry in the array is an Object which contains the following attributes:

AttributeDescription
fontNameName of the font
fontWeight"normal" or "bold"
fontPosture"normal" or "italic"|
familyNameFamily name of the font, for example, "Adobe Caslon Pro Italic" would have the family name "Adobe Caslon"
styleNameStyle name of the font, for example, "Adobe Caslon Pro Italic" would have the family name "Italic"
psNamePostScript name of the font, for example, "Adobe Caslon Pro Italic" has the PostScript name "ACaslonPro-Italic"

This property can be used as the source for data binding.


Implementation
    public function get applicationFontList():Array
authoringModeproperty 
authoringMode:Boolean  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Returns a value of true when Acrobat is in collection authoring mode. This flag is useful if your navigator has functionality that you want to make available to collection authors only.

This property can be used as the source for data binding.


Implementation
    public function get authoringMode():Boolean
collectionproperty 
collection:ICollection  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Retrieves the portfolio (an ICollection instance) on which the navigator is operating.


Implementation
    public function get collection():ICollection
collectionDropManagerproperty 
collectionDropManager:ICollectionDropManager  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Gets the drop manager object used by flex developers to specify the target directory for drag and drop of files from the OS, and by flash developers to enable and control drag and drop functionality.


Implementation
    public function get collectionDropManager():ICollectionDropManager

See also

commandsproperty 
commands:Object  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Returns the set of delivered ICommand instances as requested via requestCommands(). The instance returned is a copy; changes to it have no effect on the set held by INavigatorHost.

The value of this property is an Object. For each dynamic properties of this object:

This property can be used as the source for data binding.


Implementation
    public function get commands():Object

See also

currentFolderproperty 
currentFolder:IAttachment

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The folder where new attachments will be added when Acrobat menu items such as "Add File...", "Add Folder...", and "New Folder..." are invoked.

If currentFolder is null, new attachments will be added at the root level of the tree of attachments.

This property can be used as the source for data binding.


Implementation
    public function get currentFolder():IAttachment
    public function set currentFolder(value:IAttachment):void
currentPropertyContextproperty 
currentPropertyContext:IPropertyContext  [write-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Sets the current IPropertyContext for the navigator, based on the user's interaction.


Implementation
    public function set currentPropertyContext(value:IPropertyContext):void

See also

localeproperty 
locale:String  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Returns Acrobat's current runtime locale. This will not change during the navigator's lifetime. The locale is given as an ISO language and region code. For example, "en_US".


Implementation
    public function get locale():String
navigatorColorPaletteproperty 
navigatorColorPalette:Object

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Returns a suggested palette of colors for the navigator.

The returned palette is an Object with the following key strings:

The value for each key is a uint specifying an RGB color.

This property can be used as the source for data binding.


Implementation
    public function get navigatorColorPalette():Object
    public function set navigatorColorPalette(value:Object):void
navigatorFontproperty 
navigatorFont:Font  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Use this font to get the same look as the custom navigators that Adobe includes with Acrobat.

This font should have the glyphs needed to display the language used by Acrobat's current runtime locale, but may not have good coverage of glyphs for other locales.

The characteristics of this font (the supported font name, the font styles and glyphs) may change when Acrobat's runtime local changes. You should not assume that the Font returned here in one run of Acrobat will have the same properties as the Font returned in subsequent runs.


Implementation
    public function get navigatorFont():Font

See also

flash.text.Font
propertyContextsproperty 
propertyContexts:Array  [write-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Sets an IPropertyContext array for properties supported by the navigator. If contextArray is null, it will be treated as if it were an empty array. Any null entries in the array will be ignored; if multiple IPropertyContext entries have equal name properties, the resulting behavior is undefined. The caller retains ownerwhip of contextArray; further modifications to it will not affect this property.


Implementation
    public function set propertyContexts(value:Array):void

See also

rootDocumentproperty 
rootDocument:IPDFDocument  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 10.1
Runtime Versions : Flash Player 10.1, AIR 2.0

The portfolio's root document.

The document that contains the collection. A portfolio's root document is sometimes referred to as its "cover sheet". The value of this property does not change over the lifetime of this INavigatorHost instance.


Implementation
    public function get rootDocument():IPDFDocument
selectionproperty 
selection:Array

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The currently selected set of IAttachment instances.

The selection can be controlled both by the host (typically via host-side user interface controls) or by the INavigator instance.

Each element must be a valid, non-null IAttachment instance. The Array may be empty (signifying that there is no selection) but it can never be null. Duplicates are not allowed. Multiple IAttachment instances can be selected at once. It is also the IAttachment instance on which the next and previous instances are based.

Changing the selection may invalidate the current values of the next and previous instances. In response to selection changes, the INavigator should call setNextPrevious() if necessary to indicate such changes.

This property can be used as the source for data binding.


Implementation
    public function get selection():Array
    public function set selection(value:Array):void

See also

viewConfigurationproperty 
viewConfiguration:Object  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 10.1
Runtime Versions : Flash Player 10.1, AIR 2.0

Describes the current configuration of the view in which the navigator is being displayed. The value might be missing one or more properties, but will never be null.

The view configuration is described by a set of key-value properties. It is possible that a navigator embedded in a PDF document may someday be displayed in a runtime environment that doesn't support all of the current view configuration keys. You should always use the Object.hasOwnProperty() method to check for the existence of a property before getting its value.

The following view configuration properties can be present:

"collectionViewLayout": The collection view layout. If present, can have one of the following values:

"collectionPreviewDocumentType": The type of document being shown in conjunction with the navigator. Can have one of the following values:

Where the document is shown depends on the collection view layout (see above):

This property can be used as the source for data binding.


Implementation
    public function get viewConfiguration():Object
Method Detail
getLocalizedString()method
public function getLocalizedString(key:String):String

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Gets a localized string from Acrobat's resources.

Only a limited set of keys is supported:

Parameters

key:String — A unique key identifying a localized string.

Returns
String — The string identified by key, localized for the Acrobat's current runtime locale.

Throws
Error — An Error is thrown if an unsupported key argument is specified.

See also

requestCommands()method 
public function requestCommands(commandNames:Array, callback:Function = null):void

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Requests a set of named ICommand instances. The requested ICommand instances will be added to the commands property.

Requests are cumulative (that is, existing ICommand instances will not be removed from the commands property). A particular ICommand instance will never be delivered more than once, although it is permitted to request it multiple times.

If one or more of the command names is invalid, only those that are valid will be delivered.

The method accepts an optional callback function as an argument. The callback function is invoked to indicate the result of the operation. The callback function receives a single argument, an Object, and has the following signature:

    function callback(response:Object):void
The response:Object parameter holds properties that define the response. These include:

PropertyTypeValue
successBooleantrue if the request succeeded for all command names in the array; false if the request failed for one or more names.
invalidCommandNamesArray: each element is a String.The names of all commands that could not be delivered, if any; otherwise an empty Array.

Parameters

commandNames:Array — An Array of command names. Each element is a String, and legal values are any of the values defined in the CommandType class.
 
callback:Function (default = null) — An optional notification function, as described above.

See also

setNextPrevious()method 
public function setNextPrevious(next:IAttachment, previous:IAttachment):void

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Updates Acrobat's next and previous attachment values.

Acrobat maintains values for the next and previous attachments, based on the selection and the current sort order. When either the selection or the sort order changes, the user interface's definition of next and previous may change. INavigator instances are responsible for updating these values in response to selection and sort changes.

Parameters

next:IAttachment — The new value for the next IAttachment. A null value means there is no next IAttachment.
 
previous:IAttachment — The new value for the previous IAttachment. A null value means there is no previous IAttachment.

See also

showRootDocument()method 
public function showRootDocument():void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.1
Runtime Versions : Flash Player 10.1, AIR 2.0

Shows the portfolio's root document.

The root document is called the "cover sheet" in the Acrobat user interface. When the portfolio window is split, one pane displays the navigator and the other pane displays either an attachment preview or the cover sheet, or is blank. When the portfolio window is not split, the cover sheet or attachment preview is shown on top of the navigator; the navigator remains running but is completely obscured.

In both the split and non-split cases, showing the cover sheet hides the attachment preview, if it is showing, and previewing an attachment hides the cover sheet view, if it is showing. There is no method for hiding the root document, but the cover sheet view can be replaced with an attachment preview by executing the CommandType.PREVIEW command, which can be requested by calling the requestCommands() method.

If the user has permission to edit the root document, the cover sheet view is editable. Depending on the purpose and design of the portfolio, the navigator developer may need to be careful about previewing an attachment while the user is working with the root document.

updateProperty()method 
public function updateProperty(context:IPropertyContext, property:IProperty):void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

A function to indicate that the navigator has changed the given IProperty in the context of the given IPropertyContext. If property is not present in context's properties array, or if context has not been previously set in propertyContexts or currentPropertyContext, then this function has no effect.

Parameters

context:IPropertyContext
 
property:IProperty

See also

Event Detail
propertyValueChanged Event
Event Object Type: com.adobe.portfolio.api.PropertyValueChangedEvent

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

An event that is dispatched for a change to a property value.

Since contexts and properties cannot be directly manipulated by the host, events are used to indicate that a property has changed. This is analogous to FieldValueChangedEvent.

See also

rightClick Event  
Event Object Type: com.adobe.portfolio.api.RightClickEvent

Language Version : ActionScript 3.0
Product Version : Portfolio 9.0
Runtime Versions : Flash Player 10.1, AIR 2.0

An event that is dispatched when the user right clicks in the PDF portfolio navigator window. The typical response to this event is to execute the CommandType.CONTEXT_MENU ICommand.

See also