Reference Source
public class | source

StatedDom

Extends:

js/base/component/rendered_dom.js~RenderedDomBoundDom → StatedDom

Direct Subclass:

Component

Constructor Summary

Public Constructor
public

constructor(arg_runtime: RuntimeBase, arg_state: Immutable.Map, arg_log_context: string): nothing

Creates an instance of StatedDom.

Member Summary

Public Members
public
Private Members
private
private
private

Method Summary

Public Methods
public

Clear component to initial values.

public

dispatch_update_state_action(arg_new_state: Immutable.Map): nothing

Dispatch update state action.

public

dispatch_update_state_value_action(arg_path: array | string, arg_value: any): nothing

Dispatch update state action.

public

Get view children components.

public

get_named_stream(arg_stream_name: string): Stream | undefined

Get a named stream.

public

Render a component inside this element from a json description.

public

register_from_json(arg_options: object): nothing

Register a component description from a json content.

public

render_inside_from_json(arg_name: string, arg_json_desc: object): nothing

Render a component inside this element from a json description.

public

Update view with current state.

public

Update view with current state.

Private Methods
private

_update(): *

Inherited Summary

From class BoundDom
public
public
private

_bindings: {}

private
public

init_bindings(): nothing

Init bindings.

public

load(arg_state: Immutable.Map | undefined): nothing | Promise

Load and apply a component configuration.

public

unload(): nothing

Unload a component configuration.

Public Constructors

public constructor(arg_runtime: RuntimeBase, arg_state: Immutable.Map, arg_log_context: string): nothing source

Creates an instance of StatedDom.

Override:

BoundDom#constructor

Params:

NameTypeAttributeDescription
arg_runtime RuntimeBase

client runtime.

arg_state Immutable.Map

component initial state.

arg_log_context string

context of traces of this instance (optional).

Return:

nothing

Public Members

public is_stated_dom: boolean source

Private Members

private _children_components: * source

private _dom_element: * source

private _ready_promise: * source

Public Methods

public clear(): Promise source

Clear component to initial values.

Return:

Promise

public dispatch_update_state_action(arg_new_state: Immutable.Map): nothing source

Dispatch update state action.

Params:

NameTypeAttributeDescription
arg_new_state Immutable.Map

new state Immutable Map.

Return:

nothing

public dispatch_update_state_value_action(arg_path: array | string, arg_value: any): nothing source

Dispatch update state action.

Params:

NameTypeAttributeDescription
arg_path array | string

component state path.

arg_value any

component state value.

Return:

nothing

public get_children_component(): array source

Get view children components.

Return:

array

list of Component.

public get_named_stream(arg_stream_name: string): Stream | undefined source

Get a named stream.

Params:

NameTypeAttributeDescription
arg_stream_name string

stream name.

Return:

Stream | undefined

found stream.

public register_and_render_inside_from_json(arg_options: object): nothing source

Render a component inside this element from a json description.

Params:

NameTypeAttributeDescription
arg_options object

json source configuration.

Return:

nothing

public register_from_json(arg_options: object): nothing source

Register a component description from a json content.

Params:

NameTypeAttributeDescription
arg_options object

json source configuration.

Return:

nothing

public render_inside_from_json(arg_name: string, arg_json_desc: object): nothing source

Render a component inside this element from a json description.

Params:

NameTypeAttributeDescription
arg_name string

component name.

arg_json_desc object

component description.

Return:

nothing

public update(): Promise source

Update view with current state.

Return:

Promise

public update_children(): Promise source

Update view with current state.

Return:

Promise

Private Methods

private _update(): * source

Return:

*