06710b7564
Files correlati : ba1 ve0 Ricompilazione Demo : [ ] Commento : Segnalazioni fatte sui rispettivi moduli git-svn-id: svn://10.65.10.50/trunk@11217 c028cbd2-c16b-5b4b-a496-9718f37d4682
117 lines
2.7 KiB
C
Executable File
117 lines
2.7 KiB
C
Executable File
#ifndef __CFILES_H
|
|
#define __CFILES_H
|
|
|
|
#ifndef __CCUSTIO_H
|
|
#include "ccustio.h"
|
|
#endif
|
|
|
|
#ifdef __GNUC__
|
|
#define __PACKED__ __attribute__ ((packed))
|
|
#define __ALIGNED__ __attribute__ ((aligned(2)))
|
|
#define __PACK_1__
|
|
#else
|
|
#define __PACKED__
|
|
#define __ALIGNED__
|
|
#pragma pack(2)
|
|
#endif
|
|
|
|
#define MaxFilesDir 70
|
|
#define MKFields 10
|
|
#define MaxFields 100
|
|
#define MaxKeys 8
|
|
#define glockname "xx"
|
|
#define INVFLD 255
|
|
/* @(!) 2.3.01.144 */
|
|
#define NORDIR 0
|
|
#define COMDIR 1
|
|
/* @(:) 2.3.01.144 */
|
|
|
|
typedef char FieldName[12] ;
|
|
|
|
typedef struct
|
|
{
|
|
char SysName[42] __PACKED__ ;
|
|
RecNoType EOD __PACKED__ ;
|
|
RecNoType EOX __PACKED__ ;
|
|
unsigned short LenR __PACKED__ ;
|
|
RecNoType Flags __PACKED__ ;
|
|
char Des[42] __PACKED__ ;
|
|
char FCalc[32] __PACKED__ ;
|
|
char GenPrompt[32] __PACKED__ ;
|
|
} FileDes;
|
|
|
|
typedef struct
|
|
{
|
|
FieldName Name __PACKED__ ;
|
|
byte TypeF __PACKED__ ;
|
|
byte Len __PACKED__ ;
|
|
byte Dec __PACKED__ ;
|
|
#ifdef __PACK_1__
|
|
byte junk __PACKED__ ;
|
|
#endif
|
|
unsigned short RecOff __PACKED__ ;
|
|
} RecFieldDes ;
|
|
|
|
typedef struct
|
|
{
|
|
short DupKeys __ALIGNED__ ; // Was BOOLEAN and dangerous
|
|
byte NkFields __ALIGNED__ ;
|
|
byte FieldSeq[MKFields] __PACKED__ ;
|
|
byte FromCh[MKFields] __PACKED__ ;
|
|
byte ToCh[MKFields] __PACKED__ ;
|
|
} KeyDes ;
|
|
|
|
typedef struct
|
|
{
|
|
short NFields __PACKED__ ;
|
|
RecFieldDes Fd[MaxFields] __PACKED__ ;
|
|
byte SortFd[MaxFields] __PACKED__ ;
|
|
short NKeys __PACKED__ ;
|
|
KeyDes Ky[MaxKeys] __PACKED__ ;
|
|
} RecDes;
|
|
|
|
#ifdef __CFILES_C
|
|
SecDef rdir[2], fdir[2];
|
|
#else
|
|
extern SecDef rdir[2], fdir[2];
|
|
#endif
|
|
|
|
#ifdef WIN32
|
|
#pragma pack()
|
|
#endif
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
/* @(!) 2.3.01.144 */
|
|
void COpenDir(int, int);
|
|
void CCloseDir(int);
|
|
void COpenFile(int, FileDes *, int, int);
|
|
void CCloseFile(int, FileDes *, int);
|
|
void CGetFile(int, FileDes *, int, int);
|
|
void CPutFile(int, FileDes *, int);
|
|
/* @(:) 2.3.01.144 */
|
|
void zerofdes(FileDes *);
|
|
/* @(!) 2.3.01.144 */
|
|
void COpenRecDir(int, int);
|
|
void CCloseRecDir(int);
|
|
void CGetRec(int, RecDes *, int);
|
|
void CPutRec(int, RecDes *, int);
|
|
/* @(:) 2.3.01.144 */
|
|
void zerordes(RecDes *);
|
|
// word setrdes(RecDes *);
|
|
const char* CGetPref(void);
|
|
void CPutPref(const char *);
|
|
char *CAddPref(char *);
|
|
/* @(!) 2.3.01.144 */
|
|
char *CInsPref(char *, int);
|
|
|
|
int CGetCampoStpValue(const char* name, char* value, int valsize);
|
|
const char* CGetCampoIni(void);
|
|
|
|
#ifdef __cplusplus
|
|
};
|
|
#endif
|
|
|
|
#endif /* __CFILES_H */
|