Steps are where the work of a CIM plugin is outlined. Each step should consist of a logical group that can be presented to the user as a single entity. When the step is complete, the following events have taken place:
Relevant information is displayed to the user about what CIM will do
Input has been collected from the user
Validators may have checked the input or system state
Tasks are prepared for execution
A navigation option is chosen by the user
To insert a step, place the following XML snippet inside a process
tag:
<step id="step_ID
" insert-after="other_step_ID
" type="standard_or_base
" class="class_name
"> <title/> <detail/> <property name="some_name
"> <value>value
</value> </property> <navoption> <option default="true"> <label>Next Step</label> <command type="EXECUTE_STEP_TASKS" /> <command type="NEXT_STEP" /> </option> <option > <label>Redo Step</label> <command type="DROP_STEP_TASKS" /> <command type="REDO_STEP" /> </option> </navoption> </step>
Steps have the following attributes:
id
—Uniquely identifies the step to the framework.insert-after
—When combining wizards, identifies the step ID in the base file after which this step should be inserted.type
—Can bestandard
ortemplate
. This attribute is optional, and the default isstandard
. Astandard
step acts as part of a simple, linear process with a tightly restricted set of user options, and relies on default worker objects for its behavior. Atemplate
step permits dynamic generation of options and greater flexibility, but requires you to write your own components; this is provided for use with future versions of CIM.class
—If a template step, provide the class used to implement the step. This attribute is optional.
Steps contain the following elements:
title
—Identifies the step in the user interface.detail
—Additional text that provides any information the user needs to know in order to complete the step.property
— Argument to pass to a template step; not used in standard steps. This allows a single template to be reused, displaying different information depending on the property. For an example, see the Database Configuration menu in CIM, in which a single template displays different options depending on the database selected.navoption
—Provides a framework of options from which the user can select. As part of navigation, commands are fired, some of which are purely navigational, and others of which have to do with tasks that are prepared during the step. Navigation options include Next Step, Redo Step, Jump to Third Step, etc. The default selection is indicated by the attributedefault="true"
, and is executed if no value is entered and the user presses the Enter key.navoptionprovider
—For dynamic navigation, provide the Java class that supplies this feature for your script.
For an example, see the Example CIM Plugin section of this chapter, or review the wizards.xml
file located at <ATG11dir>/CIM/plugins/base
in your Oracle Commerce Platform installation.