Documentation ¶
Index ¶
- func NewErrorLogger(prefix string, flag int) *log.Logger
- func NewNoticeLogger(prefix string, flag int) *log.Logger
- type DB
- type Datum
- type Row
- type Rows
- type Stmt
- type TriggerData
- func (td *TriggerData) FiredAfter() bool
- func (td *TriggerData) FiredBefore() bool
- func (td *TriggerData) FiredByDelete() bool
- func (td *TriggerData) FiredByInsert() bool
- func (td *TriggerData) FiredByTruncate() bool
- func (td *TriggerData) FiredByUpdate() bool
- func (td *TriggerData) FiredForRow() bool
- func (td *TriggerData) FiredForStatement() bool
- func (td *TriggerData) FiredInstead() bool
- type TriggerRow
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewErrorLogger ¶
NewErrorLogger creates an logger that writes into ERROR elog
Types ¶
type Row ¶
type Row struct {
// contains filtered or unexported fields
}
Row represents a single row from running a query
type Rows ¶
type Rows struct {
// contains filtered or unexported fields
}
Rows represents the result of running a prepared Stmt with Query
type Stmt ¶
type Stmt struct {
// contains filtered or unexported fields
}
Stmt represents the prepared SQL statement
type TriggerData ¶
type TriggerData struct { OldRow *TriggerRow NewRow *TriggerRow // contains filtered or unexported fields }
TriggerData represents the data passed by the trigger manager
func (*TriggerData) FiredAfter ¶
func (td *TriggerData) FiredAfter() bool
FiredAfter returns true if the trigger fired after the operation.
func (*TriggerData) FiredBefore ¶
func (td *TriggerData) FiredBefore() bool
FiredBefore returns true if the trigger fired before the operation.
func (*TriggerData) FiredByDelete ¶
func (td *TriggerData) FiredByDelete() bool
FiredByDelete returns true if the trigger was fired by a DELETE command.
func (*TriggerData) FiredByInsert ¶
func (td *TriggerData) FiredByInsert() bool
FiredByInsert returns true if the trigger was fired by an INSERT command.
func (*TriggerData) FiredByTruncate ¶
func (td *TriggerData) FiredByTruncate() bool
FiredByTruncate returns true if the trigger was fired by a TRUNCATE command.
func (*TriggerData) FiredByUpdate ¶
func (td *TriggerData) FiredByUpdate() bool
FiredByUpdate returns true if the trigger was fired by an UPDATE command.
func (*TriggerData) FiredForRow ¶
func (td *TriggerData) FiredForRow() bool
FiredForRow returns true if the trigger fired for a row-level event.
func (*TriggerData) FiredForStatement ¶
func (td *TriggerData) FiredForStatement() bool
FiredForStatement returns true if the trigger fired for a statement-level event.
func (*TriggerData) FiredInstead ¶
func (td *TriggerData) FiredInstead() bool
FiredInstead returns true if the trigger fired instead of the operation.
type TriggerRow ¶
type TriggerRow struct {
// contains filtered or unexported fields
}
TriggerRow is used in TriggerData as NewRow and OldRow
func (*TriggerRow) Scan ¶
func (row *TriggerRow) Scan(args ...interface{}) error
Scan sets the args from the TriggerRow
func (*TriggerRow) Set ¶
func (row *TriggerRow) Set(i int, val interface{})
Set sets the i'th value in the row