MCPcopy Index your code
hub / github.com/TomWright/dasel / KeyValues

Method KeyValues

model/orderedmap/map.go:103–112  ·  view source on GitHub ↗

KeyValues returns the KeyValue pairs within the map, in the order that they were added.

()

Source from the content-addressed store, hash-verified

101
102// KeyValues returns the KeyValue pairs within the map, in the order that they were added.
103func (m *Map) KeyValues() []KeyValue {
104 res := make([]KeyValue, 0)
105 for _, key := range m.keys {
106 res = append(res, KeyValue{
107 Key: key,
108 Value: m.data[key],
109 })
110 }
111 return res
112}
113
114// Keys returns all the keys from the map.
115func (m *Map) Keys() []string {

Callers 1

TestKeyValuesFunction · 0.95

Calls

no outgoing calls

Tested by 1

TestKeyValuesFunction · 0.76