Documentation
¶
Index ¶
- type Date
- func (d Date) After(t Date) bool
- func (d Date) Before(t Date) bool
- func (d Date) Equal(t Date) bool
- func (d Date) MarshalText() ([]byte, error)
- func (d *Date) Scan(v interface{}) error
- func (d Date) String() string
- func (d Date) Sub(t Date) int
- func (d *Date) UnmarshalText(b []byte) error
- func (d Date) Value() (driver.Value, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Date ¶
A Date specifies the year, month and day.
func Parse ¶
Parse parses the d with layout and returns the value of Date. The layout follows the format of time.Parse.
func (Date) MarshalText ¶
MarshalText implements the encoding.TextMarshaler interface. The output is in "YYYY-MM-DD" format.
func (*Date) UnmarshalText ¶
UnmarshalText implements the encoding.TextUnmarshaler interface. The formats it supports are "2006-01-02", "2006/01/02" and "02 Jan 2006".
Click to show internal directories.
Click to hide internal directories.