Home Reference Source
public class | source

VirtualScrollLoadInfo

Extends:

TypedObject → VirtualScrollLoadInfo

When grid.enableVirtualScroll=true, the grid dispatches a virtualScroll event when the grid scrolls. This event contains a recordsToLoad array, which contains an series of VirtualScrollLoadInfo records. This provides the application a list of record indexes to load, and which levels to load them at.

In flat grids, the FlexDataGridVirtualScrollEvent.recordsToLoad will always contain a list of VirtualScrollLoadInfo records were level=1. For nested grids, depending on where the user scrolls and which items are open, you could get a list of records from multiple levels, for example. Records 1-3 from level 1, All children of record 3 from level 2, and then Record 4-10 from level 1.

Setting enableVirtualScroll requires that you specify childrenCountField as well as selectedKeyField. Additionally, enableVirtualScroll also requires that you set filterPageSortMode=server and itemLoadMode=server. Finally, virtual scroll does not work with variableRowHeights.

Constructor Summary

Public Constructor
public

constructor(level: *, recordIndex: *, verticalScrollPosition: *, itemHeight: *, item: *, parent: *, rowType: *)

Member Summary

Public Members
public

item: *

Pointer to the item.

public

The "area" covered by this item.

public

level: *

FlexDataGridColumnLevel that this item belongs to

public

parent: *

Pointer to the parent item.

public

The record index.

public

rowType: *

Type of the row.

public

The verticalScrollPosition that this record appears at

Method Summary

Public Methods
public
public
public

The nest depth of the level

public

getRowType(): *

public

getRowType(): *

public
public

isParentOf(child: *): *

public

setRowType(val: *)

public
public

Inherited Summary

From class TypedObject
public

typeCache: {}

public
public

Returns a list of strings that represent the object hierarchy for this object.

public

Returns true if the class name to check is in the list of class names defined for this class.

Public Constructors

public constructor(level: *, recordIndex: *, verticalScrollPosition: *, itemHeight: *, item: *, parent: *, rowType: *) source

Override:

TypedObject#constructor

Params:

NameTypeAttributeDescription
level *
recordIndex *
verticalScrollPosition *
itemHeight *
item *
parent *
rowType *

Public Members

public item: * source

Pointer to the item. Should be populated before calling setVirtualScrollData.

public itemHeight: * source

The "area" covered by this item. Includes any children.

public level: * source

FlexDataGridColumnLevel that this item belongs to

public parent: * source

Pointer to the parent item.

public recordIndex: * source

The record index.

public rowType: * source

Type of the row.

public verticalScrollPosition: * source

The verticalScrollPosition that this record appears at

Public Methods

public getClassNames(): string source

Returns a list of strings that represent the object hierarchy for this object.

Override:

TypedObject#getClassNames

Return:

string

public getItemArea(): * source

Return:

*

public getLevelNestDepth(): * source

The nest depth of the level

Return:

*

public getRowType(): * source

Return:

*

public getRowType(): * source

Return:

*

public getVerticalScrollPosition(): * source

Return:

*

public isParentOf(child: *): * source

Params:

NameTypeAttributeDescription
child *

Return:

*

public setRowType(val: *) source

Params:

NameTypeAttributeDescription
val *

public setVerticalScrollPosition(val: *) source

Params:

NameTypeAttributeDescription
val *

public toString(): string source

Return:

string