@relation attribute -- specifies the relation/type name to be used for Connection's ORM functions. If none is set, dpq will default to the structure's name in lower_snake_case.
Specifies that the member should be completely ignored as far as the DB is concerned.
@PK / @Pkey / @PrimaryKey attribute -- specifies that the member should be a PK. Coumpound PKs are not supported.
@attribute / @attr -- specifies the name of the attribute to be used.
Allows placing any text after the column definition when ensureSchema is ran.
Specifies the type for the member, overrides any serialiser-provided type
A shortcut to @suffix("NOT NULL")
@index
Shortcut for @type("SERIAL")
SHORTCUT for @type("SERIAL4")
SHORTCUT for @type("SERIAL8")
@uniqueIndex
Specifies that the member is a foriegn key, ensureSchema will create a FK constraint as well as an index for it. Finds the referenced table's PK by itself.
Specifies that the member/column should have an index created on it. If unique is set, it well be a unique index.
Returns a list of Columns for all the given type's serialisable members, with their actual names as they're used in SQL.
Transforms the given string into lower_snake_case at compile-time. Used for attribute and relation names and probably not very useful outside the library itself.
Attribute name for the given type, can be specified with @attribute. If @attribute is not specified, the member's name will just be lower_snake_cased and returned.
A filter implementation for serialisableMembers
Workaround for getSymbolsByUDA not working on structs/classes with private members. Returns all the structure's members that have the given UDA.
Returns true if the member m is a PK on T.
Determines if a member is a public, non-static, de-facto data field. In addition to plain data fields, R/W properties are also accepted.
Determins if a member is a public, non-static data field.
Returns the name of the PK attribute (SQL name)
Returns a string containing the name of the type member that is marked with @PK
Relation/type name for the given type, can be set with @relation attribute. If @relation is not set, type's name will be lower_snake_cased.
Gives a list of all the structure's members that will be used in the DB. Ignores @ignore members, non-RW and non-public members.