MCPcopy Create free account
hub / github.com/gavv/httpexpect / sortedKV

Method sortedKV

object.go:1206–1218  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1204}
1205
1206func (o *Object) sortedKV() []kv {
1207 kvs := make([]kv, 0, len(o.value))
1208
1209 for key, val := range o.value {
1210 kvs = append(kvs, kv{key: key, val: val})
1211 }
1212
1213 sort.Slice(kvs, func(i, j int) bool {
1214 return kvs[i].key < kvs[j].key
1215 })
1216
1217 return kvs
1218}
1219
1220func containsKey(
1221 opChain *chain, obj map[string]interface{}, key string,

Callers 8

KeysMethod · 0.95
ValuesMethod · 0.95
EveryMethod · 0.95
FilterMethod · 0.95
TransformMethod · 0.95
FindMethod · 0.95
FindAllMethod · 0.95
NotFindMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected