Class: IControl¶
Hierarchy¶
-
IControl
Summary¶
Properties¶
Accessors¶
Methods¶
- androidContext
- container
- definition
- executeAction
- executeActionOrRule
- formatRule
- getValue
- initialize
- observable
- onDataChanged
- onDismissingModal
- onDisplayingModal
- onNavigatedFrom
- onNavigatedTo
- onNavigatingFrom
- onNavigatingTo
- onPageLoaded
- onPageUnloaded
- onPress
- page
- redraw
- setContainer
- setStyle
- setValidationProperty
- setValue
- valueResolver
- view
- viewIsNative
Properties¶
Protected
_props¶
• _props: any
context¶
• context: IContext
Accessors¶
builder¶
• get builder(): IBuilder
Returns: IBuilder
controlProxy¶
• get controlProxy(): IControlProxy
Get the ControlProxy associated with this control.
Returns: IControlProxy
isControl¶
• get isControl(): boolean
Returns: boolean
isFormCell¶
• get isFormCell(): boolean
Returns: boolean
type¶
• get type(): string
Returns: string
Methods¶
androidContext¶
▸ androidContext(): any
Inherited from IView.androidContext
Called to get the android.content.Context object necessary to create view objects. To learn more, see https://developer.android.com/reference/android/content/Context
Returns: any
container¶
▸ container(): ContainerDefinition
Getter for the container.
Returns: ContainerDefinition
The control's container.
definition¶
▸ definition(): any
Inherited from IView.definition
Getter for the view's definition.
Returns: any
The view's definition.
Protected
executeAction¶
▸ executeAction(actionOrRulePath
: any): Promise‹any›
Inherited from IView.executeAction
deprecated
- use executeActionOrRule
Parameters:
Name | Type |
---|---|
actionOrRulePath |
any |
Returns: Promise‹any›
Protected
executeActionOrRule¶
▸ executeActionOrRule(actionOrRulePath
: any): Promise‹any›
Inherited from IView.executeActionOrRule
Called to excecute action or rule from control.
Parameters:
Name | Type |
---|---|
actionOrRulePath |
any |
Returns: Promise‹any›
action or rule reference
formatRule¶
▸ formatRule(): any
Getter for the control format rule, if any.
Returns: any
The control's format rule path.
getValue¶
▸ getValue(): any
Called to get the control value from the observable.
Returns: any
The control's value.
initialize¶
▸ initialize(controlData
: IControlData): void
Inherited from IView.initialize
Called to initialize view. props object passed in containing all relevant properties and view's context.
Parameters:
Name | Type |
---|---|
controlData |
IControlData |
Returns: void
Abstract
observable¶
▸ observable(): IObservable
Called by control factory to ask for a specific Observable implementation.
Returns: IObservable
- IObservable implementation.
onDataChanged¶
▸ onDataChanged(action
: any, result
: any): void
Parameters:
Name | Type |
---|---|
action |
any |
result |
any |
Returns: void
onDismissingModal¶
▸ onDismissingModal(): void
Inherited from IView.onDismissingModal
Returns: void
onDisplayingModal¶
▸ onDisplayingModal(isFullPage
: boolean): void
Inherited from IView.onDisplayingModal
Parameters:
Name | Type |
---|---|
isFullPage |
boolean |
Returns: void
onNavigatedFrom¶
▸ onNavigatedFrom(pageExists
: boolean): void
Inherited from IView.onNavigatedFrom
Parameters:
Name | Type |
---|---|
pageExists |
boolean |
Returns: void
onNavigatedTo¶
▸ onNavigatedTo(initialLoading
: boolean): void
Inherited from IView.onNavigatedTo
Parameters:
Name | Type |
---|---|
initialLoading |
boolean |
Returns: void
onNavigatingFrom¶
▸ onNavigatingFrom(pageExists
: boolean): void
Inherited from IView.onNavigatingFrom
Parameters:
Name | Type |
---|---|
pageExists |
boolean |
Returns: void
onNavigatingTo¶
▸ onNavigatingTo(initialLoading
: boolean): void
Inherited from IView.onNavigatingTo
Parameters:
Name | Type |
---|---|
initialLoading |
boolean |
Returns: void
onPageLoaded¶
▸ onPageLoaded(initialLoading
: boolean): void
Inherited from IView.onPageLoaded
Called when parent page is being loaded.
Parameters:
Name | Type | Description |
---|---|---|
initialLoading |
boolean | Whether or not it is being loaded for the first time |
Returns: void
onPageUnloaded¶
▸ onPageUnloaded(pageExists
: boolean): void
Inherited from IView.onPageUnloaded
Called when the parent page is unloaded.
Parameters:
Name | Type | Description |
---|---|---|
pageExists |
boolean | Whether or not the page still exists on the stack after unload |
Returns: void
onPress¶
▸ onPress(...args
: any[]): void
Parameters:
Name | Type |
---|---|
...args |
any[] |
Returns: void
page¶
▸ page(): any
Getter for the Page the control resides on.
Returns: any
The control's page.
redraw¶
▸ redraw(): void
Called to refresh the control
Returns: void
Abstract
setContainer¶
▸ setContainer(container
: IControl): any
Parameters:
Name | Type |
---|---|
container |
IControl |
Returns: any
setStyle¶
▸ setStyle(cssClassName?
: string): void
Called to tell the control to set its styles.
Parameters:
Name | Type |
---|---|
cssClassName? |
string |
Returns: void
setValidationProperty¶
▸ setValidationProperty(key
: string, value
: any): void
Called to set the propertis of the validation view
Parameters:
Name | Type | Description |
---|---|---|
key |
string | The validation property's key |
value |
any | The value |
Returns: void
Abstract
setValue¶
▸ setValue(value
: any, notify
: boolean, isTextValue?
: boolean): Promise‹any›
Sets the controls value. Abstract because each control must validate or throw the incoming value.
throws
if the value supplied doesn't work out!
Parameters:
Name | Type |
---|---|
value |
any |
notify |
boolean |
isTextValue? |
boolean |
Returns: Promise‹any›
valueResolver¶
▸ valueResolver(): ValueResolver
Inherited from IView.valueResolver
Getter for the value resolver.
Returns: ValueResolver
The value resolver.
Abstract
view¶
▸ view(): any
Called to retrieve the view to display.
Returns: any
- View to display
viewIsNative¶
▸ viewIsNative(): boolean
Overrides IView.viewIsNative
Called to find out if the view is implemented in a native plugin. If the view is a custom native view, this needs to be overriden and set to true so it can be correctly added to our layout.
Returns: boolean
- true if it is a custom native view, false if not.