MCPcopy Create free account
hub / github.com/apache/fory / ReadBool

Method ReadBool

go/fory/buffer.go:301–310  ·  view source on GitHub ↗

ReadBool reads a bool and sets error on bounds violation

(err *Error)

Source from the content-addressed store, hash-verified

299
300// ReadBool reads a bool and sets error on bounds violation
301func (b *ByteBuffer) ReadBool(err *Error) bool {
302 if b.readerIndex+1 > len(b.data) {
303 if !b.fill(1, err) {
304 return false
305 }
306 }
307 v := b.data[b.readerIndex]
308 b.readerIndex++
309 return v != 0
310}
311
312// ReadByte reads a byte and sets error on bounds violation
313func (b *ByteBuffer) ReadByte(err *Error) byte {

Callers 13

testBufferFunction · 0.95
ReadDataMethod · 0.45
readRemainingFieldMethod · 0.45
readOptionFastFunction · 0.45
readFieldsInOrderMethod · 0.45
RawBoolMethod · 0.45
readFastMethod · 0.45
ReadBufferObjectMethod · 0.45
DeserializeFunction · 0.45
readMapStringBoolFunction · 0.45
readBoolListValuesFunction · 0.45
ReadTypedMethod · 0.45

Calls 1

fillMethod · 0.95

Tested by

no test coverage detected