MCPcopy Create free account
hub / github.com/cel-expr/cel-go / timestampGetSeconds

Function timestampGetSeconds

common/stdlib/standard.go:1028–1034  ·  view source on GitHub ↗
(ts, tz ref.Val)

Source from the content-addressed store, hash-verified

1026}
1027
1028func timestampGetSeconds(ts, tz ref.Val) ref.Val {
1029 t, err := inTimeZone(ts, tz)
1030 if err != nil {
1031 return types.NewErrFromString(err.Error())
1032 }
1033 return types.Int(t.Second())
1034}
1035
1036func timestampGetMilliseconds(ts, tz ref.Val) ref.Val {
1037 t, err := inTimeZone(ts, tz)

Callers 1

initFunction · 0.70

Calls 4

NewErrFromStringFunction · 0.92
IntTypeAlias · 0.92
inTimeZoneFunction · 0.85
ErrorMethod · 0.45

Tested by

no test coverage detected