Documentation ¶
Index ¶
- Variables
- type Checker
- type Checkers
- type Date
- type Format
- type FormatParser
- type FormatRef
- type FormatRefs
- type Formats
- type Limit
- type LogFormatParser
- type LogParser
- type LongTime
- type MinOrMax
- type MultiParseError
- type MultiParser
- type NoChecker
- type OptionalTime
- type ParseError
- type ParseFmt
- type Parser
- type Range
- type ShortTime
- type StdFormatParser
- type ToTime
Constants ¶
This section is empty.
Variables ¶
View Source
var ( StdParser = NewStdParser() Logger = log.StandardLogger() DebugLogger = func() (l *log.Logger) { l = log.StandardLogger() l.SetLevel(log.DebugLevel) return }() DefaultFormatParser = StdParser /* TODO: add parser for gamma format.*/ DebugParser = NewLogger( defaultFormats.Ref(debugParser), Logger, ) DefaultParser = NewLogger( defaultFormats.Ref(StdParser), Logger, ) )
Functions ¶
This section is empty.
Types ¶
type Checkers ¶
type Checkers struct {
// contains filtered or unexported fields
}
func NewCheckers ¶
func NewCheckers() (c Checkers)
func NewCheckersWithCap ¶
type Date ¶
func (*Date) UnmarshalJSON ¶
type Format ¶
type Format string
func (Format) Ref ¶
func (f Format) Ref(parser FormatParser) (fr FormatRef)
type FormatParser ¶
type FormatRefs ¶
type FormatRefs struct {
// contains filtered or unexported fields
}
type Formats ¶
type Formats []Format
func FormatsFromStrings ¶
func (Formats) Ref ¶
func (f Formats) Ref(parser FormatParser) (fr FormatRefs)
type LogFormatParser ¶
type LogFormatParser struct {
// contains filtered or unexported fields
}
func NewLogFormatParser ¶
func NewLogFormatParser(parser FormatParser, logger *log.Logger) (l LogFormatParser)
func (LogFormatParser) ParseWithFormat ¶
type MultiParseError ¶
func (MultiParseError) Error ¶
func (m MultiParseError) Error() (s string)
func (MultiParseError) Unwrap ¶
func (m MultiParseError) Unwrap() (err error)
type MultiParser ¶
type MultiParser struct {
// contains filtered or unexported fields
}
type OptionalTime ¶
func (OptionalTime) IsSet ¶
func (ot OptionalTime) IsSet() (b bool)
type ParseError ¶
type ParseError struct {
// contains filtered or unexported fields
}
func (ParseError) Error ¶
func (p ParseError) Error() string
func (ParseError) Unwrap ¶
func (p ParseError) Unwrap() error
type StdFormatParser ¶
type StdFormatParser struct{}
func NewStdParser ¶
func NewStdParser() (s *StdFormatParser)
func (StdFormatParser) ParseWithFormat ¶
Click to show internal directories.
Click to hide internal directories.