View Source

[modwtcl]
apreq.h
dist/
libapreq1/
mod_wtcl.c
mod_wtcl.h
setupExclude.txt
util/
win.def
win.mak
wt1.1/
WtAppTable.c
WtAppTable.h
WtBasicCmds.c
WtBasicCmds.h
WtClientRequest.c
WtClientRequest.h
WtCollection.c
WtCollection.h
WtCollectionCmds.c
WtCollectionCmds.h
WtContext.c
WtContext.h
WtContextEvents.c
WtContextEvents.h
WtCookie.c
WtCookie.h
WtDbSession.c
WtDbSession.h
WtExecute.c
WtExecute.h
WtHtmlEntities.c
WtHtmlEntities.h
WtInitCmds.c
WtInitCmds.h
WtMtTable.c
WtMtTable.h
WtMultiTable.c
WtMultiTable.h
WtOS.h
WtProcSession.c
WtProcSession.h
WtResponse.c
WtResponse.h
WtServerCmds.c
WtServerCmds.h
WtSession.c
WtSession.h
WtSettings.c
WtSettings.h
WtTable.c
WtTable.h
WtTableCmds.c
WtTableCmds.h
WtTableUtil.c
WtTableUtil.h
WtUpload.c
WtUpload.h
WtUtil.c
WtUtil.h
WtWebErrors.c
WtWebErrors.h
WtWindows.h
File: / archive / modwtcl / WtDbSession.h

Lines Size Modified Created Owner MIME Types
166 8,003 2010/05/08 18:46:41 2011/06/13 15:35:15 BUILTIN\Administrators text/x-chdr

0001
/*
0002
 * Copyright 2001 Alexander Boverman and the original authors.
0003
 * 
0004
 * Licensed under the Apache License, Version 2.0 (the "License");
0005
 * you may not use this file except in compliance with the License.
0006
 * You may obtain a copy of the License at
0007
 * 
0008
 *      http://www.apache.org/licenses/LICENSE-2.0
0009
 * 
0010
 * Unless required by applicable law or agreed to in writing, software
0011
 * distributed under the License is distributed on an "AS IS" BASIS,
0012
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
0013
 * See the License for the specific language governing permissions and
0014
 * limitations under the License.
0015
 */
0016
0017
#ifndef _WT_DB_SESSION_H
0018
#define _WT_DB_SESSION_H
0019
0020
#include <tcl.h>
0021
#include "WtSession.h"
0022
0023
typedef struct WtDbSessionT
0024
{
0025
  /* Session ID */
0026
0027
  Tcl_Obj *id;
0028
  int isAutoId;
0029
0030
  /* Updates */
0031
0032
  int isOpen;
0033
  int isFetched;
0034
  Tcl_Obj *items;
0035
  Tcl_Obj *checkpoint;
0036
  int isModified;
0037
  Tcl_Obj *deletions;
0038
  Tcl_Obj *insertions;
0039
  int isCleared;
0040
  int commitStatus;
0041
  time_t accessTime;
0042
  int syncedAccessTime;
0043
  int accessTimeInterval;
0044
0045
  /* DB state */
0046
0047
  Tcl_Obj *dbHandler;
0048
  Tcl_Obj *dbHandlerData;
0049
  int dbHandlerLoaded;
0050
  int dbSessionOpened;
0051
} WtDbSession;
0052
0053
Tcl_Obj *WtNewDbSessionObj();
0054
WtDbSession *WtDbSessionRep(Tcl_Obj *obj);
0055
int WtInitDbSessionId(WtDbSession *ds, Tcl_Interp *interp);
0056
Tcl_Obj *WtGetDbSessionId(WtDbSession *ds, Tcl_Interp *interp);
0057
int WtSetDbSessionId(WtDbSession *ds, Tcl_Obj *id, Tcl_Interp *interp);
0058
int WtOpenDbSession(WtDbSession *ds, Tcl_Interp *interp);
0059
int WtCloseDbSession(WtDbSession *ds, Tcl_Interp *interp, int doCommit);
0060
int WtOpenDbSessionResource(WtDbSession *ds, Tcl_Interp *interp);
0061
int WtCloseDbSessionResource(WtDbSession *ds, Tcl_Interp *interp);
0062
int WtSetDbSessionHandler(WtDbSession *ds, Tcl_Obj *handler, Tcl_Interp *interp);
0063
int WtLoadDbSessionStore(WtDbSession *ds, Tcl_Interp *interp);
0064
int WtUnloadDbSessionStore(WtDbSession *ds, Tcl_Interp *interp, int doClose);
0065
int WtFetchDbSession(WtDbSession *ds, Tcl_Interp *interp);
0066
Tcl_Obj *WtGetDbSessionItems(WtDbSession *ds, Tcl_Interp *interp);
0067
Tcl_Obj *WtGetDbSessionInsertions(WtDbSession *ds, Tcl_Interp *interp);
0068
Tcl_Obj *WtGetDbSessionDeletions(WtDbSession *ds, Tcl_Interp *interp);
0069
int WtCommitIsPending(WtDbSession *ds);
0070
int WtCommitDbSession(WtDbSession *ds, Tcl_Interp *interp);
0071
int WtDeleteDbSession(WtDbSession *ds, Tcl_Obj *id, Tcl_Interp *interp);
0072
int WtSweepDbSessions(WtDbSession *ds, Tcl_Interp *interp);
0073
int WtClearDbSessionCache(WtDbSession *ds, Tcl_Interp *interp);
0074
int WtClearDbSessionUpdates(WtDbSession *ds, Tcl_Interp *interp);
0075
int WtUnloadDbSession(WtDbSession *ds, Tcl_Interp *interp);
0076
int WtDbSessionFinalizeRequest(WtDbSession *ds, Tcl_Interp *interp);
0077
int WtDbSessionCmd(ClientData clientData, Tcl_Interp *interp,
0078
  int objc, Tcl_Obj *const objv[]);
0079
int WtDbSessionCmdHelper(ClientData clientData, Tcl_Interp *interp,
0080
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0081
WtDbSessionCmdUsage(Tcl_Interp *interp, Tcl_Obj *cmd);
0082
int WtDbSessionIdCmd(ClientData clientData, Tcl_Interp *interp,
0083
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0084
int WtDbSessionCountCmd(ClientData clientData, Tcl_Interp *interp,
0085
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0086
int WtDbSessionHasCmd(ClientData clientData, Tcl_Interp *interp,
0087
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0088
int WtDbSessionGetCmd(ClientData clientData, Tcl_Interp *interp,
0089
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0090
int WtDbSessionGetAllCmd(ClientData clientData, Tcl_Interp *interp,
0091
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0092
int WtDbSessionSetCmd(ClientData clientData, Tcl_Interp *interp,
0093
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0094
int WtDbSessionSetDefaultCmd(ClientData clientData, Tcl_Interp *interp,
0095
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0096
int WtDbSessionSetAllCmd(ClientData clientData, Tcl_Interp *interp,
0097
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0098
int WtDbSessionSetAllDefaultCmd(ClientData clientData, Tcl_Interp *interp,
0099
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0100
int WtDbSessionAddCmd(ClientData clientData, Tcl_Interp *interp,
0101
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0102
int WtDbSessionAddListCmd(ClientData clientData, Tcl_Interp *interp,
0103
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0104
int WtDbSessionKeysCmd(ClientData clientData, Tcl_Interp *interp,
0105
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0106
int WtDbSessionValuesCmd(ClientData clientData, Tcl_Interp *interp,
0107
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0108
int WtDbSessionAllValuesCmd(ClientData clientData, Tcl_Interp *interp,
0109
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0110
int WtDbSessionRemoveCmd(ClientData clientData, Tcl_Interp *interp,
0111
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0112
int WtDbSessionRemoveListCmd(ClientData clientData, Tcl_Interp *interp,
0113
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0114
int WtDbSessionArrayCmd(ClientData clientData, Tcl_Interp *interp,
0115
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0116
int WtDbSessionListArrayCmd(ClientData clientData, Tcl_Interp *interp,
0117
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0118
int WtDbSessionItemsCmd(ClientData clientData, Tcl_Interp *interp,
0119
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0120
int WtDbSessionClearCmd(ClientData clientData, Tcl_Interp *interp,
0121
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0122
int WtDbSessionIsAccessedCmd(ClientData clientData, Tcl_Interp *interp,
0123
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0124
int WtDbSessionIsModifiedCmd(ClientData clientData, Tcl_Interp *interp,
0125
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0126
int WtDbSessionCommitCmd(ClientData clientData, Tcl_Interp *interp,
0127
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0128
int WtDbSessionTouchCmd(ClientData clientData, Tcl_Interp *interp,
0129
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0130
int WtDbSessionClearCacheCmd(ClientData clientData, Tcl_Interp *interp,
0131
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0132
int WtDbSessionStatusCmd(ClientData clientData, Tcl_Interp *interp,
0133
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0134
int WtDbSessionPropertiesCmd(ClientData clientData, Tcl_Interp *interp,
0135
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0136
int WtDbSessionDeleteCmd(ClientData clientData, Tcl_Interp *interp,
0137
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0138
int WtDbSessionSweepCmd(ClientData clientData, Tcl_Interp *interp,
0139
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0140
int WtDbSessionHandlerCmd(ClientData clientData, Tcl_Interp *interp,
0141
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0142
int WtDbSessionHandlerDataCmd(ClientData clientData, Tcl_Interp *interp,
0143
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0144
int WtDbSessionHandlerEvalCmd(ClientData clientData, Tcl_Interp *interp,
0145
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0146
int WtDbSessionUnloadCmd(ClientData clientData, Tcl_Interp *interp,
0147
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0148
int WtDbSessionLoadModuleCmd(ClientData clientData, Tcl_Interp *interp,
0149
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0150
int WtDbSessionUnloadModuleCmd(ClientData clientData, Tcl_Interp *interp,
0151
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0152
int WtDbSessionFinalizeCmd(ClientData clientData, Tcl_Interp *interp,
0153
  WtDbSession *ds, int objc, Tcl_Obj *const objv[]);
0154
int WtDbSessionHandler(WtDbSession *ds, Tcl_Obj *handler,
0155
  Tcl_Obj *method, Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]);
0156
int WtDbSessionHandlerStr(WtDbSession *ds, Tcl_Obj *handler,
0157
  const char *methodStr, Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]);
0158
int WtDbSessionHandlerInternal(WtDbSession *ds,
0159
  Tcl_Obj *handler, Tcl_Obj *method, Tcl_Interp *interp,
0160
  int objc, Tcl_Obj *const objv[]);
0161
int WtPrepareDbSessionHandler(WtDbSession *ds, Tcl_Obj *method, Tcl_Interp *interp);
0162
void WtInitDbSessionCommands(Tcl_Interp *interp);
0163
0164
extern struct Tcl_ObjType WtDbSessionType;
0165
0166
#endif /* !_WT_DB_SESSION_H */