Engine for Web Applications

org.cote.js.wires

Class Index

static org.cote.js.wires.wire

version 1.9.18

Static initializer for new Wire instances.

This class participates in the engine library.

Index

Method Index

Methods

newInstance

Creates and returns a new Wire instance.

Syntax

w = newInstance( )

Returns

w as Wire: Returns a new Wire instance.

org.cote.js.wires.Wire

version 1.9.18

Service for extending PrimitiveWire utility, auto-linking PrimitiveWires together, and reusing PrimitiveWires.

This class participates in the engine library.

Index

Property Index

Method Index

Properties

object_config

Object API structure for storing sub structures: object_config.pointers and object_config.status.

Syntax

object = object.object_config

object_id

Unique instance identifier.

Syntax

String = object.object_id

object_type

The type of this object.

Syntax

String = object.object_type

object_version

Version of the object class.

Syntax

String = object.object_version

ready_state

Object load and execution state. Follows: 0 unitialized, 1 through 3 variant, 4 ready, 5 destroyed.

Syntax

int = object.ready_state

Methods

getCanSignal

Returns whether the underlying PrimitiveWire objects signal to each other based on commonality between actions and handlers.

Syntax

b = getCanSignal( )

Returns

b as boolean: Bit indicating whether PrimitiveWires signal to each other.

getObjectId

Returns the unique id of the object.

Syntax

i = getObjectId( )

Returns

i as String: The unique object instance id.

getObjectType

Returns the type of the object.

Syntax

t = getObjectType( )

Returns

t as String: The type of the object instance.

getObjectVersion

Returns the version of the object.

Syntax

v = getObjectVersion( )

Returns

v as String: The version of the object instance.

getPointers

Returns the object_config.pointers sub structure.

Syntax

o = getPointers( )

Returns

o as object: The object_config.pointers substructure.

getReadyState

Returns the state of the object.

Syntax

s = getReadyState( )

Returns

s as int: The object ready state.

getStatus

Returns the object_config.status sub structure.

Syntax

o = getStatus( )

Returns

o as object: The object_config.status substructure.

hardWire

Invokes the action of a hardened wire.

Syntax

i = hardWire( o, i, aa, ha, xp, x, yp, y, ep, e, ea )

Parameters

Returns

i as String: Returns the identifier of the newly created hardened wire.

invoke

Invokes a specified function that exists on the wire.

Syntax

v = invoke( a, x, f, b, o )

Parameters

Returns

v as variant: Returns false if unsuccessful, true otherwise.

invokeHardWireAction

Invokes the action of a hardened wire.

Syntax

r = invokeHardWireAction( o, i, a )

Parameters

Returns

r as boolean: Returns true if the chain completed successfully, false if otherwise.

invokeHardWireHandler

Invokes the handler of a hardened wire.

Syntax

r = invokeHardWireHandler( o, i, a )

Parameters

Returns

r as boolean: Returns true if the chain completed successfully, false if otherwise.

invokePrimitive

Invokes a wire, causing the action-handler chain to be processed.

Syntax

r = invokePrimitive( a, i, b, z )

Parameters

Returns

r as boolean: Returns true if the chain completed successfully, false if otherwise.

primitiveWire

Creates and returns a PrimiteWire based on the specified parameters.

Syntax

i = primitiveWire( xp, x, yp, y, ep, e )

Parameters

Returns

i as String: Returns the identifier of the PrimitiveWire object.

setCanSignal

Specifies whether the underlying PrimitiveWire objects signal to each other based on commonality between actions and handlers.

Syntax

void setCanSignal( b )

Parameters

sigterm

Sends termination signal to destroy object.

Syntax

void sigterm( )

wire

Creates and returns a wire based on the specified parameters. This function creates an underlying PrimitiveWire as well as creating linkage to be connected with other wires.

Syntax

i = wire( xp, x, yp, y, ep, e )

Parameters

Returns

i as String: Returns the identifier of the wire object.