XBinder  Version 2.9.x
Classes | Macros | Typedefs | Functions
rtxContext.h File Reference

Common run-time context definitions. More...

#include "rtxsrc/rtxDList.h"
#include "rtxsrc/rtxStack.h"

Go to the source code of this file.

Classes

struct  OSRTErrLocn
 Run-time error location structure. More...
 
struct  OSRTErrInfo
 Run-time error information structure. More...
 
struct  OSRTBuffer
 Run-time message buffer structure. More...
 
struct  OSRTBufSave
 Structure to save the current message buffer state. More...
 
struct  OSBufferIndex
 This structure can be used as an index into the buffer. More...
 
struct  OSCTXT
 Run-time context structure. More...
 

Macros

#define OSNOWHITESPACE   0x00400000 /* Turn off indentation whitesapce */
 Turn off unnecessary whitespace in text output. More...
 
#define rtxCtxtGetMsgPtr(pctxt)   (pctxt)->buffer.data
 This macro returns the start address of an encoded message. More...
 
#define rtxCtxtGetMsgLen(pctxt)   (pctxt)->buffer.byteIndex
 This macro returns the length of an encoded message. More...
 
#define rtxCtxtTestFlag(pctxt, mask)   (((pctxt)->flags & mask) != 0)
 This macro tests if the given bit flag is set in the context. More...
 
#define rtxCtxtPeekElemName(pctxt)
 This macro returns the last element name from the context stack. More...
 
#define rtxByteAlign(pctxt)
 This macro will byte-align the context buffer.
 
#define rtxCtxtSetProtocolVersion(pctxt, value)   (pctxt)->version = value
 This macro sets the protocol version in the context. More...
 

Typedefs

typedef int(* OSFreeCtxtAppInfoPtr) (struct OSCTXT *pctxt)
 OSRTFreeCtxtAppInfoPtr is a pointer to pctxt->pAppInfo free function, The pctxt->pAppInfo (pXMLInfo and pASN1Info) should contain the pointer to a structure and its first member should be a pointer to an appInfo free function.
 
typedef int(* OSResetCtxtAppInfoPtr) (struct OSCTXT *pctxt)
 OSRTResetCtxtAppInfoPtr is a pointer to pctxt->pAppInfo reset function, The pctxt->pAppInfo (pXMLInfo and pASN1Info) should contain the pointer to a structure and its second member should be a pointer to appInfo reset function.
 
typedef void(* OSFreeCtxtGlobalPtr) (struct OSCTXT *pctxt)
 OSRTFreeCtxtGlobalPtr is a pointer to a memory free function. More...
 

Functions

EXTERNRT int rtxInitContext (OSCTXT *pctxt)
 This function initializes an OSCTXT block. More...
 
EXTERNRT int rtxInitContextExt (OSCTXT *pctxt, OSMallocFunc malloc_func, OSReallocFunc realloc_func, OSFreeFunc free_func)
 This function initializes an OSCTXT block. More...
 
EXTERNRT int rtxInitThreadContext (OSCTXT *pctxt, const OSCTXT *pSrcCtxt)
 This function initializes a context for use in a thread. More...
 
EXTERNRT int rtxInitContextUsingKey (OSCTXT *pctxt, const OSOCTET *key, OSSIZE keylen)
 This function initializes a context using a run-time key. More...
 
EXTERNRT int rtxInitContextBuffer (OSCTXT *pctxt, OSOCTET *bufaddr, OSSIZE bufsiz)
 This function assigns a message buffer to a context block. More...
 
EXTERNRT int rtxCtxtSetBufPtr (OSCTXT *pctxt, OSOCTET *bufaddr, OSSIZE bufsiz)
 This function is used to set the internal buffer pointer for in-memory encoding or decoding. More...
 
EXTERNRT OSSIZE rtxCtxtGetBitOffset (OSCTXT *pctxt)
 This function returns the total bit offset to the current element in the context buffer. More...
 
EXTERNRT int rtxCtxtSetBitOffset (OSCTXT *pctxt, OSSIZE offset)
 This function sets the bit offset in the context to the given value. More...
 
EXTERNRT OSSIZE rtxCtxtGetIOByteCount (OSCTXT *pctxt)
 This function returns the count of bytes either written to a stream or memory buffer. More...
 
EXTERNRT int rtxCheckContext (OSCTXT *pctxt)
 This function verifies that the given context structure is initialized and ready for use. More...
 
EXTERNRT void rtxFreeContext (OSCTXT *pctxt)
 This function frees all dynamic memory associated with a context. More...
 
EXTERNRT void rtxCopyContext (OSCTXT *pdest, OSCTXT *psrc)
 This function creates a copy of a context structure. More...
 
EXTERNRT void rtxCtxtSetFlag (OSCTXT *pctxt, OSUINT32 mask)
 This function is used to set a processing flag within the context structure. More...
 
EXTERNRT void rtxCtxtClearFlag (OSCTXT *pctxt, OSUINT32 mask)
 This function is used to clear a processing flag within the context structure. More...
 
EXTERNRT int rtxCtxtPushArrayElemName (OSCTXT *pctxt, const OSUTF8CHAR *elemName, OSSIZE idx)
 This function is used to push an array element name onto the context element name stack. More...
 
EXTERNRT int rtxCtxtPushElemName (OSCTXT *pctxt, const OSUTF8CHAR *elemName)
 This function is used to push an element name onto the context element name stack. More...
 
EXTERNRT int rtxCtxtPushElemNameCopy (OSCTXT *pctxt, const OSUTF8CHAR *elemName)
 This function is used to push a copy of the given element name onto the context element name stack. More...
 
EXTERNRT int rtxCtxtPushTypeName (OSCTXT *pctxt, const OSUTF8CHAR *typeName)
 This function is used to push a type name onto the context element name stack. More...
 
EXTERNRT OSBOOL rtxCtxtPopArrayElemName (OSCTXT *pctxt)
 This function pops the last element name from the context stack. More...
 
EXTERNRT const OSUTF8CHAR * rtxCtxtPopElemName (OSCTXT *pctxt)
 This function pops the last element name from the context stack. More...
 
EXTERNRT void rtxCtxtPopElemNameCopy (OSCTXT *pctxt)
 This function pops the last element name from the context stack and frees the associated memory. More...
 
EXTERNRT const OSUTF8CHAR * rtxCtxtPopTypeName (OSCTXT *pctxt)
 This function pops the type name from the context stack. More...
 
EXTERNRT OSBOOL rtxCtxtContainerHasRemBits (OSCTXT *pctxt)
 Return true iff there are bits remaining to be decoded in the current length-constrained container, which is possibly the outer PDU. More...
 
EXTERNRT OSBOOL rtxCtxtContainerEnd (OSCTXT *pctxt)
 Return true if we are at the end of container - neither having more bits remaining nor having overrun it; otherwise return false. More...
 
EXTERNRT OSSIZE rtxCtxtGetContainerRemBits (OSCTXT *pctxt)
 Return the number of bits remaining to be decoded in the current length-constrained container, which is possibly the outer PDU. More...
 
EXTERNRT int rtxCtxtPushContainerBytes (OSCTXT *pctxt, OSSIZE bytes)
 Notify the runtime layer of the start of decoding of a length-constrained container of a given length. More...
 
EXTERNRT int rtxCtxtPushContainerBits (OSCTXT *pctxt, OSSIZE bits)
 Notify the runtime layer of the start of decoding of a length-constrained container of a given length. More...
 
EXTERNRT void rtxCtxtPopContainer (OSCTXT *pctxt)
 Notify the runtime layer of the end of decoding of a length-constrained container of the given length. More...
 
EXTERNRT void rtxCtxtPopAllContainers (OSCTXT *pctxt)
 Pop all containers from the container stack. More...
 
EXTERNRT void rtxMemHeapSetFlags (OSCTXT *pctxt, OSUINT32 flags)
 This function sets flags to a heap. More...
 
EXTERNRT void rtxMemHeapClearFlags (OSCTXT *pctxt, OSUINT32 flags)
 This function clears memory heap flags. More...
 
EXTERNRT int rtxCtxtMarkBitPos (OSCTXT *pctxt, OSSIZE *ppos)
 This function saves the current bit position in a message buffer. More...
 
EXTERNRT int rtxCtxtResetToBitPos (OSCTXT *pctxt, OSSIZE pos)
 This function resets a message buffer back to the given bit position. More...
 
EXTERNRT int rtxMarkPos (OSCTXT *pctxt, OSSIZE *ppos)
 This function saves the current position in a message buffer or stream. More...
 
EXTERNRT int rtxResetToPos (OSCTXT *pctxt, OSSIZE pos)
 This function resets a message buffer or stream back to the given position. More...
 
EXTERNRT const char * rtxCtxtGetExpDateStr (OSCTXT *pctxt, char *buf, OSSIZE bufsiz)
 This function will get the license expiration date for a time-limited license. More...
 
EXTERNRT void rtxLicenseClose (void)
 Finish with current license and free internal resources. More...
 

Detailed Description

Common run-time context definitions.

Definition in file rtxContext.h.