MCPcopy Create free account
hub / github.com/DataDog/jsonapi / UnmarshalText

Method UnmarshalText

jsonapi_test.go:418–425  ·  view source on GitHub ↗
(text []byte)

Source from the content-addressed store, hash-verified

416}
417
418func (i *EncodingIntID) UnmarshalText(text []byte) error {
419 v, err := strconv.Atoi(string(text))
420 if err != nil {
421 return err
422 }
423 *i = EncodingIntID(v)
424 return nil
425}
426
427type ArticleEncodingIntID struct {
428 ID EncodingIntID `jsonapi:"primary,articles"`

Callers 1

unmarshalFieldsMethod · 0.80

Calls 1

EncodingIntIDTypeAlias · 0.85

Tested by

no test coverage detected