MCPcopy Index your code
hub / github.com/devfeel/mapper / Get

Method Get

convert.go:190–198  ·  view source on GitHub ↗

Get int by index from int slice

(i int, args ...int)

Source from the content-addressed store, hash-verified

188
189// Get int by index from int slice
190func (a argInt) Get(i int, args ...int) (r int) {
191 if i >= 0 && i < len(a) {
192 r = a[i]
193 }
194 if len(args) > 0 {
195 r = args[0]
196 }
197 return
198}
199
200// TimeToUnix transform time to Unix time, the number of seconds elapsed
201func TimeToUnix(t time.Time) int64 {

Callers 3

ToStringFunction · 0.80
buildFieldMappingsFunction · 0.80
getStructTagMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected