/************************************************/ /* */ /* File : ./userconv.h */ /* Description : tl compiler definitions */ /* */ /* Command : conv */ /* Comment : Convert various formats */ /* */ /* Note : This file was created from a tl file. */ /* Do not modify by hand. */ /* */ /* Created : Mon 12. May 1997 12:32:00 */ /* */ /************************************************/ #ifndef TLC_TCLC_conv_USER_H #define TLC_TCLC_conv_USER_H #define TL_OK 0 typedef struct { int nr; /* associated nr. */ char *str; /* read string */ } _TL_siset; /* set/iset data structure */ /*****************************************/ /* Constants */ /*****************************************/ #define cef_center 3 #define cef_right 2 #define cef_left 1 /*****************************************/ /* User types */ /*****************************************/ typedef _TL_siset ITeformat; /* intype iset */ typedef struct { char * indata; /* param: intype string */ unsigned int length; /* param: intype natural */ ITeformat format; /* option: intype idf. */ char format_present; /* boolean: option format present */ char fillchar; /* option: intype char */ char fillchar_present; /* boolean: option fillchar present */ char * result; /* outtype string */ char *errorstr; /* initialized ==NULL */ } t_expand; /* data structure */ /* conv expand data function*/ /* return TL_OK iff no error */ int fexpand(t_expand *data); typedef struct { unsigned int indata; /* param: intype natural */ unsigned int result; /* outtype natural */ char *errorstr; /* initialized ==NULL */ } t_nat2nat; /* data structure */ /* conv nat2nat data function*/ /* return TL_OK iff no error */ int fnat2nat(t_nat2nat *data); typedef struct { unsigned int indata; /* param: intype natural */ unsigned int result; /* outtype hex */ char *errorstr; /* initialized ==NULL */ } t_nat2hex; /* data structure */ /* conv nat2hex data function*/ /* return TL_OK iff no error */ int fnat2hex(t_nat2hex *data); typedef struct { unsigned int indata; /* param: intype natural */ unsigned int result; /* outtype octal */ char *errorstr; /* initialized ==NULL */ } t_nat2octal; /* data structure */ /* conv nat2octal data function*/ /* return TL_OK iff no error */ int fnat2octal(t_nat2octal *data); typedef struct { unsigned int indata; /* param: intype natural */ unsigned int result; /* outtype binary */ char *errorstr; /* initialized ==NULL */ } t_nat2binary; /* data structure */ /* conv nat2binary data function*/ /* return TL_OK iff no error */ int fnat2binary(t_nat2binary *data); typedef struct { unsigned int indata; /* param: intype natural */ unsigned int result; /* outtype compact */ char *errorstr; /* initialized ==NULL */ } t_nat2compact; /* data structure */ /* conv nat2compact data function*/ /* return TL_OK iff no error */ int fnat2compact(t_nat2compact *data); typedef struct { unsigned int indata; /* param: intype hex */ unsigned int result; /* outtype natural */ char *errorstr; /* initialized ==NULL */ } t_hex2nat; /* data structure */ /* conv hex2nat data function*/ /* return TL_OK iff no error */ int fhex2nat(t_hex2nat *data); typedef struct { unsigned int indata; /* param: intype binary */ unsigned int result; /* outtype natural */ char *errorstr; /* initialized ==NULL */ } t_binary2nat; /* data structure */ /* conv binary2nat data function*/ /* return TL_OK iff no error */ int fbinary2nat(t_binary2nat *data); typedef struct { unsigned int indata; /* param: intype octal */ unsigned int result; /* outtype natural */ char *errorstr; /* initialized ==NULL */ } t_octal2nat; /* data structure */ /* conv octal2nat data function*/ /* return TL_OK iff no error */ int foctal2nat(t_octal2nat *data); typedef struct { unsigned int indata; /* param: intype compact */ unsigned int result; /* outtype natural */ char *errorstr; /* initialized ==NULL */ } t_compact2nat; /* data structure */ /* conv compact2nat data function*/ /* return TL_OK iff no error */ int fcompact2nat(t_compact2nat *data); typedef struct { char indata; /* param: intype boolean */ char result; /* outtype boolean */ char *errorstr; /* initialized ==NULL */ } t_bool2bool; /* data structure */ /* conv bool2bool data function*/ /* return TL_OK iff no error */ int fbool2bool(t_bool2bool *data); typedef struct { char indata; /* param: intype boolean */ char result; /* outtype nboolean */ char *errorstr; /* initialized ==NULL */ } t_bool2nbool; /* data structure */ /* conv bool2nbool data function*/ /* return TL_OK iff no error */ int fbool2nbool(t_bool2nbool *data); typedef struct { char indata; /* param: intype boolean */ char result; /* outtype cboolean */ char *errorstr; /* initialized ==NULL */ } t_bool2cbool; /* data structure */ /* conv bool2cbool data function*/ /* return TL_OK iff no error */ int fbool2cbool(t_bool2cbool *data); typedef struct { double indata; /* param: intype real */ unsigned int maxfract; /* option: intype natural */ char maxfract_present; /* boolean: option maxfract present */ char * result; /* outtype string */ char *errorstr; /* initialized ==NULL */ } t_real2real; /* data structure */ /* conv real2real data function*/ /* return TL_OK iff no error */ int freal2real(t_real2real *data); typedef struct { double indata; /* param: intype real */ unsigned int maxint; /* option: intype natural */ char maxint_present; /* boolean: option maxint present */ unsigned int maxfract; /* option: intype natural */ char maxfract_present; /* boolean: option maxfract present */ char * result; /* outtype string */ char *errorstr; /* initialized ==NULL */ } t_real2freal; /* data structure */ /* conv real2freal data function*/ /* return TL_OK iff no error */ int freal2freal(t_real2freal *data); typedef struct { double indata; /* param: intype real */ double result; /* outtype breal */ char *errorstr; /* initialized ==NULL */ } t_real2breal; /* data structure */ /* conv real2breal data function*/ /* return TL_OK iff no error */ int freal2breal(t_real2breal *data); #endif /* TLC_TCLC_conv_USER_H */