MCPcopy Create free account

hub / github.com/araddon/dateparse / functions

Functions45 in github.com/araddon/dateparse

↓ 68 callersMethodset
(start int, val string)
parseany.go:2036
↓ 26 callersMethodsetDay
()
parseany.go:2055
↓ 20 callersMethodsetYear
()
parseany.go:2062
↓ 16 callersMethodnextIs
(i int, b byte)
parseany.go:2029
↓ 15 callersFunctionParseAny
ParseAny parse an unknown date format, detect the layout. Normal parse. Equivalent Timezone rules as time.Parse(). NOTE: please see readme on mmdd v
parseany.go:146
↓ 11 callersMethodsetMonth
()
parseany.go:2047
↓ 10 callersFunctionMustParse
MustParse parse a date, and panic if it can't be parsed. Used for testing. Not recommended for most use-cases.
parseany.go:192
↓ 7 callersMethodparse
func (p *parser) remove(i, length int) { if len(p.format) > i+length { //append(a[:i], a[j:]...) p.format = append(p.format[0:i], p.format[i+leng
parseany.go:2155
↓ 6 callersFunctionParseIn
ParseIn with Location, equivalent to time.ParseInLocation() timezone/offset rules. Using location arg, if timezone/offset info exists in the datestri
parseany.go:159
↓ 6 callersMethodcoalesceTime
(end int)
parseany.go:2091
↓ 6 callersFunctionparseTime
(datestr string, loc *time.Location, opts ...ParserOption)
parseany.go:235
↓ 6 callersMethodtrimExtra
()
parseany.go:2137
↓ 6 callersFunctionunknownErr
(datestr string)
parseany.go:139
↓ 4 callersFunctionParseLocal
ParseLocal Given an unknown date format, detect the layout, using time.Local, parse. Set Location to time.Local. Same as ParseIn Location but lazily
parseany.go:182
↓ 4 callersFunctionParseStrict
ParseStrict parse an unknown date format. IF the date is ambigous mm/dd vs dd/mm then return an error. These return errors: 3.3.2014 , 8/8/71 etc
parseany.go:224
↓ 4 callersFunctionRetryAmbiguousDateWithSwap
RetryAmbiguousDateWithSwap is an option that allows retryAmbiguousDateWithSwap to be changed from its default
parseany.go:2004
↓ 3 callersFunctionPreferMonthFirst
PreferMonthFirst is an option that allows preferMonthFirst to be changed from its default
parseany.go:1996
↓ 2 callersFunctionParseFormat
ParseFormat parse's an unknown date-time string and returns a layout string that can parse this (and exact same format) other date-time strings. layo
parseany.go:210
↓ 2 callersFunctionfatal
(err error)
dateparse/main.go:128
↓ 2 callersFunctionnewParser
(dateStr string, loc *time.Location, opts ...ParserOption)
parseany.go:2011
↓ 2 callersFunctiontestDidPanic
(datestr string)
parseany_test.go:476
↓ 1 callersMethodcoalesceDate
(end int)
parseany.go:2069
↓ 1 callersMethodds
()
parseany.go:2088
↓ 1 callersFunctionisDay
(alpha string)
parseany.go:2174
↓ 1 callersFunctionisMonthFull
(alpha string)
parseany.go:2182
↓ 1 callersFunctionparseShotgunStyle
(raw string)
bench_test.go:101
↓ 1 callersMethodsetFullMonth
(month string)
parseany.go:2131
↓ 1 callersMethodts
()
parseany.go:2085
FunctionBenchmarkParseAny
(b *testing.B)
bench_test.go:36
FunctionBenchmarkShotgunParse
* go test -bench Parse BenchmarkShotgunParse 50000 37588 ns/op 13258 B/op 167 allocs/op BenchmarkDateparseParseAny 500000 5752
bench_test.go:26
FunctionTestInLocation
Lets test to see how this performs using different Timezones/Locations Also of note, try changing your server/machine timezones and repeat !!!!! The
parseany_test.go:619
FunctionTestOne
(t *testing.T)
parseany_test.go:11
FunctionTestPStruct
(t *testing.T)
parseany_test.go:486
FunctionTestParse
(t *testing.T)
parseany_test.go:422
FunctionTestParseErrors
(t *testing.T)
parseany_test.go:519
FunctionTestParseLayout
(t *testing.T)
parseany_test.go:529
FunctionTestParseStrict
(t *testing.T)
parseany_test.go:599
FunctionTestPreferMonthFirst
(t *testing.T)
parseany_test.go:728
FunctionTestRetryAmbiguousDateWithSwap
(t *testing.T)
parseany_test.go:746
Functionmain
()
example/main.go:139
Functionmain
()
dateparse/main.go:18
FunctionparseAny
(datestr string, loc *time.Location, utc bool)
dateparse/main.go:106
FunctionparseIn
(datestr string, loc *time.Location, utc bool)
dateparse/main.go:95
FunctionparseLocal
(datestr string, loc *time.Location, utc bool)
dateparse/main.go:83
FunctionparseStrict
(datestr string, loc *time.Location, utc bool)
dateparse/main.go:117