ut_ox_base.c File Reference

ComplexObject FUNCTIONS OGX_. More...

#include "../xa/MS_Def0.h"
#include <stdio.h>
#include <math.h>
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>
#include "../ut/ut_cast.h"
#include "../ut/ut_geo.h"
#include "../ut/ut_gtypes.h"
#include "../ut/ut_obj.h"
#include "../ut/ut_memTab.h"
#include "../ut/ut_txt.h"
#include "../ut/ut_ox_base.h"

Data Structures

struct  Relocdat
 relocationDataRecord More...

Functions

int OGX_deloc_adr (void **vpt, Relocdat *rd)
 typedef_MemTab (ObjRange)
int OGX_ox_ato1 (ObjGX *oxo, int *ausTyp, double *ausTab)
ObjGXOGX_oxm_copy_obj (Memspc *mSpo, void *obji, int typ, int iNr, int isolate)
ObjGXOGX_oxm_copy_ox (Memspc *mSpo, ObjGX *oTab, int iNr, int isolate)
int OGX_ox_copy__ (void *objo, long *oSiz, void *obji, int isolate)
int OGX_ox_copy_obj (void **objo, long *oSiz, void *obji, int typ, int iNr, int isolate)
int OGX_ck_reloc (int typ)
int OGX_deloc__ (ObjGX *oxi, long mSiz)
int OGX_reloc__ (ObjGX *oxi, long mSiz)
int OGX_reloc_ox (void *obj1, int typ, int iNr, Relocdat *rd)
int OGX_reloc_adr (void **vpt, Relocdat *rd)
long OGX_siz__ (ObjGX *oxi, int isolate)
int OGX_siz_obj (long *oSiz, void *obj1, int typ, int iNr, int isolate)
int OGX_DEB_dump__ (void *obj1)
int OGX_DEB_dump_obj (void *obj1, int typ, int iNr, int deloc)
int OGX_DEB_dump_stru (void *obj, int typ, char *txt)

Detailed Description

ComplexObject FUNCTIONS OGX_.

=====================================================
Liste_Funktionen_Beginn:

OGX_SET_OBJ             create complexObject (ObjGX) from binObj (struct)
OGX_SET_INDEX           create complexObject (ObjGX) from DB-Obj (dbTyp,dbInd)
OGX_SET_INT             create complexObject (ObjGX) from DB-Obj (dbTyp,dbInd)
OGX_GET_INT             get index out of complexObject

OGX_ox_copy_ox          complexObj-group from a group of objs.
OGX_ox_ato1             complexObj from 1 atomicObj (ausTyp/ausTab)

OGX_oxm_copy_ox         copy iNr complexObjects into Memspc (serialize)
OGX_oxm_copy_obj        copy (serialize) obj into a Memspc
OGX_ox_copy__           copy (serialize) a ObjGX-Tree into a single memChunk.
OGX_ox_copy_obj
OGX_ck_reloc            check if struct is relocatable without modifications

OGX_deloc__             serialize (make all pointers relative)
OGX_reloc__             deserialize (relocate all pointers)
OGX_reloc_ox            relocate objTree.
OGX_reloc_adr           relocate a pointer.

OGX_siz__               return size of complete ObjGX-Tree; 
OGX_siz_obj             return size of complete ObjGX-Tree;

OGX_DEB_dump__
OGX_DEB_dump_obj
OGX_DEB_dump_stru       dump stru and its pointers, do not resolve.

-------------- TESTFUNCTIONS --------------
OGX_tst__               test 
OGX_tst_load_ox         get a test-ObjGX-tree

Liste_Funktionen_Ende:
=====================================================

Functions resolving ObjGX-Trees:
OGX_ox_copy_obj
OGX_reloc_ox
OGX_DEB_dump_obj + OGX_DEB_dump_stru
OGX_siz_obj
UTRA_app_oTab
UPRJ_app_obj UNUSED - see UPRJ_app__

Function Documentation

int OGX_deloc_adr ( void **  vpt,
Relocdat rd 
)
typedef_MemTab ( ObjRange   ) 
int OGX_ox_ato1 ( ObjGX oxo,
int *  ausTyp,
double *  ausTab 
)

    OGX_ox_ato1             complexObj from 1 atomicObj (ausTyp/ausTab)
   
    Output:
      RetCod: pointer to the complexObj inside mSp1
   
    typical complexObj-Records:
     Typ_Val   Typ_Val    ((double*)*value)  ((double)value)
     Typ_<typ> Typ_Index  ((int)DB-ind)

ObjGX* OGX_oxm_copy_obj ( Memspc *  mSpo,
void *  obji,
int  typ,
int  iNr,
int  isolate 
)
ObjGX* OGX_oxm_copy_ox ( Memspc *  mSpo,
ObjGX oTab,
int  iNr,
int  isolate 
)

    copy iNr complexObjects into Memspc (serialize, no delocate)
    Input:
      oTab     iNr complexObjects
      iNr      size of oTab
      isolate  0=do not resolv (copy) DB-objects; 1=copy the data of DB-objects
    Output:
      mSpo
      RetCod:  NULL   Error (not enough mem in mSpo)
               else   adress of primary struct ObjGX in mSpo

int OGX_ox_copy__ ( void *  objo,
long *  oSiz,
void *  obji,
int  isolate 
)

    copy (serialize) a ObjGX-Tree into a single memChunk.
    Does not resolve DB-Objects (see isolate).
    Does not delocate (see OGX_deloc__).
    Input:
      obji   complexObj to be copied
      objo   where to save obji
      oSiz   free space at objo
      isolate  0=do not resolv (copy) DB-objects; 1=copy the data of DB-objects
    Output:
      objo   copy of obji
      oSiz   oSiz is reduced (new free size)
    RetCode:
      -1     out of memory-Error
      else   size of data stored in objo
   
    see also UTO_copy_tab DB_store_obj UTRA_app_obj UTO_write_obj

int OGX_ox_copy_obj ( void **  objo,
long *  oSiz,
void *  obji,
int  typ,
int  iNr,
int  isolate 
)

    copy (serialize) a ObjGX-Tree into a single memChunk.
    Does not delocate (see OGX_deloc__).
    Input:
      obji     struct(s) of type <typ> to be copied
      objo     copy of obji
      oSiz     free space at objo
      isolate  0=do not resolv (copy) DB-objects; 1=copy the data of DB-objects
    Output:
      objo     next free position
      oSiz     oSiz is reduced (new free size)
    RetCode:
      -1       out of memory-Error
   
    see also UTO_copy_tab DB_store_obj UTRA_app_obj UTO_write_obj

int OGX_ck_reloc ( int  typ  ) 
int OGX_deloc__ ( ObjGX oxi,
long  mSiz 
)
int OGX_reloc__ ( ObjGX oxi,
long  mSiz 
)
int OGX_reloc_ox ( void *  obj1,
int  typ,
int  iNr,
Relocdat rd 
)

    delocate objTree.
    make all pointers relativ to rd->oPos (the startPos of this objTree).

int OGX_reloc_adr ( void **  vpt,
Relocdat rd 
)
long OGX_siz__ ( ObjGX oxi,
int  isolate 
)
int OGX_siz_obj ( long *  oSiz,
void *  obj1,
int  typ,
int  iNr,
int  isolate 
)
int OGX_DEB_dump__ ( void *  obj1  ) 
int OGX_DEB_dump_obj ( void *  obj1,
int  typ,
int  iNr,
int  deloc 
)
int OGX_DEB_dump_stru ( void *  obj,
int  typ,
char *  txt 
)
Generated on Fri Apr 6 09:40:10 2012 for gCAD3D by  doxygen 1.6.3