Final Class: FlattenedNodeSet

Oracle® JavaScript Extension Toolkit (JET)
17.0.0

F92240-01

Since:
  • 1.0
Module:
  • ojrowexpander

Note: This class is deprecated since 14.0.0. FlattenedNodeSet has been deprecated with FlattenedTreeDataSource.

QuickNav

Description

Flattens a hierarchical node set, which can happen in node set returned from fetchDescendants call.


Usage

For additional information visit:


Final classes in JET

Classes in JET are generally final and do not support subclassing. At the moment, final is not enforced. However, this will likely change in an upcoming JET release.


Constructor

new FlattenedNodeSet(nodeSet, actualStart)

Flattens a hierarchical node set, which can happen in node set returned from fetchDescendants call.
Parameters:
Name Type Argument Description
nodeSet Object the node set to flatten
actualStart number <optional>
in the fetch descendant case the result set would be a subset of the node set. This param gives the exact start index in the wrapped node set where the result should start.

Methods

getCount : {number}

Gets the actual count of the result set.
Returns:

the actual count of the result set.

Type
number

getData(index) : {Object}

Gets the data of the specified index. An error is throw when 1) the range is not yet available and 2) the index specified is out of bounds.
Parameters:
Name Type Description
index number the index of the node/row in which we want to retrieve the data from.
Returns:

the data for the specified index.

Type
Object

getMetadata(index) : {Object}

Gets the metadata of the specified index. An error is throw when 1) the range is not yet available and 2) the index specified is out of bounds. The metadata that the data source must return are: 1) key - Object, the key of the node/row. 2) state - state of the node, valid values are 'expanded', 'collapsed', 'leaf'. 3) depth - number, the depth of the node/row.
Parameters:
Name Type Description
index number the index of the node/row in which we want to retrieve the metadata from.
Returns:

the metadata object for the specific index.

Type
Object

getParent : {Object}

Gets the parent
Returns:

the key of the parent.

Type
Object

getStart : {number}

Gets the start index of the result set.
Returns:

the start index of the result set.

Type
number