Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Column ¶
func (*Column) SetSelectSQL ¶
func (Column) UpdateString ¶
UpdateString returns the SQL statement to UPDATE the column.
type Columns ¶
type Columns struct { Cols map[string]*Column TableName string TableAlias string // contains filtered or unexported fields }
Columns represent a list of columns, related to a given table.
func ColumnsForStruct ¶
func NewColumns ¶
NewColumns constructs a list of columns for a given table name.
func NewColumnsWithAlias ¶
NewColumnsWithAlias constructs a list of columns for a given table name, using a given alias for the table.
func (Columns) Readable ¶
func (c Columns) Readable() *ReadableColumns
Readable gets a list of the readable columns from the column list.
func (Columns) SymbolizedString ¶
SymbolizedString returns a list of tokens (:token) to bind a value to an INSERT query.
func (Columns) Writeable ¶
func (c Columns) Writeable() *WriteableColumns
Writeable gets a list of the writeable columns from the column list.
type ReadableColumns ¶
type ReadableColumns struct {
Columns
}
func (ReadableColumns) SelectString ¶
func (c ReadableColumns) SelectString() string
SelectString returns the SQL column list part of the SELECT query.
type Tags ¶
type Tags []Tag
Tags is a group of pop tags defined in just one model field.
func TagsFor ¶
func TagsFor(field reflect.StructField) Tags
TagsFor is a function which returns all tags defined in model field.
type WriteableColumns ¶
type WriteableColumns struct {
Columns
}
func (WriteableColumns) UpdateString ¶
func (c WriteableColumns) UpdateString() string
UpdateString returns the SQL column list part of the UPDATE query.