Winter Cardinal UI - v0.457.0 / DListDataImpl

Class: DListDataImpl<ITEM>

DList data.

Type parameters

Name
ITEM

Implements

Table of contents

Constructors

Properties

Accessors

Methods

Constructors

constructor

• new DListDataImpl<ITEM>(parent, options?): DListDataImpl<ITEM>

Type parameters

Name
ITEM

Parameters

Name Type
parent DListDataImplParent
options? DListDataOptions<ITEM>

Returns

DListDataImpl<ITEM>

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:33

Properties

_accessor

• Protected _accessor: DListItemAccessorImpl<ITEM>

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:29


_after

• Protected _after: ITEM[]

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:28


_before

• Protected _before: ITEM[]

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:26


_items

• Protected _items: ITEM[]

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:27


_mapped

• Protected _mapped: DListDataMapped<ITEM>

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:31


_parent

• Protected _parent: DListDataImplParent

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:25


_selection

• Protected _selection: DListDataImplSelection<ITEM>

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:30

Accessors

accessor

• get accessor(): DListItemAccessor<ITEM>

Returns

DListItemAccessor<ITEM>

Implementation of

DListData.accessor

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:101


after

• get after(): ITEM[]

Returns

ITEM[]

Implementation of

DListData.after

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:87

• set after(after): void

Parameters

Name Type
after ITEM[]

Returns

void

Implementation of

DListData.after

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:91


before

• get before(): ITEM[]

Returns

ITEM[]

Implementation of

DListData.before

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:67

• set before(before): void

Parameters

Name Type
before ITEM[]

Returns

void

Implementation of

DListData.before

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:71


items

• get items(): ITEM[]

Returns

ITEM[]

Implementation of

DListData.items

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:77

• set items(items): void

Parameters

Name Type
items ITEM[]

Returns

void

Implementation of

DListData.items

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:81


mapped

• get mapped(): DListDataMapped<ITEM>

Returns

DListDataMapped<ITEM>

Implementation of

DListData.mapped

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:97


selection

• get selection(): DListDataSelection<ITEM>

Returns

DListDataSelection<ITEM>

Implementation of

DListData.selection

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:105

Methods

add

▸ add(item, index?): boolean

Adds the given item. If the index is given, inserts the given item at that index.

Parameters

Name Type Description
item ITEM an item
index? number an index

Returns

boolean

true if the data is changed

Implementation of

DListData.add

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:166


addAll

▸ addAll(newItems, index?): boolean

Adds all the given items. If the index is given, inserts all the given items at that index.

Parameters

Name Type Description
newItems ITEM[] items
index? number an index

Returns

boolean

true if the data is changed

Implementation of

DListData.addAll

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:180


clear

▸ clear(): boolean

Removes all the items.

Returns

boolean

true if the data is changed

Implementation of

DListData.clear

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:117


clearAndAdd

▸ clearAndAdd(item): boolean

Removes all the existing items and adds the given item.

Parameters

Name Type Description
item ITEM an item

Returns

boolean

true if the data is changed

Implementation of

DListData.clearAndAdd

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:127


clearAndAddAll

▸ clearAndAddAll(newItems): boolean

Removes all the existing items and adds all the given items.

Parameters

Name Type Description
newItems ITEM[] items to be inserted

Returns

boolean

true if the data is changed.

Implementation of

DListData.clearAndAddAll

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:146


each

▸ each(iteratee, from?, to?): void

Calls the specified iteratee on each datum of the specified index range. If called iteratee explicitly returns false, stops an iteration.

Parameters

Name Type Description
iteratee DListDataIteratee<ITEM> an function called on each datum
from? number an index to start an iteration
to? number an index before which an interation stops

Returns

void

Implementation of

DListData.each

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:230


get

▸ get(index): null | ITEM

Returns an item at the specified index. The index is an index on itemsrows filters and sorters are not applied.

Parameters

Name Type Description
index number an index on rows filters and sorters are not applied

Returns

null | ITEM

Implementation of

DListData.get

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:201


onChange

▸ onChange(): void

Returns

void

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:242


remove

▸ remove(index): null | ITEM

Removes an item at the given index.

Parameters

Name Type Description
index number an index of the item to be removed.

Returns

null | ITEM

a removed item or null

Implementation of

DListData.remove

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:220


set

▸ set(index, item): null | ITEM

Replaces an item at the specified index with the given item.

Parameters

Name Type Description
index number an index of the item to be replaced.
item ITEM an item

Returns

null | ITEM

a replaced item or null

Implementation of

DListData.set

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:209


size

▸ size(): number

Returns a size of data.

Returns

number

Implementation of

DListData.size

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:113


toSelection

▸ toSelection(accessor, options?): DListDataImplSelection<ITEM>

Parameters

Name Type
accessor DListItemAccessorImpl<ITEM>
options? DListDataOptions<ITEM>

Returns

DListDataImplSelection<ITEM>

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:50


update

▸ update(forcibly?): void

Parameters

Name Type
forcibly? boolean

Returns

void

Defined in

src/main/typescript/wcardinal/ui/d-list-data-impl.ts:109