Documentation ¶
Index ¶
- func RegisterWithSchema(reg register)
- type Bool
- type ByteSlice
- func (ns ByteSlice) Interface() interface{}
- func (ns ByteSlice) MarshalJSON() ([]byte, error)
- func (ns *ByteSlice) Scan(value interface{}) error
- func (ns *ByteSlice) UnmarshalJSON(text []byte) error
- func (ns *ByteSlice) UnmarshalText(text []byte) error
- func (ns ByteSlice) Value() (driver.Value, error)
- type Float32
- type Float64
- type Int
- type Int32
- type Int64
- type String
- type Time
- type UInt32
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterWithSchema ¶
func RegisterWithSchema(reg register)
RegisterWithSchema allows for the nulls package to be used with http://www.gorillatoolkit.org/pkg/schema#Converter
Types ¶
type Bool ¶
Bool replaces sql.NullBool with an implementation that supports proper JSON encoding/decoding.
func (Bool) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*Bool) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the proper representation of that value. The strings "true" and "t" will be considered "true", "false" and "f" will be treated as "false". All other values will be set to null by Valid = false
func (*Bool) UnmarshalText ¶
type ByteSlice ¶
ByteSlice adds an implementation for []byte that supports proper JSON encoding/decoding.
func NewByteSlice ¶
NewByteSlice returns a new, properly instantiated ByteSlice object.
func (ByteSlice) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*ByteSlice) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the propert representation of that value.
func (*ByteSlice) UnmarshalText ¶
type Float32 ¶
Float32 adds an implementation for float32 that supports proper JSON encoding/decoding.
func NewFloat32 ¶
NewFloat32 returns a new, properly instantiated Float32 object.
func (Float32) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*Float32) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the propert representation of that value.
func (*Float32) UnmarshalText ¶
type Float64 ¶
type Float64 sql.NullFloat64
Float64 replaces sql.NullFloat64 with an implementation that supports proper JSON encoding/decoding.
func NewFloat64 ¶
NewFloat64 returns a new, properly instantiated Float64 object.
func (Float64) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*Float64) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the propert representation of that value.
func (*Float64) UnmarshalText ¶
type Int ¶
Int adds an implementation for int that supports proper JSON encoding/decoding.
func (Int) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*Int) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the propert representation of that value.
func (*Int) UnmarshalText ¶
type Int32 ¶
Int32 adds an implementation for int32 that supports proper JSON encoding/decoding.
func (Int32) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*Int32) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the propert representation of that value.
func (*Int32) UnmarshalText ¶
type Int64 ¶
Int64 replaces sql.Int64 with an implementation that supports proper JSON encoding/decoding.
func (Int64) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*Int64) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the propert representation of that value.
func (*Int64) UnmarshalText ¶
type String ¶
type String sql.NullString
String replaces sql.NullString with an implementation that supports proper JSON encoding/decoding.
func (String) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*String) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the propert representation of that value.
func (*String) UnmarshalText ¶
type Time ¶
Time replaces sql.NullTime with an implementation that supports proper JSON encoding/decoding.
func (Time) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*Time) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the propert representation of that value.
func (*Time) UnmarshalText ¶
type UInt32 ¶
UInt32 adds an implementation for int that supports proper JSON encoding/decoding.
func (UInt32) MarshalJSON ¶
MarshalJSON marshals the underlying value to a proper JSON representation.
func (*UInt32) UnmarshalJSON ¶
UnmarshalJSON will unmarshal a JSON value into the propert representation of that value.