aem-forms-af-runtime

Class: Scriptable<T>

Defines scriptable aspects (ie rules, events) of form runtime model. Any form runtime object which requires execution of rules/events should extend from this class.

Type parameters

Name Type
T extends RulesJson

Hierarchy

Implements

Table of contents

Accessors

Properties

Methods

Accessors

:type

get :type(): string

Returns

string

Inherited from

BaseNode.:type


dataRef

get dataRef(): undefined | null | string

Returns

undefined | null | string

Inherited from

BaseNode.dataRef


description

get description(): undefined | string

Returns

undefined | string

Inherited from

BaseNode.description

set description(d): void

Parameters

Name Type
d undefined | string

Returns

void

Inherited from

BaseNode.description


fieldType

get fieldType(): string

Returns

string

Inherited from

BaseNode.fieldType


form

get form(): FormModel

Returns

FormModel

Inherited from

BaseNode.form


fragment

get fragment(): string

Returns

string

Inherited from

BaseNode.fragment


id

get id(): string

Returns

string

Inherited from

BaseNode.id


index

get index(): number

Returns

number

Inherited from

BaseNode.index


isContainer

get isContainer(): boolean

Returns

boolean

Inherited from

BaseNode.isContainer


label

get label(): undefined | Label

Returns

undefined | Label

Inherited from

BaseNode.label

set label(l): void

Parameters

Name Type
l undefined | Label

Returns

void

Inherited from

BaseNode.label


lang

get lang(): undefined | string

Returns

undefined | string

Inherited from

BaseNode.lang


name

get name(): undefined | string

Returns

undefined | string

Inherited from

BaseNode.name


parent

get parent(): ContainerModel

Returns

ContainerModel

Inherited from

BaseNode.parent


properties

get properties(): Object

Returns

Object

Inherited from

BaseNode.properties

set properties(p): void

Parameters

Name Type
p Object

Returns

void

Inherited from

BaseNode.properties


qualifiedName

get qualifiedName(): any

Returns

any

Inherited from

BaseNode.qualifiedName


repeatable

get repeatable(): any

Returns

any

Inherited from

BaseNode.repeatable


ruleEngine

get ruleEngine(): RuleEngine

Returns

RuleEngine

Implementation of

ScriptableField.ruleEngine

Inherited from

BaseNode.ruleEngine


screenReaderText

get screenReaderText(): undefined | string

Returns

undefined | string

Inherited from

BaseNode.screenReaderText


type

get type(): undefined | string

Returns

undefined | string

Inherited from

BaseNode.type


uniqueItems

get uniqueItems(): undefined | boolean

Returns

undefined | boolean

Inherited from

BaseNode.uniqueItems


visible

get visible(): undefined | boolean

Returns

undefined | boolean

Inherited from

BaseNode.visible

set visible(v): void

Parameters

Name Type
v undefined | boolean

Returns

void

Inherited from

BaseNode.visible

Properties

_eventSource

_eventSource: EventSource = EventSource.CODE

Inherited from

BaseNode._eventSource


value

Abstract value: Primitives

The current value of the Field. The property is serialized in the Data Model.

Inherited from

BaseNode.value

Methods

change

change(event, context): void

Parameters

Name Type
event Action
context any

Returns

void


defaultDataModel

Abstract defaultDataModel(name): undefined | default

Parameters

Name Type
name string | number

Returns

undefined | default

Inherited from

BaseNode.defaultDataModel


dispatch

dispatch(action): void

Parameters

Name Type
action Action

Returns

void

Inherited from

BaseNode.dispatch


executeAction

executeAction(action): void

Executes the given action

Parameters

Name Type Description
action Action event object

Returns

void

Overrides

BaseNode.executeAction


executeExpression

executeExpression(expr): any

Parameters

Name Type
expr string

Returns

any


focus

focus(): void

Returns

void

Inherited from

BaseNode.focus


getDependents

getDependents(): string[]

Returns

string[]

Inherited from

BaseNode.getDependents


getNonTransparentParent

getNonTransparentParent(): ContainerModel

Returns

ContainerModel

Inherited from

BaseNode.getNonTransparentParent


getRules

getRules(): Items<string>

Returns

Items<string>


getState

getState(forRestore?): T & { :type: string ; _dependents: undefined | string[] ; allowedComponents: undefined = undefined; columnClassNames: undefined = undefined; columnCount: undefined = undefined; gridClassNames: undefined = undefined; id: string ; index: number ; maxOccur: undefined | number ; minOccur: undefined | number ; parent: undefined = undefined; properties: { [key: string]: any; } ; qualifiedName: any ; repeatable: undefined | boolean = true }

Parameters

Name Type Default value
forRestore boolean false

Returns

T & { :type: string ; _dependents: undefined | string[] ; allowedComponents: undefined = undefined; columnClassNames: undefined = undefined; columnCount: undefined = undefined; gridClassNames: undefined = undefined; id: string ; index: number ; maxOccur: undefined | number ; minOccur: undefined | number ; parent: undefined = undefined; properties: { [key: string]: any; } ; qualifiedName: any ; repeatable: undefined | boolean = true }

Inherited from

BaseNode.getState


isTransparent

isTransparent(): boolean

Transparent form fields are meant only for creation of view. They are also not part of data

Returns

boolean

Inherited from

BaseNode.isTransparent


reset

Abstract reset(): any

Resets the form model

Returns

any

Inherited from

BaseNode.reset


syncDataAndFormModel

Abstract syncDataAndFormModel(a?): any

Parameters

Name Type
a? default | default

Returns

any

Inherited from

BaseNode.syncDataAndFormModel


validate

Abstract validate(): ValidationError[]

Validates the given form field

Returns

ValidationError[]

Inherited from

BaseNode.validate