MCPcopy Create free account
hub / github.com/dolthub/doltgresql / iterArrayValues

Method iterArrayValues

postgres/parser/json/encoded.go:210–222  ·  view source on GitHub ↗

iterArrayValues iterates through all the values of an encoded array without requiring decoding of all of them.

()

Source from the content-addressed store, hash-verified

208// iterArrayValues iterates through all the values of an encoded array without
209// requiring decoding of all of them.
210func (j *jsonEncoded) iterArrayValues() encodedArrayIterator {
211 if j.typ != ArrayJSONType {
212 panic("can only iterate through the array values of an array")
213 }
214
215 return encodedArrayIterator{
216 dataOffset: containerHeaderLen + j.containerLen*jEntryLen,
217 curDataIdx: 0,
218 len: j.containerLen,
219 idx: 0,
220 data: j.value,
221 }
222}
223
224type encodedObjectIterator struct {
225 curKeyIdx int

Callers 2

shallowDecodeMethod · 0.95
ExistsMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected