📄 ort.h
字号:
#include <oratypes.h>#endif#ifndef ORO_ORACLE#include <oro.h>#endif#ifndef OCI_ORACLE#include <oci.h>#endif#ifndef ORT_ORACLE#define ORT_ORACLE/*---------------------------------------------------------------------------*//* SHORT NAMES SUPPORT SECTION *//*---------------------------------------------------------------------------*/#ifdef SLSHORTNAME/* the following are short names that are only supported on IBM mainframes with the SLSHORTNAME defined. With this all subsequent long names will actually be substituted with the short names here */#define OCITypeArrayByName ortgatyp#define OCITypeAttrByName ortgabn#define OCITypeAttrNext ortgabi#define OCITypeAttrs ortgtna#define OCITypeByRef ortgtbrf#define OCITypeCollElem ortgcel#define OCITypeCollExtTypeCode ortgcsqt#define OCITypeCollSize ortgcne#define OCITypeCollTypeCode ortgdttc#define OCITypeElem ortado#define OCITypeElemCharSetForm ortgscform#define OCITypeElemCharSetID ortgscid#define OCITypeElemDefaultValue ortgpdv#define OCITypeElemExtTypeCode ortgasqt#define OCITypeElemLength ortgsl#define OCITypeElemName ortganm#define OCITypeElemNumPrec ortgnp#define OCITypeElemNumScale ortgns#define OCITypeElemParamMode ortgpmo#define OCITypeElemParameterizedType ortgpa#define OCITypeElemType ortgaty#define OCITypeElemTypeCode ortgatc#define OCITypeIter ortitr#define OCITypeIterFree ortifre#define OCITypeIterNew ortinew#define OCITypeIterSet ortiset#define OCITypeMethod ortmdo#define OCITypeMethodByName ortgmbn#define OCITypeMethodEncap ortgmen#define OCITypeMethodFlags ortgmfl#define OCITypeMethodMap ortgmmap#define OCITypeMethodName ortgmnm#define OCITypeMethodNext ortgmbi#define OCITypeMethodOrder ortgmor#define OCITypeMethodOverload ortgmno#define OCITypeMethodParams ortgmnp#define OCITypeMethods ortgtnm#define OCITypeName ortgtme#define OCITypeParamByName ortgpbn#define OCITypeParamPos ortgpps#define OCITypeSchema ortgtsch#define OCITypeTypeCode ortgttc#define OCITypeVTInit ortvini#define OCITypeVTInsert ortvins#define OCITypeVTSelect ortvsel#define OCITypeVersion ortgtvn#endif /* SLSHORTNAME *//*============================*/ /* PUBLIC TYPES AND CONSTANTS *//*============================*//*----------------------------- TYPE DESCRIPTION ----------------------------*//* * OCIType - OCI Type Description Object * * The contents of an 'OCIType' is private/opaque to clients. Clients just * need to declare and pass 'OCIType' pointers in to the type manage * functions. * The pointer points to the type in the object cache. Thus, clients don't * need to allocate space for this type and must NEVER free the pointer to the * 'OCIType'. */typedef struct OCIType OCIType;/*------------------------- TYPE ELEMENT DESCRIPTION ------------------------*//* * OCITypeElem - OCI Type Element object * * The contents of an 'OCITypeElem' is private/opaque to clients. Clients just * need to declare and pass 'OCITypeElem' pointers in to the type manager * functions. * * 'OCITypeElem' objects contains type element information such as the numeric * precision for example, for number objects, and the number of elements for * arrays. * They ARE used to describe type attributes, collection elements, * method parameters, and method results. Hence they are pass in or returned * by attribute, collection, and method parameter/result accessors. */typedef struct OCITypeElem OCITypeElem;/*--------------------------- METHOD DESCRIPTION ---------------------------*//* * OCITypeMethod - OCI Method Description object * * The contents of an 'OCITypeMethod' is private/opaque to clients. Clients * just need to declare and pass 'OCITypeMethod' pointers in to the type * manager functions. * The pointer points to the method in the object cache. Thus, clients don't * need to allocate space for this type and must NEVER free the pointer to * the 'OCITypeMethod'. */typedef struct OCITypeMethod OCITypeMethod;/*--------------------------- TYPE ACCESS ITERATOR --------------------------*//* * OCITypeIter- OCI Type Iterator * * The contents of an 'orti' is private/opaque to clients. Clients just * need to declare and pass 'orti' pointers in to the type manager functions. * The iterator is used to retreive MDO's and ADO's that belong to the TDO * one at a time. It needs to be allocated by the 'OCITypeIterNew()' function * call and deallocated with the 'OCITypeIterFree()' function call. */typedef struct OCITypeIter OCITypeIter;/*==================*//* PUBLIC FUNCTIONS *//*==================*//*--------------------------------------------------------------------------*//* ITERATOR *//*--------------------------------------------------------------------------*//*-----------------------_- OCITypeIterNew ---------------------------------*//* ** OBSOLETE ** */#if !defined(__STDC__) && !defined(__cplusplus) /* K&R C - not ANSI C */sword OCITypeIterNew(/*_ OCIEnv *env, OCIError *err, OCIType *tdo, OCITypeIter **iterator_ort _*/);#elsesword OCITypeIterNew( OCIEnv *env, OCIError *err, OCIType *tdo, OCITypeIter **iterator_ort );#endif/* NAME: OCITypeIterNew - OCI Iterator NEW PARAMETERS: env (IN/OUT) - OCI environment handle initialized in object mode err (IN/OUT) - error handle. If there is an error, it is recorded in 'err' and this function returns OCI_ERROR. The error recorded in 'err' can be retrieved by calling OCIErrorGet(). tdo (IN) - pointer to the pinned type in the object cache to initialize the iterator with iterator_ort (OUT) - pointer to the pointer to the new iterator created DESCRIPTION: Create a new instance of a method/attribute iterator and initalize it's values. RETURNS: OCI_SUCCESS if the function completes successfully. OCI_INVALID_HANDLE if 'env' or 'err' is null. OCI_ERROR if 1) any of the required parameters is null. 2) error while allocating space for the iterator.*//*------------------------ OCITypeIterSet ---------------------------------*//* ** OBSOLETE ** */#if !defined(__STDC__) && !defined(__cplusplus) /* K&R C - not ANSI C */sword OCITypeIterSet(/*_ OCIEnv *env, OCIError *err, OCIType *tdo, OCITypeIter *iterator_ort _*/);#elsesword OCITypeIterSet( OCIEnv *env, OCIError *err, OCIType *tdo, OCITypeIter *iterator_ort );#endif/* NAME: OCITypeIterSet - OCI Iterator SET PARAMETERS: env (IN/OUT) - OCI environment handle initialized in object mode err (IN/OUT) - error handle. If there is an error, it is recorded in 'err' and this function returns OCI_ERROR. The error recorded in 'err' can be retrieved by calling OCIErrorGet(). tdo (IN) - pointer to the pinned type in the object cache to initialize the iterator with iterator_ort (IN/OUT) - pointer to the iterator to set DESCRIPTION: Initializes the iterator. This is used to reset the state of the iterator. RETURNS: OCI_SUCCESS if the function completes successfully. OCI_INVALID_HANDLE if 'env' or 'err' is null. OCI_ERROR if 1) any of the required parameters is null.*//*------------------------ OCITypeIterFree ---------------------------------*//* ** OBSOLETE ** */#if !defined(__STDC__) && !defined(__cplusplus) /* K&R C - not ANSI C */sword OCITypeIterFree(/*_ OCIEnv *env, OCIError *err, OCITypeIter *iterator_ort _*/);#elsesword OCITypeIterFree( OCIEnv *env, OCIError *err, OCITypeIter *iterator_ort );#endif/* NAME: OCITypeIterFree - OCI Iterator FREe PARAMETERS: env (IN/OUT) - OCI environment handle initialized in object mode err (IN/OUT) - error handle. If there is an error, it is recorded in 'err' and this function returns OCI_ERROR. The error recorded in 'err' can be retrieved by calling OCIErrorGet(). iterator_ort (IN/OUT) - pointer to the iterator to free DESCRIPTION: Free space allocated for the iterator. RETURNS: OCI_SUCCESS if the function completes successfully. OCI_INVALID_HANDLE if 'env' or 'err' is null. OCI_ERROR if 1) any of the required parameters is null. 2) error while freeing the iterator, probably bad iterator pointer.*//*--------------------------------------------------------------------------*//* TYPE GET *//*--------------------------------------------------------------------------*//* ** OBSOLETE ** */#if !defined(__STDC__) && !defined(__cplusplus) /* K&R C - not ANSI C */sword OCITypeByName(/*_ OCIEnv *env, OCIError *err, CONST OCISvcCtx *svc, CONST oratext *schema_name, ub4 s_length, CONST oratext *type_name, ub4 t_length, CONST oratext *version_name, ub4 v_length, OCIDuration pin_duration, OCITypeGetOpt get_option, OCIType **tdo _*/);#else /* ANSI C */sword OCITypeByName( OCIEnv *env, OCIError *err, CONST OCISvcCtx *svc, CONST oratext *schema_name, ub4 s_length, CONST oratext *type_name, ub4 t_length, CONST oratext *version_name, ub4 v_length, OCIDuration pin_duration, OCITypeGetOpt get_option, OCIType **tdo );#endif/* NAME: OCITypeByName - OCI Get the most current version of an existing TYPe by name. PARAMETERS: env (IN/OUT) - OCI environment handle initialized in object mode err (IN/OUT) - error handle. If there is an error, it is recorded in 'err' and this function returns OCI_ERROR. The error recorded in 'err' can be retrieved by calling OCIErrorGet(). svc (IN) - OCI service handle schema_name (IN, optional) - name of schema associated with the type. By default, the user's schema name is used. s_length (IN) - length of the 'schema_name' parameter type_name (IN) - name of the type to get t_length (IN) - length of the 'type_name' parameter version_name (IN, optional) - user readable version of the type. Pass (oratext *)0 for the most current version. v_length (IN) - length of version_name in bytes. Should be 0 if the most current version is to be retrieved. pin_duration (IN) - pin duration (e.g. until the end of current transaction). See 'oro.h' for a description of each option. get_option (IN) - options for loading the types. It can be one of two values: OCI_TYPEGET_HEADER for only the header to be loaded, or OCI_TYPEGET_ALL for the TDO and all ADO and MDOs to be loaded. tdo (OUT) - pointer to the pinned type in the object cache DESCRIPTION: Get a pointer to a version of the existing type associated with schema/type name.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -