NAME
om_instance - Determines whether an object
is an instance of a particular class or any of its subclasses
SYNOPSIS
#include <xom.h>
OM_return_code om_instance(
OM_object subject,
OM_object_identifier class,
OM_boolean *instance);
PARAMETERS
Input
- subject
-
The subject that remains accessible.
- class
-
Identifies the class in question.
Output
- instance
-
Indicates whether the subject is an instance of the specified
class or any of its subclasses. This result is present if and only if the
value of the OM_return_code is set to OM_SUCCESS.
DESCRIPTION
The om_instance() function determines
whether a service-generated
public or private object (the subject) is an instance
of a particular class or any of its subclasses.
NOTES
The client can determine an object's class (C)
by simply inspecting the object, using programming language constructs if
the object is public or om_get() if it is private.
This function is useful in that it reveals that an
object is an instance of the specified class, even if C
is a subclass of that class.
RETURN VALUES
- OM_return_code
-
Indicates whether the function succeeded and,
if not, why not. If the function is
successful, the value of OM_return_code is set to OM_SUCCESS;
if the function fails, it has one of the error values listed in this reference page.
The exact constants for
OM_return_code are defined in the xom.h
header file (see the xom.h(4xom) reference page).
ERRORS
- OM_FUNCTION_INTERRUPTED
-
- OM_MEMORY_INSUFFICIENT
-
- OM_NETWORK_ERROR
-
- OM_NO_SUCH_CLASS
-
- OM_NO_SUCH_OBJECT
-
- OM_NO_SUCH_SYNTAX
-
- OM_NOT_THE_SERVICES
-
- OM_PERMANENT_ERROR
-
- OM_POINTER_INVALID
-
- OM_SYSTEM_ERROR
-
- OM_TEMPORARY_ERROR
-
© 1990-1996, Transarc Corporation