SaMakeObjectCall(3tlib)


SaMakeObjectCall -- perform object calls returing a list of BMIP responses

Synopsis

SaMakeObjectCall objectCall

Description

SaMakeObjectCall performs an object call returning a list of BMIP responses. In some cases, direct object operations result in OSA or framework errors that throw stacks rather than returning a BMIP response containing the stack. SaMakeObjectCall handles such cases by building and returning a BMIP response in order to give the application an even more consistent interface.

When unrecognized errors are thrown, SaMakeObjectCall will throw as well, leaving the burden on the application itself. These are rare cases and most likely indicate a serious coding error in the OSA.

Arguments


objectCall
a properly formatted SCOadmin object operation.

Return values

A list of 0 or more BMIP responses. Callers can check for the presense of an error stack in each BMIP response using BmipResponseErrorIsPresent.

Diagnostics

Most errors will generate an error stack that is returned with a BMIP response. In the case of a list of two or more BMIP responses, (such as an object operation on multiple objects) it is possible that only a subset of BMIP responses contain error stacks. The caller should iterate through the list checking each BMIP response.

SaMakeObjectCall can throw an error in the event of an unrecognized throw from a lower level (framework or OSA). SaMakeObjectCall should be used in conjunction with ErrorCatch either at the same or higher level.

Examples

# build the object operation
set objCall [list ObjectCreate [list sco $class] $instance $attrs]

# make the call set bmipList [SaMakeObjectCall $objCall]

# iterate through the list of bmip's foreach bmip $bmipList {

# did we get an error? if [BmipResponseErrorIsPresent $bmip] { ErrorThrow [BmipResponseErrorStack bmip] }

# successful operation process bmip . . . }

References

Bmip(3tlib), Object(3tlib).
25 April 2004
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004