Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

189 lines
7.5 KiB

  1. //+--------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1996 - 1999
  5. //
  6. // File: dbw.h
  7. //
  8. // Contents: Cert Server Database interface implementation
  9. //
  10. //---------------------------------------------------------------------------
  11. #if !defined(__DBW_H__)
  12. #define __DBW_H__
  13. #ifdef __cplusplus
  14. extern "C" {
  15. #endif
  16. #if DBG
  17. JET_ERR JET_API _dbgJetInit(JET_INSTANCE *pinstance);
  18. JET_ERR JET_API _dbgJetTerm(JET_INSTANCE instance);
  19. JET_ERR JET_API _dbgJetTerm2(JET_INSTANCE instance, JET_GRBIT grbit);
  20. JET_ERR JET_API _dbgJetBackup(const char *szBackupPath, JET_GRBIT grbit, JET_PFNSTATUS pfnStatus);
  21. JET_ERR JET_API _dbgJetRestore(const char *sz, JET_PFNSTATUS pfn);
  22. JET_ERR JET_API _dbgJetRestore2(const char *sz, const char *szDest, JET_PFNSTATUS pfn);
  23. JET_ERR JET_API _dbgJetSetSystemParameter(JET_INSTANCE *pinstance, JET_SESID sesid, unsigned long paramid, unsigned long lParam, const char *sz);
  24. JET_ERR JET_API _dbgJetBeginSession(JET_INSTANCE instance, JET_SESID *psesid, const char *szUserName, const char *szPassword);
  25. JET_ERR JET_API _dbgJetEndSession(JET_SESID sesid, JET_GRBIT grbit);
  26. JET_ERR JET_API _dbgJetCreateDatabase(JET_SESID sesid, const char *szFilename, const char *szConnect, JET_DBID *pdbid, JET_GRBIT grbit);
  27. JET_ERR JET_API _dbgJetCreateTable(JET_SESID sesid, JET_DBID dbid, const char *szTableName, unsigned long lPages, unsigned long lDensity, JET_TABLEID *ptableid);
  28. JET_ERR JET_API _dbgJetGetColumnInfo(JET_SESID sesid, JET_DBID dbid, const char *szTableName, const char *szColumnName, void *pvResult, unsigned long cbMax, unsigned long InfoLevel);
  29. JET_ERR JET_API _dbgJetConvertDDL(JET_SESID sesid, JET_DBID ifmp, JET_OPDDLCONV convtyp, void *pvData, unsigned long cbData);
  30. JET_ERR JET_API _dbgJetAddColumn(JET_SESID sesid, JET_TABLEID tableid, const char *szColumn, const JET_COLUMNDEF *pcolumndef, const void *pvDefault, unsigned long cbDefault, JET_COLUMNID *pcolumnid);
  31. JET_ERR JET_API _dbgJetDeleteColumn(JET_SESID sesid, JET_TABLEID tableid, const char *szColumnName);
  32. JET_ERR JET_API _dbgJetCreateIndex(JET_SESID sesid, JET_TABLEID tableid, const char *szIndexName, JET_GRBIT grbit, const char *szKey, unsigned long cbKey, unsigned long lDensity);
  33. JET_ERR JET_API _dbgJetDeleteIndex(JET_SESID sesid, JET_TABLEID tableid, const char *szIndexName);
  34. JET_ERR JET_API _dbgJetBeginTransaction(JET_SESID sesid);
  35. JET_ERR JET_API _dbgJetCommitTransaction(JET_SESID sesid, JET_GRBIT grbit);
  36. JET_ERR JET_API _dbgJetRollback(JET_SESID sesid, JET_GRBIT grbit);
  37. JET_ERR JET_API _dbgJetOpenDatabase(JET_SESID sesid, const char *szFilename, const char *szConnect, JET_DBID *pdbid, JET_GRBIT grbit);
  38. JET_ERR JET_API _dbgJetAttachDatabase(JET_SESID sesid, const char *szFilename, JET_GRBIT grbit);
  39. JET_ERR JET_API _dbgJetCloseDatabase(JET_SESID sesid, JET_DBID dbid, JET_GRBIT grbit);
  40. JET_ERR JET_API _dbgJetOpenTable(JET_SESID sesid, JET_DBID dbid, const char *szTableName, const void *pvParameters, unsigned long cbParameters, JET_GRBIT grbit, JET_TABLEID *ptableid);
  41. JET_ERR JET_API _dbgJetCloseTable(JET_SESID sesid, JET_TABLEID tableid);
  42. JET_ERR JET_API _dbgJetUpdate(JET_SESID sesid, JET_TABLEID tableid, void *pvBookmark, unsigned long cbBookmark, unsigned long *pcbActual);
  43. JET_ERR JET_API _dbgJetDelete(JET_SESID sesid, JET_TABLEID tableid);
  44. JET_ERR JET_API _dbgJetRetrieveColumn(JET_SESID sesid, JET_TABLEID tableid, JET_COLUMNID columnid, void *pvData, unsigned long cbData, unsigned long *pcbActual, JET_GRBIT grbit, JET_RETINFO *pretinfo);
  45. JET_ERR JET_API _dbgJetSetColumn(JET_SESID sesid, JET_TABLEID tableid, JET_COLUMNID columnid, const void *pvData, unsigned long cbData, JET_GRBIT grbit, JET_SETINFO *psetinfo);
  46. JET_ERR JET_API _dbgJetPrepareUpdate(JET_SESID sesid, JET_TABLEID tableid, unsigned long prep);
  47. JET_ERR JET_API _dbgJetSetCurrentIndex2(JET_SESID sesid, JET_TABLEID tableid, const char *szIndexName, JET_GRBIT grbit);
  48. JET_ERR JET_API _dbgJetMove(JET_SESID sesid, JET_TABLEID tableid, long cRow, JET_GRBIT grbit);
  49. JET_ERR JET_API _dbgJetMakeKey(JET_SESID sesid, JET_TABLEID tableid, const void *pvData, unsigned long cbData, JET_GRBIT grbit);
  50. JET_ERR JET_API _dbgJetSeek(JET_SESID sesid, JET_TABLEID tableid, JET_GRBIT grbit);
  51. JET_ERR JET_API _dbgJetSetIndexRange(JET_SESID sesid, JET_TABLEID tableid, JET_GRBIT grbit);
  52. JET_ERR JET_API _dbgJetRetrieveKey(JET_SESID sesid, JET_TABLEID tableid, void *pvData, unsigned long cbData, unsigned long *pcbActual, JET_GRBIT grbit);
  53. JET_ERR JET_API _dbgJetBeginExternalBackup(JET_GRBIT grbit);
  54. JET_ERR JET_API _dbgJetGetAttachInfo(void *pv,
  55. unsigned long cbMax,
  56. unsigned long *pcbActual);
  57. JET_ERR JET_API _dbgJetOpenFile(const char *szFileName,
  58. JET_HANDLE *phfFile,
  59. unsigned long *pulFileSizeLow,
  60. unsigned long *pulFileSizeHigh);
  61. JET_ERR JET_API _dbgJetReadFile(JET_HANDLE hfFile,
  62. void *pv,
  63. unsigned long cb,
  64. unsigned long *pcb);
  65. #if 0
  66. JET_ERR JET_API _dbgJetAsyncReadFile(
  67. JET_HANDLE hfFile,
  68. void* pv,
  69. unsigned long cb,
  70. JET_OLP *pjolp);
  71. JET_ERR JET_API _dbgJetCheckAsyncReadFile(void *pv, int cb, unsigned long pgnoFirst);
  72. #endif
  73. JET_ERR JET_API _dbgJetCloseFile(JET_HANDLE hfFile);
  74. JET_ERR JET_API _dbgJetGetLogInfo(void *pv,
  75. unsigned long cbMax,
  76. unsigned long *pcbActual);
  77. JET_ERR JET_API _dbgJetTruncateLog(void);
  78. JET_ERR JET_API _dbgJetEndExternalBackup(void);
  79. JET_ERR JET_API _dbgJetExternalRestore(char *szCheckpointFilePath, char *szLogPath, JET_RSTMAP *rgstmap, long crstfilemap, char *szBackupLogPath, long genLow, long genHigh, JET_PFNSTATUS pfn);
  80. #else // DBG
  81. #define _dbgJetInit JetInit
  82. #define _dbgJetTerm JetTerm
  83. #define _dbgJetTerm2 JetTerm2
  84. #define _dbgJetBackup JetBackup
  85. #define _dbgJetRestore JetRestore
  86. #define _dbgJetRestore2 JetRestore2
  87. #define _dbgJetSetSystemParameter JetSetSystemParameter
  88. #define _dbgJetBeginSession JetBeginSession
  89. #define _dbgJetEndSession JetEndSession
  90. #define _dbgJetCreateDatabase JetCreateDatabase
  91. #define _dbgJetCreateTable JetCreateTable
  92. #define _dbgJetGetColumnInfo JetGetColumnInfo
  93. #define _dbgJetConvertDDL JetConvertDDL
  94. #define _dbgJetAddColumn JetAddColumn
  95. #define _dbgJetDeleteColumn JetDeleteColumn
  96. #define _dbgJetCreateIndex JetCreateIndex
  97. #define _dbgJetDeleteIndex JetDeleteIndex
  98. #define _dbgJetBeginTransaction JetBeginTransaction
  99. #define _dbgJetCommitTransaction JetCommitTransaction
  100. #define _dbgJetRollback JetRollback
  101. #define _dbgJetAttachDatabase JetAttachDatabase
  102. #define _dbgJetOpenDatabase JetOpenDatabase
  103. #define _dbgJetCloseDatabase JetCloseDatabase
  104. #define _dbgJetOpenTable JetOpenTable
  105. #define _dbgJetCloseTable JetCloseTable
  106. #define _dbgJetUpdate JetUpdate
  107. #define _dbgJetDelete JetDelete
  108. #define _dbgJetRetrieveColumn JetRetrieveColumn
  109. #define _dbgJetSetColumn JetSetColumn
  110. #define _dbgJetPrepareUpdate JetPrepareUpdate
  111. #define _dbgJetSetCurrentIndex2 JetSetCurrentIndex2
  112. #define _dbgJetMove JetMove
  113. #define _dbgJetMakeKey JetMakeKey
  114. #define _dbgJetSeek JetSeek
  115. #define _dbgJetSetIndexRange JetSetIndexRange
  116. #define _dbgJetRetrieveKey JetRetrieveKey
  117. #define _dbgJetBeginExternalBackup JetBeginExternalBackup
  118. #define _dbgJetGetAttachInfo JetGetAttachInfo
  119. #define _dbgJetOpenFile JetOpenFile
  120. #define _dbgJetReadFile JetReadFile
  121. #if 0
  122. #define _dbgJetAsyncReadFile JetAsyncReadFile
  123. #define _dbgJetCheckAsyncReadFile JetCheckAsyncReadFile
  124. #endif
  125. #define _dbgJetCloseFile JetCloseFile
  126. #define _dbgJetGetLogInfo JetGetLogInfo
  127. #define _dbgJetTruncateLog JetTruncateLog
  128. #define _dbgJetEndExternalBackup JetEndExternalBackup
  129. #define _dbgJetExternalRestore JetExternalRestore
  130. #endif // DBG
  131. #ifdef __cplusplus
  132. }
  133. #endif
  134. #endif /* __DBW_H__ */