Documentation
¶
Index ¶
Constants ¶
const ( ByteSpace = ' ' ByteColon = ':' ByteSemicolon = ';' ByteSlash = '/' ByteAsterisk = '*' ByteDot = '.' ByteComma = ',' ByteHyphen = '-' ByteUnderscore = '_' ByteAt = '@' ByteHash = '#' ByteDollar = '$' BytePercent = '%' BytePlus = '+' ByteMinus = '-' ByteEquals = '=' ByteAmpersand = '&' BytePipe = '|' ByteTilde = '~' ByteBacktick = '`' ByteQuestionMark = '?' ByteExclamationMark = '!' ByteLeftParenthesis = '(' ByteRightParenthesis = ')' ByteLeftBracket = '[' ByteRightBracket = ']' ByteLeftBrace = '{' ByteRightBrace = '}' ByteDoubleQuote = '"' ByteSingleQuote = '\'' ByteBackslash = '\\' ByteCarriageReturn = '\r' ByteNewline = '\n' ByteTab = '\t' )
Byte constants for common characters.
const ( EnvKeyPrefix = "VEF" EnvNodeID = EnvKeyPrefix + "_NODE_ID" // XID node identifier EnvLogLevel = EnvKeyPrefix + "_LOG_LEVEL" // Log level (debug|info|warn|error) EnvConfigPath = EnvKeyPrefix + "_CONFIG_PATH" // Custom config file path EnvI18NLanguage = EnvKeyPrefix + "_I18N_LANGUAGE" // Override default language )
Environment variable keys.
const ( HeaderXAppID = "X-App-ID" HeaderXTimestamp = "X-Timestamp" HeaderXNonce = "X-Nonce" HeaderXSignature = "X-Signature" HeaderXMetaPrefix = "X-Meta-" )
HTTP header keys used by the framework.
const ( JSONNull = "null" JSONQuote = '"' )
JSON constants.
const ( OperatorSystem = "system" OperatorCronJob = "cron_job" OperatorAnonymous = "anonymous" )
System operators for audit tracking.
const ( ExprOperator = "?Operator" ExprTableColumns = "?TableColumns" ExprColumns = "?Columns" ExprTablePKs = "?TablePKs" ExprPKs = "?PKs" ExprTableName = "?TableName" ExprTableAlias = "?TableAlias" )
SQL expression placeholders for query building.
const ( ColumnID = "id" ColumnCreatedAt = "created_at" ColumnUpdatedAt = "updated_at" ColumnCreatedBy = "created_by" ColumnUpdatedBy = "updated_by" ColumnCreatedByName = "created_by_name" ColumnUpdatedByName = "updated_by_name" )
Database column names for audit fields.
const ( FieldID = "ID" FieldCreatedAt = "CreatedAt" FieldUpdatedAt = "UpdatedAt" FieldCreatedBy = "CreatedBy" FieldUpdatedBy = "UpdatedBy" FieldCreatedByName = "CreatedByName" FieldUpdatedByName = "UpdatedByName" )
Go struct field names corresponding to audit columns.
const ( AuthSchemeBearer = "Bearer" QueryKeyAccessToken = "__accessToken" )
Authentication constants.
const ( PrincipalSystem = OperatorSystem PrincipalCronJob = OperatorCronJob PrincipalAnonymous = OperatorAnonymous )
System internal principals (not allowed to login).
const ( Empty = "" Space = " " Colon = ":" ColonSpace = ": " Semicolon = ";" Slash = "/" DoubleSlash = "//" Asterisk = "*" Dot = "." Comma = "," CommaSpace = ", " Hyphen = "-" Underscore = "_" At = "@" Hash = "#" Dollar = "$" Percent = "%" Plus = "+" Minus = "-" Equals = "=" Ampersand = "&" Pipe = "|" Tilde = "~" Backtick = "`" QuestionMark = "?" ExclamationMark = "!" LeftParenthesis = "(" RightParenthesis = ")" LeftBracket = "[" RightBracket = "]" LeftBrace = "{" RightBrace = "}" DoubleQuote = "\"" SingleQuote = "'" Backslash = "\\" CarriageReturn = "\r" Newline = "\n" CarriageReturnNewline = "\r\n" Tab = "\t" )
String constants for common characters and sequences.
const ( TypeInt = "int" TypeString = "str" TypeBool = "bool" TypeDecimal = "dec" TypeDate = "date" TypeDateTime = "datetime" TypeTime = "time" )
Type tokens for schema field type identification.
const DefaultI18NLanguage = "zh-CN"
DefaultI18NLanguage is the default language for the i18n system.
const PlaceholderKeyOperator = "Operator"
Placeholder key for named arguments in database queries.
const VEFVersion = "v0.19.2"
VEFVersion is the current version of the VEF Framework (semver format).
Variables ¶
var JSONNullBytes = []byte(JSONNull)
JSONNullBytes is the byte slice representation of JSON null.
Functions ¶
This section is empty.
Types ¶
type StorageProvider ¶ added in v0.10.1
type StorageProvider string
StorageProvider represents supported storage backend types.
const ( StorageMinIO StorageProvider = "minio" StorageMemory StorageProvider = "memory" StorageFilesystem StorageProvider = "filesystem" )
Supported storage providers.