Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

<aspect> 
Anchor
aspect
aspect

XML Syntax<aspect name="" class="">
DescriptionThis element used defines lifeCycles as aspects.
Type 
Default Value 
Fixed Values 
Mandatory/OptionalMandatory
Samples 

...

<configuration> 
Anchor
configuration
configuration

XML Syntax<configuration type="">
DescriptionThis element describes the way of lifecycle configuration is setup
Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalMandatory

...

Back to Top ^

...

<scxml> 
Anchor
scxml
scxml

XML Syntax<scxml xmlns="" version="" initialstate=""/>
Description

This is the element that contains the new, SCXML-based configuration. SCXML is one of many standards supported by the WSO2 Governance Registry. Read more on Supported APIs & Standards for a complete list of standards supported by WSO2 Governance Registry.

Up to this point of the configuration, there can be only one of each of the elements described above. They all provide meta data about the lifecycle (name, class, and other information). The elements that appear after this one contain the actual configuration.

Type 
Default Value 
Fixed Values 
Mandatory/OptionalMandatory

...

Back to Top ^

...

<state> 
Anchor
state
state

XML Syntax<state id="">
Description

The state element defines the states of the lifecycle. A lifecycle can have multiple states, and in the configuration, more than one state element can be given.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalMandatory

...

<datamodel> 
Anchor
datamodel
datamodel

XML Syntax<datamodel>
Description

This element contains all the custom elements which are defined in the lifeCycles model. The SCXML specification allows users to define a data model to a state and this extension is used to define custom elements.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalOptional

...

Back to Top ^

...

<data> 
Anchor
data
data

XML Syntax<data name=""/>
Description

Custom data elements (according to the SCXML specification) serve to define check items, transition permission, transition validations, transition scripts, transition executions, and transition UIs. This element describes the data of its child elements.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalOptional

...

Back to Top ^

...

<item> 
Anchor
item
item

XML Syntax<item name="" forEvent=""/>
Description

These elements contain the check items for each state. There can be more than one of these elements.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalOptional

...

<permissions> 
Anchor
permissions
permissions

XML Syntax<permissions>
Description

The permissions element defines permissions for that specified action and hold more than one child element which defines permissions. Under check items, the permissions element defines the users that have the capability of checking (check/uncheck) that check item. If a user does not have permissions to check a check item, then the management console will display that specific item in disabled mode. The idea behind this is to let the user know that there are some more check items in that state, but that he or she does not have permission to check them (so as to avoid user confusion).

Type 
Default Value 
Fixed Values 
Mandatory/OptionalOptional

...

<permission> 
Anchor
permission
permission

XML Syntax<permission roles=""/>
Description

This element is a child element of the permissions element and will define the roles that have permissions to do the specified action. Here, the attribute roles accepts a comma (",") separated list and these roles should be present in Governance Registry.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalOptional

...

<validations> 
Anchor
validations
validations

XML Syntax 
Description

Defines the validations that need to be completed for each action. This element can contain one or more validation elements. Check Item Validators are one of many well-defined extension points supported by the WSO2 Governance Registry. Read more on Supported Extension Points for a complete list of extension points supported by WSO2 Governance Registry.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalOptional

...

<validation> 
Anchor
validation
validation

XML Syntax<validation forEvent="" class=""/>
Description

Validations are an important part of lifeCycles. The validation element defines the event and the validation class that has to be invoked at runtime.

Type 
Default Value 
Fixed Values 
Mandatory/OptionalOptional

...

<parameter>
Anchor
parameter
parameter

XML Syntax<parameter name="" value=""/>
Description

The parameter elements are used to give parameters to the validation and execution classes. It is up to the user to define the name value pairs, and the parameter element has attributes to define these values. A validation element or an execution element can have more than one parameter element and it is up to the user code to handle this. The underline implementation of the DefaultLifeCycle class will pass all the parameters in a map object.

Type 
Default Value 
Fixed Values 
Mandatory/OptionalOptional

...

Back to Top ^

...

<js>
Anchor
js
js

XML Syntax 
Description

Governance Registry lifeCycle configuration has the ability to allow JavaScript functions to execute on both the server side and the client side. The js element defines the scripts that need to be executed for different events.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalOptional

...

<console>
Anchor
console
console

XML Syntax<console function=""/>
Description

Defines the JavaScript function that needs to be executed on the client side.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalOptional

...

<script>
Anchor
script
script

XML Syntax<script type="text/javascript"/>
Description

Contains the actual JavaScript code segment. A user has the ability to define any code segment here.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalOptional

...

<server>
Anchor
server
server

XML Syntax<server function=""/>
Description

This is the same as the console function and the only difference is that this element defines the scripts that need to be executed on the server side.

Type 
Default Value 
Fixed Values 
Mandatory/OptionalOptional

...

<Execution>
Anchor
execution
execution

XML Syntax<execution forEvent="" class=""/>
Description

An executor is business logic that is executed once a state transition happens in a lifecycle. The execution element defines the event and the execution class that will be invoked at runtime.

Type 
Default Value 
Fixed Values 
Mandatory/OptionalOptional

...

<parameter>
Anchor
execution
execution

XML Syntax<parameter name="" value=""/>
Description

The name attribute defines the name of the parameter and value attribute defines that the value hold by the parameter. This parameter element defined under the <execution>  element.

Type 
Default Value 
Fixed Values 
Mandatory/OptionalOptional

...

Back to Top ^

...

<ui>
Anchor
ui
ui

XML Syntax<ui forEvent="" href=""/>
Description

A UI element is a mechanism to associate a user interface with a particular event during a given transition. This provides a convenient way for a user to pass input that would be utilized when performing a transition. Note that, for the value of href, it will not accept any external reference link for the value. It is required to provide a relative path in the carbon server as the value of href.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalOptional

...

<transition>
Anchor
transition
transition

XML Syntax<transition event="" target=""/>
Description

Defines the transitions of a state. In Governance Registry 4.1.1 onwards, users are allowed to define the transitions (the name and the target state) instead of using static transitions.

Previously, the configuration did not have a direct method of defining the transition event names or, most importantly, the target of the transition. There were only two transitions that were supported by default.

With the new, SCXML-based configuration model, any number of transitions from one state are supported. Also, this model has the capacity to define the target state of the transition and the name of the event as well.

Type 
Default ValueN/A
Fixed Values 
Mandatory/OptionalMandatory

...