home *** CD-ROM | disk | FTP | other *** search
- /* Copyright (c) 1995 by Oracle Corporation. All Rights Reserved.
- *
- * yodefs.h - Oracle OMX Object Layer Stub Support
- */
-
- #ifndef YODEFS_ORACLE
- #define YODEFS_ORACLE
-
- #ifndef SYSX_ORACLE
- #include <sysx.h>
- #endif
- #ifndef YS_ORACLE
- #include <ys.h>
- #endif
-
- #ifndef YOTK_ORACLE
- #include <yotk.h>
- #endif
-
- EXTC_START
-
- #ifndef CORBA_Object_delcared
- #define CORBA_Object_delcared
- typedef dvoid *CORBA_Object;
- #endif
-
- typedef struct yoevm yoevm;
-
- /* Environment */
- struct yoenv
- {
- ub4 _maximum;
- ub4 _length;
- yoevm *_buffer;
- };
- typedef struct yoenv yoenv;
-
- typedef struct yocur yocur;
-
- typedef struct CosTransactions_PropagationContext
- CosTransactions_PropagationContext;
-
- /*
- * Pre-defined Sequences
- */
- typedef struct {
- ub4 _maximum; ub4 _length; sb2 *_buffer;
- } YCIDL_sequence_sb2;
-
- typedef struct {
- ub4 _maximum; ub4 _length; sb4 *_buffer;
- } YCIDL_sequence_sb4;
-
- typedef struct {
- ub4 _maximum; ub4 _length; ub2 *_buffer;
- } YCIDL_sequence_ub2;
-
- typedef struct {
- ub4 _maximum; ub4 _length; ub4 *_buffer;
- } YCIDL_sequence_ub4;
-
- typedef struct {
- ub4 _maximum; ub4 _length; boolean *_buffer;
- } YCIDL_sequence_boolean;
-
- typedef struct {
- ub4 _maximum; ub4 _length; char *_buffer;
- } YCIDL_sequence_char;
-
- typedef struct {
- ub4 _maximum; ub4 _length; ub1 *_buffer;
- } YCIDL_sequence_ub1;
-
- typedef struct {
- ub4 _maximum; ub4 _length; yoany *_buffer;
- } YCIDL_sequence_yoany;
-
- typedef struct {
- ub4 _maximum; ub4 _length; char * *_buffer;
- } YCIDL_sequence_string;
-
- typedef struct {
- ub4 _maximum; ub4 _length; sysb8 *_buffer;
- } YCIDL_sequence_sysb8;
-
- typedef struct {
- ub4 _maximum; ub4 _length; yotk * *_buffer;
- } YCIDL_sequence_TypeCode;
-
- /* typecodes for predefined sequences */
- CONST yotk *yoTc_seq_sb2_getTC(void);
- CONST yotk *yoTc_seq_sb4_getTC(void);
- CONST yotk *yoTc_seq_ub2_getTC(void);
- CONST yotk *yoTc_seq_ub4_getTC(void);
- CONST yotk *yoTc_seq_boolean_getTC(void);
- CONST yotk *yoTc_seq_char_getTC(void);
- CONST yotk *yoTc_seq_ub1_getTC(void);
- CONST yotk *yoTc_seq_yoany_getTC(void);
- CONST yotk *yoTc_seq_TypeCode_getTC(void);
- CONST yotk *yoTc_seq_string_getTC(void);
- CONST yotk *yoTc_seq_sysb8_getTC(void);
-
- #define YCTC_YCIDL_sequence_sb2 yoTc_seq_sb2_getTC()
- #define YCTC_YCIDL_sequence_sb4 yoTc_seq_sb4_getTC()
- #define YCTC_YCIDL_sequence_ub2 yoTc_seq_ub2_getTC()
- #define YCTC_YCIDL_sequence_ub4 yoTc_seq_ub4_getTC()
- #define YCTC_YCIDL_sequence_boolean yoTc_seq_boolean_getTC()
- #define YCTC_YCIDL_sequence_char yoTc_seq_char_getTC()
- #define YCTC_YCIDL_sequence_ub1 yoTc_seq_ub1_getTC()
- #define YCTC_YCIDL_sequence_yoany yoTc_seq_yoany_getTC()
- #define YCTC_YCIDL_sequence_TypeCode yoTc_seq_TypeCode_getTC()
- #define YCTC_YCIDL_sequence_string yoTc_seq_string_getTC()
- #define YCTC_YCIDL_sequence_sysb8 yoTc_seq_sysb8_getTC()
-
- /*
- * PRIVATE DECLARATIONS
- */
- typedef struct yopar yopar;
-
- #define YOMODE_INVALID 0
- #define YOMODE_RETURN 1
- #define YOMODE_IN 2
- #define YOMODE_OUT 3
- #define YOMODE_INOUT 4
- #define YOMODE_EXCEPT 5
-
- /* DISABLE check_naming */
- struct yopar
- {
- sb4 mode; /* return, in, out, in/out */
- yotk *tk; /* type code */
- ub4 sz; /* size of type */
- };
- /* ENABLE check_naming */
-
- /*
- * yoSendReq - send a request
- *
- * DESCRIPTION
- * Sends a method request to the specified object reference.
- * The or argument specifies the object reference to which the request is to
- * be sent. The op argument is the method to be invoked. The response
- * argument indicates if a response is expected from the implementation. The
- * uevt argument contains an event which will be triggered upon completion of
- * the request. args is the number of arguments to be passed to the method.
- * pars specifies the types of the parameters for this method. The values
- * parameter is an array of pointers to the parameter values for the method.
- * Hence all parameter values are passed by reference.
- *
- * This function will be called primarily from client stubs which have been
- * generated by the IDL compiler. This function may also be used by those
- * wishing to dynamically make method requests.
- *
- * This function will not block under any circumstances. All results are
- * returned via uevt.
- */
- void yoSendReq(CONST dvoid *ref, yoenv *ev, CONST char *op, boolean response,
- ysevt *uevt, sword args, CONST yopar *pars, dvoid **values);
-
- /*
- * yoParsSize - Size parameter descriptions
- *
- * DESCRIPTION
- * Fills in the size field in the yopar structure with the proper machine
- * dependant size based on the parameters typecode. This function should only
- * be called on parameter descriptions obtained from the IRF. The IDL compiler
- * normal fills in the size field.
- */
- void yoParsSize(yopar *pars);
-
- /* private for stubs */
- typedef void (*yogfp)(void);
- typedef yogfp (*yowiden)(ub4 op, dvoid *impldef, CONST ysid *intf);
- typedef struct yopard yopard;
- struct yopard
- {
- CONST char *id;
- yopar pars[1];
- };
-
- dvoid *yoLocalObj(dvoid *ref, yowiden *widener);
- yopard *yoPardCreate(CONST char *id, ub4 cnt);
- void yoParsSet(yopard *pd);
- yopar *yoParsGet(CONST char *id);
-
- EXTC_END
- #endif /* YODEFS_ORACLE */
-