Package com.highdeal.iec.hci
Class JavaActionModel
java.lang.Object
com.highdeal.iec.hci.ActionModelImpl
com.highdeal.iec.hci.JavaActionModel
- All Implemented Interfaces:
com.highdeal.hci.XMLMarshallable,com.highdeal.iec.hci.ActionModel,com.highdeal.iec.hci.ContextualModel
public class JavaActionModel
extends com.highdeal.iec.hci.ActionModelImpl
This
Java class represents a Java action that can be set in a scenario file of an SAP CC Import/Export Connector (IEC) application;
Your customized class can be processed by the IEC application at runtime.
Implementation in Your Customized IEC Application
You must develop a Java class that extends the JavaTask abstract class.
During the execution of a scenario, two methods are invoked by the running IEC application:
setProperties(Properties)to receive the properties of initialization of your Java task; The properties are those defined in this model.JavaTask.execute(DataCollection)to treat theDataCollectionspecified in argument; DataCollection contains data (such as ExtendedChargeableItem).
It can access to other features regarding the following implementations:
JavaTaskStateListener- The method
stateTerminated(..)is invoked when the last action has fully treated the current DataCollection - The method
stateRejected(..)is invoked when an action rejected the current DataCollection. The reasons are explained in the arguments - The method
stateFiltered(..)is invoked when an action filtered the current DataCollection is fully treated JavaTaskIteratorJavaTaskInitializable- Invoke the method
setUp(DataCollection collection)before:- The invocation of the
executemethod when the Java task is not a JavaTaskIterator - The iterations when the Java task is not a JavaTaskIterator
- The invocation of the
- Invoke the method
tearDown(DataCollection collection)after:- The invocation of the
executemethod when the Java task is not a JavaTaskIterator - The iterations when the Java task is not a JavaTaskIterator
- The invocation of the
- While the method "boolean hasNext(DataCollection collection)" returns
true,invoke the method "execute(DataCollection collection)" with the same DataCollection
Additional Information
Consult the primary help of the SAP CC Connector Administration Tool (CAT Tool) in the related documentation about how to create and configure a scenario and how to add a Java Action component to this scenario file.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final StringFields inherited from class com.highdeal.iec.hci.ActionModelImpl
ACTION_XMLTAG, children, DESCRIPTION_XMLATTR, EMPTYCHILD_XMLTAG, TYPE_XMLATTR, UID_XMLATTRFields inherited from interface com.highdeal.iec.hci.ContextualModel
SAVE, USAGE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidGets the class name of the Java task to perform.Gets the properties to initialize the Java task.booleanisValid(int level) voidsetAttributes(com.highdeal.hci.XMLAttributes atts) voidsetClassName(String className) Sets the class name of the Java task to perform.voidsetNodeContext(Vector props, Vector renamedProps, Vector lastPropertyNames, Vector deletedProps) voidsetProperties(Properties props) Sets the properties to initialize the Java task.voidxmlDescription(com.highdeal.hci.XMLOutputter output) Methods inherited from class com.highdeal.iec.hci.ActionModelImpl
addCharacterData, addChild, addContextProperty, contextPropertyRemoved, contextPropertyRenamed, countChildren, getChildAt, getChildren, getContext, getDescription, getMaxChildCount, getName, getNodeContext, getParent, insertChildAt, isNull, marshal, removeChildAt, removeContextProperty, renameContextProperty, setChildAt, setDescription, setMaxChildCount, setName, setParent, toString, toXML, updateContext, updateContext, xmlTag
-
Field Details
-
PROPERTY
- See Also:
-
CONTEXT_PROPERTY
- See Also:
-
TYPE
- See Also:
-
NAME
- See Also:
-
VALUE
- See Also:
-
CLASSNAME
- See Also:
-
-
Constructor Details
-
JavaActionModel
public JavaActionModel()Creation of an instance of this model.
-
-
Method Details
-
setClassName
Sets the class name of the Java task to perform.- Parameters:
className- The class name of the Java task to perform
-
getClassName
Gets the class name of the Java task to perform.- Returns:
- The class name of the Java task to perform
-
setProperties
Sets the properties to initialize the Java task.- Parameters:
props- The properties to initialize the Java task
-
getProperties
Gets the properties to initialize the Java task.- Returns:
- The properties to initialize the Java task
-
setNodeContext
-
isValid
public boolean isValid(int level) - Specified by:
isValidin interfacecom.highdeal.iec.hci.ContextualModel- Overrides:
isValidin classcom.highdeal.iec.hci.ActionModelImpl- Parameters:
level-ContextualModel.SAVEorContextualModel.USAGElevel.- Returns:
- Returns true if the model is valid, false otherwise.
-
setAttributes
public void setAttributes(com.highdeal.hci.XMLAttributes atts) - Specified by:
setAttributesin interfacecom.highdeal.hci.XMLMarshallable- Overrides:
setAttributesin classcom.highdeal.iec.hci.ActionModelImpl
-
addChild
- Specified by:
addChildin interfacecom.highdeal.hci.XMLMarshallable- Overrides:
addChildin classcom.highdeal.iec.hci.ActionModelImpl
-
xmlDescription
public void xmlDescription(com.highdeal.hci.XMLOutputter output) - Overrides:
xmlDescriptionin classcom.highdeal.iec.hci.ActionModelImpl
-