MCPcopy Index your code
hub / github.com/DataDog/jsonapi / MarshalIdentifier

Interface MarshalIdentifier

jsonapi.go:374–376  ·  view source on GitHub ↗

MarshalIdentifier can be optionally implemented to control marshaling of the primary field to a string. The order of operations for marshaling the primary field is: 1. Use MarshalIdentifier if it is implemented 2. Use the value directly if it is a string 3. Use fmt.Stringer if it is implemented 4.

Source from the content-addressed store, hash-verified

372// 3. Use fmt.Stringer if it is implemented
373// 4. Fail
374type MarshalIdentifier interface {
375 MarshalID() string
376}
377
378// UnmarshalIdentifier can be optionally implemented to control unmarshaling of the primary field from a string.
379//

Callers 1

makeResourceObjectMethod · 0.65

Implementers 1

ArticleIntIDjsonapi_test.go

Calls

no outgoing calls

Tested by

no test coverage detected