Skip to main content

Class: FmcListUtility<T>

Utility class to drive list

Type parameters

Name
T

Constructors

constructor

new FmcListUtility<T>(page, data, renderRow, size?, firstPageSize?): FmcListUtility<T>

FMC List Utility Class

Type parameters

Name
T

Parameters

NameTypeDefault valueDescription
pageAbstractFmcPage<any>undefinedThe Fmc Page
dataSubscribableArray<T>undefinedThe row input data
renderRow(page: AbstractFmcPage<any>, indexInDisplay: number, prevData?: T, data?: T, nextData?: T) => FmcRenderTemplateRow[]undefinedFunction to call when the list needs to be re-rendered with new data
sizenumber5row count of the list per page
firstPageSizeundefined | numberundefinedrow count of the first page of the list

Returns

FmcListUtility<T>

Defined in

src/sdk/fmc/FmcListUtility.ts:19

Properties

data

Protected Readonly data: SubscribableArray<T>

The row input data

Defined in

src/sdk/fmc/FmcListUtility.ts:21


firstPageSize

Protected Readonly firstPageSize: undefined | number = undefined

row count of the first page of the list

Defined in

src/sdk/fmc/FmcListUtility.ts:24


page

Protected Readonly page: AbstractFmcPage<any>

The Fmc Page

Defined in

src/sdk/fmc/FmcListUtility.ts:20


renderRow

Protected Readonly renderRow: (page: AbstractFmcPage<any>, indexInDisplay: number, prevData?: T, data?: T, nextData?: T) => FmcRenderTemplateRow[]

Function to call when the list needs to be re-rendered with new data

Type declaration

▸ (page, indexInDisplay, prevData?, data?, nextData?): FmcRenderTemplateRow[]

Function to call when the list needs to be re-rendered with new data

Parameters
NameType
pageAbstractFmcPage<any>
indexInDisplaynumber
prevData?T
data?T
nextData?T
Returns

FmcRenderTemplateRow[]

Defined in

src/sdk/fmc/FmcListUtility.ts:22


size

Protected Readonly size: number = 5

row count of the list per page

Defined in

src/sdk/fmc/FmcListUtility.ts:23

Methods

handleSelectKey

handleSelectKey(event): Promise<boolean>

Handles when the Select Key is pressed.

Parameters

NameTypeDescription
eventLineSelectKeyEventThe Select Key Event.

Returns

Promise<boolean>

Whether the event was handled by this component.

Defined in

src/sdk/fmc/FmcListUtility.ts:59


renderList

renderList(page): FmcRenderTemplateRow[]

Returns a rendered list page for a specified page

Parameters

NameTypeDescription
pagenumberThe page number to render

Returns

FmcRenderTemplateRow[]

The FmcRenderTemplate

Defined in

src/sdk/fmc/FmcListUtility.ts:33