MCPcopy Create free account
hub / github.com/araddon/qlbridge / ValueToTime

Function ValueToTime

value/coerce.go:333–335  ·  view source on GitHub ↗

ValueToTime Convert a value type to a time if possible

(val Value)

Source from the content-addressed store, hash-verified

331
332// ValueToTime Convert a value type to a time if possible
333func ValueToTime(val Value) (time.Time, bool) {
334 return ValueToTimeAnchor(val, time.Now())
335}
336
337// ValueToTimeAnchor given a value, and a time anchor, conver to time.
338// use "now-3d" anchoring if has prefix "now".

Callers 9

mapTimeEvalFunction · 0.92
timeTruncEvalTwoFunction · 0.92
addValueMethod · 0.92
evalBinaryFunction · 0.92
walkTernaryFunction · 0.92
MapTimeMethod · 0.85
CastFunction · 0.85
EqualFunction · 0.85
TestValueToTimeFunction · 0.85

Calls 1

ValueToTimeAnchorFunction · 0.85

Tested by 1

TestValueToTimeFunction · 0.68