Zum Hauptinhalt springen

c16_dll.h

c16_dll.h Header-Datei zum Erstellen einer DLL

Die Header-Datei bindet eine weitere Header-Datei ( c16.h ) mit allgemeinen Definitionen ein.

/************************************************************************/
/* */
/* Project : CONZEPT 16 */
/* Project ID : C16.ALL */
/* */
/* Program : CONZEPT 16 PROGRAMMING INTERFACE - INTERNAL */
/* Revision : 5.9.01 */
/* FileName : c16_dll.h */
/* */
/************************************************************************/

#if !defined(INCL_C16_DLL)
#define INCL_C16_DLL

#include "c16.h"

#ifdef __cplusplus
extern "C"
{
#endif

#undef C16API_DLL
#if defined(LNX)
#define C16API_DLL
#else
#define C16API_DLL WINAPI
#endif

/****************************************************************************/
/* */
/* CALL CONTROL BLOCK */
/* */
/****************************************************************************/

typedef struct
{
vPHANDLE InstHdl; /* instance handle */

/****************************************************************************/
/* Argument access */
/****************************************************************************/

vERROR (C16API_DLL * C16_ArgCount)
(
const vPHANDLE aInstHdl, /* in: instance handle */
vINT* aArgCount /* out: number of arguments */
);

vERROR (C16API_DLL * C16_ArgInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aPosition, /* in: argument number */
vINT* aType, /* out: argument type */
vINT* aOptions, /* out: argument options */
vINT* aLength, /* out: argument length */
vINT* aMaxLength, /* out: max. string size */
vINT* aElements /* out: array elements */
);

vERROR (C16API_DLL * C16_ArgRead)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aPosition, /* in: argument number */
const vINT aIndex, /* in: array index */
void* aData /* out: argument data */
);

vERROR (C16API_DLL * C16_ArgWrite)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aPosition, /* in: argument number */
const vINT aIndex, /* in: array index */
const void* aData /* in: argument data */
);

/****************************************************************************/
/* FILE information */
/****************************************************************************/

/* retrieve file information by number */
vERROR (C16API_DLL * C16_FileInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
vC16_FileInfo* aInfoBlock /* out: information block */
);

/* retrieve file information by name */
vERROR (C16API_DLL * C16_FileInfoByName)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vCHAR* aFileName, /* in: filename */
vC16_FileInfo* aInfoBlock /* out: information block */
);

/****************************************************************************/
/* SUBRECORD information */
/****************************************************************************/

/* retrieve subrecord information */
vERROR (C16API_DLL * C16_SbrInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
vC16_SbrInfo* aInfoBlock /* out: information block */
);

/* retrieve subrecord information by name */
vERROR (C16API_DLL * C16_SbrInfoByName)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vCHAR* aSbrName, /* in: subrecord name */
vC16_SbrInfo* aInfoBlock /* out: information block */
);

/* clear subrecord buffer */
vERROR (C16API_DLL * C16_SbrClear)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo /* in: subrecord number */
);

/* change subrecord status */
vERROR (C16API_DLL * C16_SbrSetStatus)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
const vBOOL aNewStatus /* in: new status */
);

/****************************************************************************/
/* FIELD information */
/****************************************************************************/

/* retrieve field information */
vERROR (C16API_DLL * C16_FldInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
const vINT aFldNo, /* in: field number */
vC16_FldInfo* aInfoBlock /* out: information block */
);

/* retrieve field information by name */
vERROR (C16API_DLL * C16_FldInfoByName)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vCHAR* aFldName, /* in: field name */
vC16_FldInfo* aInfoBlock /* out: information block */
);

/****************************************************************************/
/* KEY information */
/****************************************************************************/

/* retrieve key information */
vERROR (C16API_DLL * C16_KeyInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aKeyNo, /* in: key number */
vC16_KeyInfo* aInfoBlock /* out: information block */
);

/* retrieve key information by name */
vERROR (C16API_DLL * C16_KeyInfoByName)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vCHAR* aKeyName, /* in: key name */
vC16_KeyInfo* aInfoBlock /* out: information block */
);

/* retrieve key field information */
vERROR (C16API_DLL * C16_KeyFldInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aKeyNo, /* in: key number */
const vINT aKeyFldNo, /* in: key field number */
vC16_KeyFldInfo* aInfoBlock /* out: information block */
);

/****************************************************************************/
/* LINK information */
/****************************************************************************/

/* retrieve link information */
vERROR (C16API_DLL * C16_LinkInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aLinkNo, /* in: link number */
vC16_LinkInfo* aInfoBlock /* out: information block */
);

/* retrieve link information by name */
vERROR (C16API_DLL * C16_LinkInfoByName)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vCHAR* aLinkName, /* in: link name */
vC16_LinkInfo* aInfoBlock /* out: information block */
);

/* retrieve link field information */
vERROR (C16API_DLL * C16_LinkFldInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aLinkNo, /* in: link number */
const vINT aLinkFldNo, /* in: link field number */
vC16_LinkFldInfo* aInfoBlock /* out: information block */
);

/****************************************************************************/
/* data exchange */
/****************************************************************************/

/* set character format defaults */
vERROR (C16API_DLL * C16_SetCharDefs)
(
const vPHANDLE aInstHdl, /* in: instance handle */
vCHAR aDecimalSep, /* in: decimal separator */
vCHAR aThousandsSep, /* in: thousands separator */
vCHAR aDateSep, /* in: date separator */
vCHAR aTimeSep1, /* in: time separator 1 */
vCHAR aTimeSep2, /* in: time separator 2 */
vCHAR aCharTRUE, /* in: char for TRUE value */
vCHAR aCharFALSE, /* in: char for FALSE value */
vFLAGS aCharSetConversion /* in: charset conv. type */
);

/* read/write field data */
vERROR (C16API_DLL * C16_FldData)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
const vINT aFldNo, /* in: field number */
void* aFldBuf, /* in/out: field data */
const vBOOL aWriteFlag /* in: write data to field */
);

/* read/write field data as chars */
vERROR (C16API_DLL * C16_FldDataChar)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
const vINT aFldNo, /* in: field number */
vCHAR* aFldBuf, /* in/out: field data */
const vFLAGS aFormatFlags, /* in: format options */
const vINT aPostcomma, /* in: postcomma digits */
const vBOOL aWriteFlag /* in: write data to field */
);

/* read/write field data (raw alpha) */
vERROR (C16API_DLL * C16_FldDataRaw)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
const vINT aFldNo, /* in: field number */
void* aFldBuf, /* in/out: field data */
const vBOOL aWriteFlag /* in: write data to field */
);

/* register external field buffer */
vERROR (C16API_DLL * C16_RegExtFld)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
const vINT aFldNo, /* in: field number */
const vFLAGS aExcFlags, /* in: data exchange flags */
const vFLAGS aFormatFlags, /* in: format options */
const vINT aPostcomma, /* in: postcomma digits */
void* aExtBuffer /* in: external field buffer */
);

/* transfer complete record */
vERROR (C16API_DLL * C16_ExcFileData)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vPHANDLE aBuffHdl, /* in: buffer handle */
const vBOOL aWriteFlag /* in: write data */
);

/* transfer subrecord */
vERROR (C16API_DLL * C16_ExcSbrData)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
const vBOOL aWriteFlag /* in: write data */
);

/* transfer single field */
vERROR (C16API_DLL * C16_ExcFldData)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
const vINT aFldNo, /* in: field number */
const vBOOL aWriteFlag /* in: write data */
);

/* set automatic data exchange option */
vERROR (C16API_DLL * C16_SetExcMode)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vBOOL aAutoFlag /* in: enable/disable flag */
);

/****************************************************************************/
/* record information */
/****************************************************************************/

/* retrieve record information */
vERROR (C16API_DLL * C16_RecInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aInfoType, /* in: information type */
const vINT aKeyNo, /* in: key number (opt.) */
vINT* aResult /* out: information result */
);

/* retrieve linked record information */
vERROR (C16API_DLL * C16_RecLinkInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aSrcFileNo, /* in: source filenumber */
const vINT aDstFileNo, /* in: destin. filenumber */
const vINT aLinkNo, /* in: link number */
const vINT aInfoType, /* in: information type */
const vINT unused, /* in: reserved (0) */
vINT* aResult /* out: information result */
);

/****************************************************************************/
/* record operations */
/****************************************************************************/

/* read record */
vERROR (C16API_DLL * C16_RecRead)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aKeyNo, /* in: key number */
const vFLAGS aFlags, /* in: operation flags */
const vLONG aAddInfo /* in: additional info */
);

/* read linked record */
vERROR (C16API_DLL * C16_RecLink)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aSrcFileNo, /* in: source filenumber */
const vINT aDstFileNo, /* in: destin. filenumber */
const vXLONG aLinkNo, /* in: link number / sel. handle */
const vFLAGS aFlags, /* in: operation flags */
const vINT unused, /* in: reserved (0) */
const vINT aLinkPos /* in: link position (opt.) */
);

/* insert new record */
vERROR (C16API_DLL * C16_RecInsert)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vFLAGS aFlags /* in: operation flags */
);

/* update record */
vERROR (C16API_DLL * C16_RecReplace)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vFLAGS aFlags /* in: operation flags */
);

/* delete single record */
vERROR (C16API_DLL * C16_RecDelete)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vFLAGS aFlags /* in: operation flags */
);

/* delete all records */
vERROR (C16API_DLL * C16_RecDeleteAll)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo /* in: filenumber */
);

/****************************************************************************/
/* record buffer operations */
/****************************************************************************/

/* clear record buffer - buffer handle is optional (0 if not used) */
vERROR (C16API_DLL * C16_RecBufClear)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vPHANDLE aBuffHdl /* in: buffer handle */
);

/* copy record buffer - buffer handles are optional (0 if not used) */
vERROR (C16API_DLL * C16_RecBufCopy)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aSrcFileNo, /* in: source filenumber */
const vINT aDstFileNo, /* in: destin. filenumber */
const vPHANDLE aSrcBuffHdl, /* in: source buf. handle */
const vPHANDLE aDstBuffHdl /* in: destin. buf. handle */
);

/* compare record buffers - buffer handles are optional (0 if not used) */
vERROR (C16API_DLL * C16_RecBufCompare)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo1, /* in: filenumber 1 */
const vINT aFileNo2, /* in: filenumber 2 */
const vPHANDLE aBuffHdl1, /* in: buffer handle 1 */
const vPHANDLE aBuffHdl2 /* in: buffer handle 2 */
);

/* create temporary record buffer */
vERROR (C16API_DLL * C16_RecBufCreate)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
vPHANDLE* aBuffHdl /* out: new buffer handle */
);

/* destroy temporary record buffer */
vERROR (C16API_DLL * C16_RecBufDestroy)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vPHANDLE aBuffHdl /* in: buffer handle */
);

/****************************************************************************/
/* transactions */
/****************************************************************************/

/* begin transaction */
vERROR (C16API_DLL * C16_DtaBegin)
(
const vPHANDLE aInstHdl /* in: instance handle */
);

/* commit transaction */
vERROR (C16API_DLL * C16_DtaCommit)
(
const vPHANDLE aInstHdl /* in: instance handle */
);

/* rollback transaction */
vERROR (C16API_DLL * C16_DtaRollback)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vBOOL aAllLevels /* in: complete rollback */
);

/****************************************************************************/
/* text operations */
/****************************************************************************/

/* create text buffer */
vERROR (C16API_DLL * C16_TextOpen)
(
const vPHANDLE aInstHdl, /* in: instance handle */
vPHANDLE* aTextHdl /* out: new text handle */
);

/* close text buffer */
vERROR (C16API_DLL * C16_TextClose)
(
const vPHANDLE aTextHdl /* in: text handle */
);

/* create text */
vERROR (C16API_DLL * C16_TextCreate)
(
const vPHANDLE aTextHdl, /* in: text handle */
const vCHAR* aTextName, /* in: text to create */
const vBOOL aLockText /* in: lock new text */
);

/* copy text */
vERROR (C16API_DLL * C16_TextCopy)
(
const vPHANDLE aTextHdl, /* in: text handle */
const vCHAR* aTextName, /* in: text to copy */
const vCHAR* aTextNameNew /* in: new text name */
);

/* rename text */
vERROR (C16API_DLL * C16_TextRename)
(
const vPHANDLE aTextHdl, /* in: text handle */
const vCHAR* aTextName, /* in: text to rename */
const vCHAR* aTextNameNew /* in: new text name */
);

/* delete text */
vERROR (C16API_DLL * C16_TextDelete)
(
const vPHANDLE aTextHdl, /* in: text handle */
const vCHAR* aTextName /* in: text to delete */
);

/* read text header */
vERROR (C16API_DLL * C16_TextRead)
(
const vPHANDLE aTextHdl, /* in: text handle */
const vCHAR* aTextName, /* in: text name to read */
const vFLAGS aFlags, /* in: operation flags */
vC16_TextInfo* aTextInfo /* out: text information */
);

/* read text data */
vERROR (C16API_DLL * C16_TextReadData)
(
const vPHANDLE aTextHdl, /* in: text handle */
const void* aBuffer, /* in: text data buffer */
const vFLAGS aFlags, /* in: operation flags */
const vINT aBufferSize, /* in: size of aBuffer */
vINT* aTextSize, /* out: size of text */
vINT* aTextLines /* out: number of text lines */
);

/* write text header */
vERROR (C16API_DLL * C16_TextWrite)
(
const vPHANDLE aTextHdl, /* in: text handle */
const vFLAGS aFlags, /* in: operation flags */
const vC16_TextInfo* aTextInfo /* in: text information */
);

/* write text data */
vERROR (C16API_DLL * C16_TextWriteData)
(
const vPHANDLE aTextHdl, /* in: text handle */
const void* aBuffer, /* in: text data buffer */
const vFLAGS aFlags, /* in: operation flags */
const vINT aTextSize /* in: size of text */
);

/****************************************************************************/
/* procedures */
/****************************************************************************/

/* define procedure argument */
vERROR (C16API_DLL * C16_ProcArgument)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vBYTE aArgType, /* in: argument type */
void* aArgVal, /* in: argument value */
const vBOOL aVarArg, /* in: pass by reference */
const vBYTE aMaxLen /* in: maximum string len */
);

/* call procedure */
vERROR (C16API_DLL * C16_ProcCall)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vCHAR* aProcName /* in: procedure name */
);

/* retrieve procedure result */
vERROR (C16API_DLL * C16_ProcResult)
(
const vPHANDLE aInstHdl, /* in: instance handle */
vBYTE* aResultType, /* out: result type */
void** aResultData /* out: result data */
);

/****************************************************************************/
/* maintainance & information */
/****************************************************************************/

/* start/stop server backup events */
vERROR (C16API_DLL * C16_ServerBackup)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aMinutes /* in: backup event duration */
);

/* query interface informations */
vERROR (C16API_DLL * C16_QueryPgifInfo)
(
const vPHANDLE aPgifHdl, /* in: module handle */
vC16_PgifInfo* aInfoBlock /* out: information block */
);

/* query server informations */
vERROR (C16API_DLL * C16_QueryServerInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
vC16_ServerInfo* aInfoBlock /* out: information block */
);

/* query data area informations */
vERROR (C16API_DLL * C16_QueryAreaInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
vC16_AreaInfo* aInfoBlock /* out: information block */
);

/* query user informations */
vERROR (C16API_DLL * C16_QueryUserInfo)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aUserID, /* in: user ID */
const vBOOL aNextID, /* in: read next user ID */
vC16_UserInfo* aInfoBlock /* out: information block */
);

/* clear user */
vERROR (C16API_DLL * C16_UserClear)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aUserID, /* in: user ID */
const vINT aUserNo, /* in: user number */
const vCHAR* aServerPassword /* in: server password */
);

#if !defined(LNX)
/* special internal extension for client 3.6 */
HANDLE hwnd;
#endif

/* retrieve field information */
vERROR (C16API_DLL * C16_FldInfoExt)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aSbrNo, /* in: subrecord number */
const vINT aFldNo, /* in: field number */
vC16_FldInfoExt* aInfoBlock /* out: information block */
);

/* retrieve field information by name */
vERROR (C16API_DLL * C16_FldInfoExtByName)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vCHAR* aFldName, /* in: field name */
vC16_FldInfoExt* aInfoBlock /* out: information block */
);

/****************************************************************************/
/* 64 bit record IDs */
/****************************************************************************/

/* read record */
vERROR (C16API_DLL * C16_RecRead64)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vXLONG aKeyNo, /* in: key number / sel. handle */
const vFLAGS aFlags, /* in: operation flags */
const vXLONG aAddInfo /* in: additional info */
);

/* retrieve record information */
vERROR (C16API_DLL * C16_RecInfo64)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vINT aFileNo, /* in: filenumber */
const vINT aInfoType, /* in: information type */
const vXLONG aKeyNo, /* in: key number (opt.) */
vXLONG* aResult /* out: information result */
);

/* create procedure buffer */
vERROR (C16API_DLL * C16_ProcOpen)
(
const vPHANDLE aInstHdl, /* in: instance handle */
vPHANDLE* aProcHdl /* out: new text handle */
);

/* compile procedure */
vERROR (C16API_DLL * C16_ProcCompile)
(
const vPHANDLE aInstHdl, /* in: instance handle */
const vCHAR* aProcName, /* in: procedure name */
const vCHAR* aLangID, /* in: language ID */
vC16_CompileInfo* aInfoBlock /* out: information block */
);

}
vC16_CCB;

#ifdef __cplusplus
};
#endif

#endif