Options
All
  • Public
  • Public/Protected
  • All
Menu

Class PartListProperty<T>

A property value that is a list of (model) elements. Will detect when children are moved, added, deleted and sends the appropriate deltas.

Type parameters

Hierarchy

Index

Constructors

constructor

  • new PartListProperty(declaredOn: any, parent: Structure, name: string, initialValue: T[], ...moreArgs: any[]): PartListProperty
  • parent is the structure that the value of this property attaches to, so e.g. for all values item of Part(List)Property we (should) have the invariant: item.container === this.parent.

    initialValue is default value except parts and GUID-typed primitives. (by-id/name references do not have default values.)

    Parameters

    • declaredOn: any
    • parent: Structure
    • name: string
    • initialValue: T[]
    • Rest ...moreArgs: any[]

    Returns PartListProperty

Properties

declaredOn

declaredOn: any

handle

handle: function

Type declaration

    • (): void
    • Returns void

isAvailable

isAvailable: boolean

Returns true if this property is not deleted, and already availabe in the current model version

isPublic

isPublic: boolean

isRequired

isRequired: boolean

name

name: string

observableValue

observableValue: IObservableArray<T>

parent

versionInfo

versionInfo: PropertyVersionInfo

Methods

assertPropertyAvailableInCurrentVersion

  • assertPropertyAvailableInCurrentVersion(): void

assertReadable

  • assertReadable(): void

assertWritable

  • assertWritable(): void

deepCopyInto

  • deepCopyInto(clone: any, idMap: any, unresolvedIdentifierFixers: any): void

dispose

  • dispose(): void

fireOnChange

  • fireOnChange(): void

get

  • get(): IObservableArray<T>

initialize

  • initialize(initialItems: T[]): IObservableArray<T>

onChange

  • onChange(changeData: IArrayChange<T> | IArraySplice<T>): void

processChildAddition

  • processChildAddition(index: number): void
  • Parameters

    • index: number

    Returns void

processChildRemoval

  • processChildRemoval(element: T): void
  • Parameters

    • element: T

    Returns void

removeChild

  • removeChild(child: T): boolean
  • Parameters

    • child: T

    Returns boolean

resolveReferences

  • resolveReferences(): void

set

  • set(newValue: T[]): void

updateElementContainer

  • updateElementContainer(unit: ModelUnit): void

updateWithRawValue

  • updateWithRawValue(value: any): void

Generated using TypeDoc