☰
Index
Modules:
ozark
,
ozark/collection
,
ozark/driver/dbmeta
,
ozark/driver/private/types
,
ozark/model
,
ozark/query
.
API symbols
`$`:
query: proc `$`(sql: SqlQuery): string
`[]`:
collection: proc `[]`[T](col: Collection[T]; index: int): T
appendSqlArgs:
types: proc appendSqlArgs(callNode: var NimNode; args: NimNode)
BigInt:
types: DataType.BigInt
BigSerial:
types: DataType.BigSerial
Bit:
types: DataType.Bit
BitVarying:
types: DataType.BitVarying
Blob:
types: DataType.Blob
Boolean:
types: DataType.Boolean
Box:
types: DataType.Box
Bytea:
types: DataType.Bytea
Char:
types: DataType.Char
Cidr:
types: DataType.Cidr
Circle:
types: DataType.Circle
Collection:
collection: object Collection
contains:
collection: proc contains[T](col: Collection[T]; key, val: string): bool
countSqlArgs:
types: proc countSqlArgs(args: NimNode): int
DataType:
types: enum DataType
Date:
types: DataType.Date
DoublePrecision:
types: DataType.DoublePrecision
dropTable:
query: macro dropTable(modelTuple: untyped; cascade: static bool = false): untyped
Enum:
types: DataType.Enum
extractSQL:
query: macro extractSQL(sql: NimNode): untyped
first:
collection: proc first[T](col: Collection[T]): T
fromSQL:
query: macro fromSQL(sql: untyped): untyped
get:
collection: proc get[T](col: Collection[T]; index: int): T
getAll:
collection: proc getAll[T](col: Collection[T]): lent seq[T]
getDatatype:
model: proc getDatatype(dt: string): (DataType, Option[seq[string]])
getDriverType:
types: proc getDriverType(n: NimNode): SqlDriver
getPlaceholder:
query: proc getPlaceholder(modelTuple: NimNode; idx: int = 1): string
getSqlDriver:
dbmeta: proc getSqlDriver(name: static string = "main"): SqlDriver
getTableName:
model: proc getTableName(id: string): string
Inet:
types: DataType.Inet
initStaticDriver:
dbmeta: proc initStaticDriver(name: static string; driver: static SqlDriver)
insert:
query: macro insert(modelTuple, data: untyped): untyped
Int:
types: DataType.Int
Int4:
types: DataType.Int4
Integer:
types: DataType.Integer
Interval:
types: DataType.Interval
isEmpty:
collection: proc isEmpty[T](col: Collection[T]): bool
items:
collection: iterator items[T](col: Collection[T]): T
Json:
types: DataType.Json
Jsonb:
types: DataType.Jsonb
len:
collection: proc len[T](col: Collection[T]): int
Line:
types: DataType.Line
Lseg:
types: DataType.Lseg
Macaddr:
types: DataType.Macaddr
Macaddr8:
types: DataType.Macaddr8
mitems:
collection: iterator mitems[T](col: Collection[T]): var T
Model:
model: object Model
Models:
model: var Models
ModelsTable:
model: object ModelsTable
Money:
types: DataType.Money
newModel:
model: macro newModel(id, fields: untyped)
Numeric:
types: DataType.Numeric
orWhere:
query: macro orWhere(sql: untyped; col: static string; val: untyped): untyped
orWhereNot:
query: macro orWhereNot(sql: untyped; col: static string; val: untyped): untyped
ozarkCreateTableResult:
query: proc ozarkCreateTableResult(sql: static[string]): NimNode
ozarkHoldModel:
query: proc ozarkHoldModel[T](t: T)
query: proc ozarkHoldModel[T: typedesc](t: T)
ozarkInsertResult:
query: proc ozarkInsertResult(sql: static[string]; vals: seq[string]): NimNode
ozarkLimitResult:
query: proc ozarkLimitResult(sql: static[string]): NimNode
OzarkModelDefect:
query: object OzarkModelDefect
ozarkOrderByResult:
query: proc ozarkOrderByResult(sql: static[string]; vals: varargs[string]): NimNode
ozarkRawSQLResult:
query: proc ozarkRawSQLResult(sql: static[string]; vals: varargs[string]): NimNode
ozarkRemoveResult:
query: proc ozarkRemoveResult(sql: static[string]): NimNode
ozarkSelectResult:
query: proc ozarkSelectResult(sql: static[string]): NimNode
ozarkUpdateResult:
query: proc ozarkUpdateResult(sql: static[string]; vals: seq[string]): NimNode
ozarkWhereInResult:
query: proc ozarkWhereInResult(sql: static[string]; vals: varargs[string]): NimNode
ozarkWhereResult:
query: proc ozarkWhereResult(sql: static[string]; val: varargs[string]): NimNode
Path:
types: DataType.Path
PGLsn:
types: DataType.PGLsn
PGSnapshot:
types: DataType.PGSnapshot
Point:
types: DataType.Point
Polygon:
types: DataType.Polygon
prepareTable:
query: macro prepareTable(modelTuple): untyped
Real:
types: DataType.Real
removeRow:
query: macro removeRow(modelTuple: untyped): untyped
RuntimeSchemas:
model: type RuntimeSchemas
RuntimeSqlSchemas:
model: var RuntimeSqlSchemas
SchemaTable:
model: type SchemaTable
select:
query: macro select(modelTuple: untyped; cols: static openArray[string]): untyped
query: macro select(modelTuple: untyped; col: static string): untyped
selectAll:
query: macro selectAll(modelTuple: untyped): untyped
Serial:
types: DataType.Serial
SmallInt:
types: DataType.SmallInt
SmallSerial:
types: DataType.SmallSerial
SqlSchemas:
model: var SqlSchemas
StaticSchemas:
model: const StaticSchemas
table:
query: template table(models: ptr ModelsTable; name): untyped
Text:
types: DataType.Text
Time:
types: DataType.Time
Timestamp:
types: DataType.Timestamp
TimestampTz:
types: DataType.TimestampTz
Timezone:
types: DataType.Timezone
TsQuery:
types: DataType.TsQuery
TsVector:
types: DataType.TsVector
unserializeSchemas:
model: proc unserializeSchemas(jsonSchema: string): RuntimeSchemas
update:
query: macro update(modelTuple, data: untyped): untyped
Uuid:
types: DataType.Uuid
Varchar:
types: DataType.Varchar
where:
query: macro where(sql: untyped; col: static string; vals: untyped): untyped
whereEndsLike:
query: macro whereEndsLike(sql: untyped; col: static string; val: untyped): untyped
whereIn:
query: macro whereIn(sql: untyped; col: static string; vals: untyped): untyped
whereLike:
query: macro whereLike(sql: untyped; col: static string; val: untyped): untyped
whereNot:
query: macro whereNot(sql: untyped; col: static string; val: untyped): untyped
whereNotEndsLike:
query: macro whereNotEndsLike(sql: untyped; col: static string; val: untyped): untyped
whereNotIn:
query: macro whereNotIn(sql: untyped; col: static string; vals: untyped): untyped
whereNotLike:
query: macro whereNotLike(sql: untyped; col: static string; val: untyped): untyped
whereNotStartsLike:
query: macro whereNotStartsLike(sql: untyped; col: static string; val: untyped): untyped
whereStartsLike:
query: macro whereStartsLike(sql: untyped; col: static string; val: untyped): untyped
withColumn:
query: template withColumn(x: NimNode; col: string; body)
withColumnCheck:
query: template withColumnCheck(model: NimNode; col: string; body)
withColumnsCheck:
query: template withColumnsCheck(model: NimNode; cols: openArray[string]; body)
withTableCheck:
query: template withTableCheck(modelTuple: NimNode; body)