Back to index

lightning-sunbird  0.9+nobinonly
Classes | Defines | Typedefs | Enumerations | Functions | Variables
xpt_xdr.h File Reference
#include "xpt_struct.h"
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  XPTState
struct  XPTDatapool
struct  XPTCursor

Defines

#define XPT_PREAMBLE_(cursor, addrp, pool, size, new_curs, already)
#define XPT_PREAMBLE_NO_ALLOC(cursor, addrp, pool, size, new_curs, already)
#define XPT_ERROR_HANDLE(arena, free_it)

Typedefs

typedef
typedefPR_BEGIN_EXTERN_C
struct 
XPTState
typedef struct XPTDatapool
typedef struct XPTCursor
typedef struct XPTHashTable

Enumerations

enum  XPTMode { XPT_ENCODE, XPT_DECODE }
enum  XPTPool { XPT_HEADER = 0, XPT_DATA = 1 }

Functions

 XPT_PUBLIC_API (PRBool) XPT_DoString(XPTArena *arena
 XPT_PUBLIC_API (XPTState *) XPT_NewXDRState(XPTMode mode
 XPT_PUBLIC_API (void) XPT_DestroyXDRState(XPTState *state)
 XPT_PUBLIC_API (PRUint32) XPT_GetOffsetForAddr(XPTCursor *cursor
 XPT_PUBLIC_API (void *) XPT_GetAddrForOffset(XPTCursor *cursor

Variables

XPTCursorcursor
XPTCursor XPTString ** strp
nsIDiidp
PRInt64u64p
PRUint32u32p
PRUint16u16p
PRUint8u8p
XPTCursor XPTHeader ** headerp
XPTCursor XPTHeader PRUint32ide_offset
char * data
char PRUint32 len
XPTPool pool
PRUint32 offset
PRUint32data_offsetp
PRUint32 data_offset
voidaddr

Class Documentation

struct XPTState

Definition at line 95 of file xpt_xdr.h.

Collaboration diagram for XPTState:
Class Members
XPTArena * arena
PRUint32 data_offset
XPTMode mode
PRUint32 next_cursor
XPTDatapool * pool
struct XPTDatapool

Definition at line 103 of file xpt_xdr.h.

Collaboration diagram for XPTDatapool:
Class Members
PRUint32 allocated
PRUint32 count
char * data
XPTHashTable * offset_map
struct XPTCursor

Definition at line 110 of file xpt_xdr.h.

Collaboration diagram for XPTCursor:
Class Members
PRUint8 bits
PRUint32 offset
XPTPool pool
XPTState * state

Define Documentation

#define XPT_ERROR_HANDLE (   arena,
  free_it 
)
Value:
error:                                                                       \
    if (cursor->state->mode == XPT_DECODE)                                    \
    XPT_FREEIF(arena, free_it);                                               \
    return PR_FALSE;

Definition at line 202 of file xpt_xdr.h.

#define XPT_PREAMBLE_ (   cursor,
  addrp,
  pool,
  size,
  new_curs,
  already 
)
Value:
XPTMode mode = cursor->state->mode;                                       \
    if (!(mode == XPT_ENCODE || XPT_Do32(cursor, &new_curs.offset)) ||        \
        !CheckForRepeat(cursor, (void **)addrp, pool,                         \
                        mode == XPT_ENCODE ? size : 0u, &new_curs,            \
                        &already) ||                                          \
        !(mode == XPT_DECODE || XPT_Do32(cursor, &new_curs.offset)))          \
        return PR_FALSE;                                                      \
    if (already)                                                              \
        return PR_TRUE;                                                       \

Definition at line 186 of file xpt_xdr.h.

#define XPT_PREAMBLE_NO_ALLOC (   cursor,
  addrp,
  pool,
  size,
  new_curs,
  already 
)
Value:
{                                                                           \
    XPT_PREAMBLE_(cursor, addrp, pool, size, new_curs, already)               \
  }

Definition at line 197 of file xpt_xdr.h.


Typedef Documentation

typedef struct XPTCursor

Definition at line 51 of file xpt_xdr.h.

typedef struct XPTDatapool

Definition at line 50 of file xpt_xdr.h.

typedef struct XPTHashTable

Definition at line 54 of file xpt_xdr.h.

typedef typedefPR_BEGIN_EXTERN_C struct XPTState

Definition at line 49 of file xpt_xdr.h.


Enumeration Type Documentation

enum XPTMode
Enumerator:
XPT_ENCODE 
XPT_DECODE 

Definition at line 85 of file xpt_xdr.h.

enum XPTPool
Enumerator:
XPT_HEADER 
XPT_DATA 

Definition at line 90 of file xpt_xdr.h.

             {
    XPT_HEADER = 0,
    XPT_DATA = 1
} XPTPool;

Function Documentation


Variable Documentation

Definition at line 148 of file xpt_xdr.h.

Definition at line 57 of file xpt_xdr.h.

XPTPool char** data

Definition at line 118 of file xpt_xdr.h.

Definition at line 145 of file xpt_xdr.h.

Definition at line 142 of file xpt_xdr.h.

Definition at line 81 of file xpt_xdr.h.

Definition at line 81 of file xpt_xdr.h.

Definition at line 66 of file xpt_xdr.h.

Definition at line 118 of file xpt_xdr.h.

Definition at line 124 of file xpt_xdr.h.

Definition at line 121 of file xpt_xdr.h.

XPTCursor char** strp

Definition at line 57 of file xpt_xdr.h.

Definition at line 75 of file xpt_xdr.h.

Definition at line 72 of file xpt_xdr.h.

Definition at line 69 of file xpt_xdr.h.

Definition at line 78 of file xpt_xdr.h.