Loading Transaction Agent Framework (TAF) Partial Extract Schemas
If you want to utilize the example Transaction Agent Framework (TAF) from the Erewhon demonstration system, you can load partial extract schemas into your own new schemas, as follows. (The "Integrating the Transaction Agent Framework (TAF)" topic and its associated topics elsewhere in this document provide an overview and diagrams of the TAF concepts.)
You can download the partial extract files from https://github.com/jadesoftwarenz.
-
After creating your model schema, before you start adding classes, select the Load command from the Schema menu to open the Load Options dialog. (Alternatively, you can click the Load icon on the toolbar or use the Ctrl+Alt+L shortcut keys.)
An example of the Load Options dialog is shown in the following diagram.
-
On the Load Options dialog:
-
Click the Browse button at the right of the Schema File Name text box and then select the TAFModelSchema_PartialExtract.scm file.
-
Click the Browse button at the right of the Forms File Name text box and then select the TAFModelSchema_PartialExtract.ddx file.
-
To avoid the need for a reorganization during the schema load process, select the Load into the existing current schema version load style in the combo box.
-
Click the Advanced button to open the Advanced Load Options dialog.
-
-
On the Advanced Load Options dialog, select Your‑model‑schema‑name in the Target Schema combo box and then click the OK button to return to the Load Options dialog.
-
Click the OK button on the Load Options dialog to load the schema into your model schema.
Some progress dialogs are displayed while the load progresses. After a short time, a message box should be displayed stating that the load completed successfully.
-
Click the OK button on the load completion message box.
-
To avoid an error during the load process, some methods had to be put on the “wrong” class. This causes several methods to be in error after the load process, and a message box is displayed advising you of this. Click the No button on this message box, because the error list will be opened later in this instruction following the addition of a property and the moving of some methods.
-
Select your model schema and then open a Class Browser by selecting the Classes command from the Browse menu (or by using the Ctrl+B shortcut key). For details about the Class Browser, see "Using the Class List, Primitive Type List, or Interface List Window", elsewhere in this chapter.
-
In the Class Browser that is then displayed:
-
Click the + icon to the left of the Application class to expand that tree entry.
-
Click the + icon at the left of the RootSchemaApp class to expand that tree entry.
-
Repeat the above two steps on each subsequent subclass until the Your‑model‑schema‑name subclass of the Application class is visible and then select that subclass.
-
-
Select the Add Reference command from the Properties menu, to open the Define Reference dialog.
-
On the Define Reference dialog that is then displayed, add a new reference property called myNotificationManager of type TAFNotificationManager as shown in the following image, and then click the OK button.
-
Select the TAFObject class in the Class Browser.
-
The following three methods now need to be moved from the TAFObject class to the Your‑model‑schema-name subclass of the Application class.
-
exception_handler_ignore_4_1090_1072_1046_with_context_and_flag
-
tafAbortTransaction
-
tafCommitTransaction
Move these one at a time, as follows.
-
Hold down the Shift key on the keyboard.
-
Mouse down on one of the three methods in the above list.
-
Drag the mouse so that the mouse pointer changes from an arrow to an alternative icon to indicate that you are performing a move action. When the arrow on the alternative icon is positioned over the Your‑model‑schema-name subclass of the Application class, release the mouse button.
-
A message is then displayed, confirming the move of the method. Click the Yes button on this message box.
-
Repeat this step for the other two methods.
-
-
Use the Status List command on the Browse menu to open the Method Status List dialog.
-
The default options on the Method Status List dialog are suitable, so click the Search button to scan for methods in error in Your‑model‑schema-name.
-
The Method Status List form that is then displayed shows all of the methods that are still in an error state.
These methods will all compile successfully now that the myNotificationManager property has been added to the Your‑model‑schema-name class and the three methods moved from the TAFObject class to the Your‑model‑schema-name subclass.
The first method will be selected already, so press F8 to compile that method and it will select the next method in the list. Keep pressing F8 to compile methods until the Method Status List form has no methods displayed in the list, and then close the form.
-
Select your view schema in the Schema Browser and then select the Load command from the Schema menu to open the Load Options dialog (shown in step 2 of this instruction).
On the Load Options dialog:
-
Click the Browse button at the right of the Schema File Name text box to select the TAFViewSchema_PartialExtract.scm file.
-
Click the Browse button at the right of the Forms File Name text box to select the TAFViewSchema_PartialExtract.ddx file.
-
Select a load style of Load into the existing current schema version to avoid the need for a reorganization during the schema load.
-
Click the Advanced button to open the Advanced Load Options dialog.
-
-
On the Advanced Load Options dialog that is then displayed, select the Your-view-schema-name subschema of the Your‑model‑schema-name in the Target Schema combo box and then click the OK button to return to the Load Options dialog.
-
Click the OK button on the Load Options dialog to load the schema into your view schema.
-
Some progress dialogs are displayed while the load is progressing. After a short time you should see a load completed successfully message box. Click OK on this message box.
You now have a TAFBaseForm class to use as the parent class for all your application forms. The TAFBaseForm class provides methods for interacting with the TAF classes in the model schema.
"
2022.0.01 and higher















