Documentation ¶
Index ¶
- Constants
- type GlobalIdentity
- func (gi *GlobalIdentity) GetAsMap() map[string]string
- func (gi *GlobalIdentity) GetKey() string
- func (gi *GlobalIdentity) PutKey(v string) allocator.AllocatorKey
- func (gi *GlobalIdentity) PutKeyFromMap(v map[string]string) allocator.AllocatorKey
- func (gi *GlobalIdentity) PutValue(key, value any) allocator.AllocatorKey
- func (gi *GlobalIdentity) Value(key any) any
Constants ¶
const ( // MetadataKeyBackendKey is the key used to store the backend key. MetadataKeyBackendKey = iota )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GlobalIdentity ¶
type GlobalIdentity struct { labels.LabelArray // contains filtered or unexported fields }
GlobalIdentity is the structure used to store an identity
func (*GlobalIdentity) GetAsMap ¶
func (gi *GlobalIdentity) GetAsMap() map[string]string
GetAsMap encodes a GlobalIdentity a map of keys to values. The keys will include a source delimted by a ':'. This output is pareable by PutKeyFromMap.
func (*GlobalIdentity) GetKey ¶
func (gi *GlobalIdentity) GetKey() string
GetKey encodes an Identity as string
func (*GlobalIdentity) PutKey ¶
func (gi *GlobalIdentity) PutKey(v string) allocator.AllocatorKey
PutKey decodes an Identity from its string representation
func (*GlobalIdentity) PutKeyFromMap ¶
func (gi *GlobalIdentity) PutKeyFromMap(v map[string]string) allocator.AllocatorKey
PutKeyFromMap decodes an Identity from a map of key to value. Output from GetAsMap can be parsed. Note: NewLabelArrayFromMap will parse the ':' separated label source from the keys because the source parameter is ""
func (*GlobalIdentity) PutValue ¶ added in v1.14.4
func (gi *GlobalIdentity) PutValue(key, value any) allocator.AllocatorKey
PutValue puts metadata inside the global identity for the given 'key' with the given 'value'.
func (*GlobalIdentity) Value ¶ added in v1.14.4
func (gi *GlobalIdentity) Value(key any) any
Value returns the value stored in the metadata map.