OSI/MHS Gateway Programmatic Interface (GPI) Programming Guide
Writing Your Program
OSI/MHS Gateway Programmatic Interface (GPI) Programming Guide—424822-001
5-16
Building a Root Object
a superobject (on any level), you must first copy that object, so that the copy has a
new object identifier.
Despite these constraints, you have great flexibility in using GPI procedures to build
objects.
•
You can create subobjects in any order. This is true regardless of subobject class, or
the level on which the subobjects are contained within the root object hierarchy.
•
A subobject does not have to be populated with its attributes before being inserted as
an attribute into its superobject. Attributes can be added to any object anytime prior
to transferring out the root object.
•
You can create an object of any class that is initialized with default attributes. You
can create an object with its defaults and then replace any or all defaults.
•
At any time during the building process, you can also use any of the object
management inspecting, decomposing, and copying procedures.
Table 5-2 shows the recommended sequence for building a root object. Note that the
sequence suggests a “top down” approach. After the root object is created (a mandatory
first step), subobjects on successively lower levels are created and inserted into the root
object. The process continues until the root object is fully formed.
Note. In addition to rules listed above, there is one limitation on use of the GPI library memory
segment: You can have no more than 15 root objects in the GPI library memory at the same
time, regardless of the number of sessions (there is no limit on the number of objects that are
not root objects).
Table 5-2. Sequence for Building a Root Object
Task Explanation Procedure(s) Used
1 Create root object with defaults GPI_OM_CREATE_
2 Edit default root attributes, as necessary GPI_OM_REMOVE_ ,
GPI_OM_INSERT_
1
3 Create first-level subobjects with defaults GPI_OM_CREATE_
4 Insert first-level subobjects into root object GPI_OM_INSERT_
5 Edit default attributes of the subobjects, as necessary GPI_OM_REMOVE_ ,
GPI_OM_INSERT_
1
6 Create next-level subobjects with defaults GPI_OM_CREATE_
7 Insert next-level subobjects into the previous level GPI_OM_INSERT_
8 Edit default attributes of the subobjects, as necessary GPI_OM_REMOVE_ ,
GPI_OM_INSERT_
1
9 Continue adding sublevels until root object is completed Same as Steps 6, 7, and 8
1
GPI_OM_WRITE_ can be used to write long strings to a value.
Note: At any time, inspecting, decomposing, and copying procedures can also be used.