Documentation
¶
Index ¶
- func ColumnNameConversion(name string) string
- func GetColumnName(name string) string
- func GetSession() *dbr.Session
- func Initialize(dbType, dsn string)
- type DbrObjxMap
- type Row
- type RowInterface
- type Table
- func (t *Table) Delete() *dbr.DeleteBuilder
- func (t *Table) GetName() string
- func (t *Table) GetRow() RowInterface
- func (t *Table) GetRowCollection() interface{}
- func (t *Table) Initialize() TableInterface
- func (t *Table) Insert() *dbr.InsertBuilder
- func (t *Table) Load(value ...interface{}) (RowInterface, error)
- func (t *Table) Select(column ...string) *dbr.SelectBuilder
- func (t *Table) Update() *dbr.UpdateBuilder
- type TableInterface
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ColumnNameConversion ¶
func GetColumnName ¶
func GetSession ¶
func Initialize ¶
func Initialize(dbType, dsn string)
Types ¶
type DbrObjxMap ¶
func NewObjxMap ¶
func NewObjxMap(v interface{}) (o DbrObjxMap)
func (DbrObjxMap) MarshalJSON ¶
func (o DbrObjxMap) MarshalJSON() ([]byte, error)
MarshalJSON correctly serializes a NullTime to JSON
func (*DbrObjxMap) Scan ¶
func (o *DbrObjxMap) Scan(value interface{}) error
Scan implements the Scanner interface. The value type must be time.Time or string / []byte (formatted time-string), otherwise Scan fails.
func (*DbrObjxMap) UnmarshalJSON ¶
func (o *DbrObjxMap) UnmarshalJSON(b []byte) error
UnmarshalJSON correctly deserializes an DbrObjxMap from JSON
type Row ¶
type Row struct { Table *Table `json:"-"` Columns []string `json:"-"` Instance RowInterface `json:"-"` // contains filtered or unexported fields }
func (*Row) BeforeSave ¶
func (*Row) ContainsPrimaryKeys ¶
func (*Row) GetColumns ¶
func (*Row) Initialize ¶
func (r *Row) Initialize() RowInterface
type RowInterface ¶
type Table ¶
type Table struct { Name string `json:"-"` PkColumns []string `json:"-"` Instance TableInterface }
func (*Table) Delete ¶
func (t *Table) Delete() *dbr.DeleteBuilder
func (*Table) GetRow ¶
func (t *Table) GetRow() RowInterface
func (*Table) GetRowCollection ¶
func (t *Table) GetRowCollection() interface{}
func (*Table) Initialize ¶
func (t *Table) Initialize() TableInterface
func (*Table) Insert ¶
func (t *Table) Insert() *dbr.InsertBuilder
func (*Table) Load ¶
func (t *Table) Load(value ...interface{}) (RowInterface, error)
func (*Table) Update ¶
func (t *Table) Update() *dbr.UpdateBuilder
type TableInterface ¶
type TableInterface interface { Initialize() TableInterface Select(column ...string) *dbr.SelectBuilder Insert() *dbr.InsertBuilder Update() *dbr.UpdateBuilder Delete() *dbr.DeleteBuilder Load(value ...interface{}) (RowInterface, error) GetName() string GetRow() RowInterface GetRowCollection() interface{} }
Click to show internal directories.
Click to hide internal directories.