Documentation ¶
Index ¶
- Constants
- Variables
- type Date
- type Email
- type File
- func (file File) Bytes() ([]byte, error)
- func (file File) FileSize() int64
- func (file File) Filename() string
- func (file *File) InitFromBytes(data []byte, filename string)
- func (file *File) InitFromMultipart(header *multipart.FileHeader)
- func (file File) MarshalJSON() ([]byte, error)
- func (file File) Reader() (io.ReadCloser, error)
- func (file *File) UnmarshalJSON(data []byte) error
- type UUID
Constants ¶
View Source
const DateFormat = "2006-01-02"
Variables ¶
View Source
var ErrValidationEmail = errors.New("email: failed to pass regex validation")
ErrValidationEmail is the sentinel error returned when an email fails validation
Functions ¶
This section is empty.
Types ¶
type Date ¶
func (Date) MarshalJSON ¶
func (*Date) UnmarshalJSON ¶
func (*Date) UnmarshalText ¶ added in v1.12.0
type Email ¶ added in v1.3.9
type Email string
Email represents an email address. It is a string type that must pass regex validation before being marshalled to JSON or unmarshalled from JSON.
func (Email) MarshalJSON ¶ added in v1.3.9
func (*Email) UnmarshalJSON ¶ added in v1.3.9
type File ¶ added in v1.12.0
type File struct {
// contains filtered or unexported fields
}
func (*File) InitFromBytes ¶ added in v1.12.0
func (*File) InitFromMultipart ¶ added in v1.12.0
func (file *File) InitFromMultipart(header *multipart.FileHeader)
func (File) MarshalJSON ¶ added in v1.12.0
func (*File) UnmarshalJSON ¶ added in v1.12.0
Click to show internal directories.
Click to hide internal directories.