DocumentManager1.2

back

Commands

Events

DocumentManager provides a way to monitor, and interact with individual documents/frames in a document tree (whether they have an ECMASCript environment or not).

Example functionality includes loading URLs in a certain frame, and enumerating all the documents in a certain Window.

ID fields

External ID fields

Some IDs used in this service originate (and can be used with) other services.

GetHighlights

Get information about the currently highlighted text, resulting from a previous inline text search.

This command will fail if used on a build which does not support 'find-all' functionality, typically (non-smart) phone and TV builds.

Added in version 1.1

command GetHighlights(GetHighlightsArg)
{
}
returns (HighlightList)
{
}
= 7;

GetPageText

Get the displayed (plain) text of a window, or document subtree. This command can fail if the connected build does not support the necessary text serialization feature.

Added in version 1.1

command GetPageText(GetPageTextArg)
{
}
returns (PageText)
{
}
= 8;

ListDocuments

Get the document tree for a Window, or for all Windows.

command ListDocuments(ListDocumentsArg)
{
}
returns (DocumentList)
{
}
= 1;

LoadDocument

Load a URL in a specified frame.

command LoadDocument(LoadDocumentArg)
{
}
returns (Default)
{
}
= 2;

ReloadDocument

Reload the current URL for a specified frame.

command ReloadDocument(ReloadDocumentArg)
{
}
returns (Default)
{
}
= 3;

SearchText

Search for a text string in a certain window, or frame.

This command will fail if used on a build which does not support 'find-all' functionality, typically (non-smart) phone and TV builds.

Added in version 1.1

command SearchText(SearchTextArg)
{
}
returns (HighlightList)
{
}
= 6;

OnAboutToLoadDocument

Fired when a document is about to be loaded (regardless of whether the load actually succeeds).

event OnAboutToLoadDocument returns (AboutToLoadDocument)
{
}
= 4;

OnDocumentEvent

Fired for specific events happening during document load.

Added in version 1.2

event OnDocumentEvent returns (DocumentEvent)
{
}
= 9;

OnDocumentLoaded

Fired when a document is fully loaded (after DOM event 'load' has finished).

event OnDocumentLoaded returns (DocumentLoaded)
{
}
= 5;