Documentation
¶
Index ¶
- Constants
- func CleanOldSessions(updateTime int64) (err error)
- func CreateSession(initialData map[string]string, env *dvevaluation.DvObject) (err error)
- func IsSessionPresent(sessionId string) (bool, error)
- func ReadSession(sessionId string, force bool) (data map[string]string, err error)
- func ReadSessionByEnvironment(env *dvevaluation.DvObject) (string, map[string]string, error)
- func UpdateBySession(env *dvevaluation.DvObject, mode int) (err error)
- func UpdateSessionWithKeyValue(env *dvevaluation.DvObject, key string, value string) (err error)
- func UpdateSessionWithMap(env *dvevaluation.DvObject, info map[string]string) (err error)
- func WriteToSession(sessionId string, data map[string]string) (orig map[string]string, err error)
- type SessionMetaInfo
Constants ¶
View Source
const ( SessionId = "SESSION_ID" MODE_SESSION_MAY_BE = 0 MODE_SESSION_CREATE_IF_NOT_EXISTS = 1 MODE_SESSION_MUST_EXIST = 2 )
Variables ¶
This section is empty.
Functions ¶
func CleanOldSessions ¶
func CreateSession ¶
func CreateSession(initialData map[string]string, env *dvevaluation.DvObject) (err error)
func IsSessionPresent ¶
func ReadSession ¶
func UpdateBySession ¶
func UpdateBySession(env *dvevaluation.DvObject, mode int) (err error)
func UpdateSessionWithKeyValue ¶
func UpdateSessionWithKeyValue(env *dvevaluation.DvObject, key string, value string) (err error)
func UpdateSessionWithMap ¶
func UpdateSessionWithMap(env *dvevaluation.DvObject, info map[string]string) (err error)
Types ¶
type SessionMetaInfo ¶
type SessionMetaInfo struct {
Db string `json:"db"`
Table string `json:"table"`
Id string `json:"id"`
Data string `json:"data"`
ModTime string `json:"modTime"`
Prefix string `json:"prefix"`
ReadSql []string `json:"readSql"`
CreateSql []string `json:"createSql"`
UpdateSql []string `json:"updateSql"`
DeleteExpireSql string `json:"deleteExpireSql"`
SqlType int
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.