Copyright © 2021 by K4.org
  (v.0.48.124)

This implements the binder-breaker pattern to store and manage a dynamic list.

Index

Rules

initialList

initialList: Array

The initial list

Flags : cached, parameter

Default expression : []

listBinder

listBinder: Boolean

Internal Use Only

Flags : cached

Expression : true

listBreaker

listBreaker: Any

Internal Use Only

Flags : None. (Note this is uncached)

Expression : R.model.unbindSlot(this, "listBinder");

sortKey

sortKey: String

The name of the property or Rule which will be used to sort the list.

Flags : cached, parameter

Default expression : "name"

theList

theList: Array

The sole accessor to the list.

Flags : cached

Expression : if (this.listBinder) return this.getList();

uniqueKey

uniqueKey: String

The name of the property or Rule which will return a unique key for each item in the list.

Flags : cached, parameter

Default expression : "refChain"

Methods

addItem

  • addItem(): Number
  • Adds item to the end of the list.

    Flags : method (Note this is uncached)

    Returns Number

clearList

  • clearList(): Number
  • Empties the list of all items.

    Flags : method (Note this is uncached)

    Returns Number

getList

  • getList(): Array
  • Internal Use Only

    Flags : method (Note this is uncached)

    Returns Array

makeItem

  • makeItem(): Any
  • Creates items containing data to insert into the list. data must be an object which has a sortKey.

    Flags : method (Note this is uncached)

    Returns Any