IBM WebSphere Multichannel Bank Transformation Toolkit, Version 7.1

Reference

Context exceptions

Contexts throw the following exceptions:
Table 1. Context exceptions
Exception Reasons/Actions
DSEObjectNotFound Exception The keyed collection does not contain the requested element. This exception may be the result of an incorrect element name or path to the element.
DSEInvalidArgument Exception The method was invoked using incorrect parameters. This exception may be the result of using a collection name instead of a data field name in the parameters.
DSEInvalidRequest Exception An operation cannot be performed because of the current context tree. This exception may be the result of trying to chain a context to a nonexistent parent.

Context external definitions

The following table shows the tags (corresponding to classes) and tag attributes (corresponding to class variables) used for externalizing Context objects in the toolkit contexts definition file:
Table 2. <context> tag attributes
Tag Attribute Description
id Identifies the context instance. This attribute provides access to the data. This is a linkable tag.
type Identifies the class used to represent the context. The type attribute allows several contexts of the same type to be part of the contexts structure. For example, there can be two operational mode contexts: one for real operations and the other for operator training. This is a linkable tag. 
parent Identifies the parent context. The system uses this attribute to build the chain of contexts and allow the application to have access to the resources available in the whole assigned chain inside the context tree. The parent attribute is not related to the qualified name used by the application to search for resources in a specific context.. This is a linkable tag.
addToDynamicKColl Determines what happens when the context's keyed collection is dynamic and the toolkit needs to add a data element to the keyed collection.

When this attribute is false (the default value), the setValueAt method, when invoked, searches the context tree for the first element that matches the key. If the method finds the element, it modifies the value. If it does not find the element, it dynamically creates the element in the current context.

When this attribute is true, one of the following happens:
  • If the element does not exist in the keyed collection of the context, the toolkit adds a DataField to the keyed collection. The toolkit obtains the DataField's name from the key parameter of the setValueAt method. The toolkit obtains the DataField's value from the value parameter of same method.
  • If the element already exists in the keyed collection of the context, the toolkit overwrites its value without checking whether the element exists in contexts higher in the context tree.
Table 3. <refKColl> tag attributes
Tag Attribute Description
refId Contains a reference to a keyed collection. This is a linkable tag.
Table 4. <refType> tag attributes
Tag Attribute Description
refId Contains a reference to a keyed collection defined as a Type in the  types definition file. This is a linkable tag.
Table 5. <iniValue> tag attributes
Tag Attribute Description
name Identifies the data field to be initialized. This is an optional tag. If you use it, you must define it inside a refKColl tag or a refType tag.
value Contains the value of the data field.
Table 6. <refService> tag attributes
Tag Attribute Description
refId Contains a reference to a service. This is a linkable tag.
type Identifies the service type.
alias Contains the alias of the service instance.

For information about linkable tags, see Tag linking.



Feedback