MCPcopy Index your code
hub / github.com/uber/aresdb / GetBool

Method GetBool

memstore/common/data_value.go:737–743  ·  view source on GitHub ↗

GetBool returns bool value for Bool item type at index

(index int)

Source from the content-addressed store, hash-verified

735
736// GetBool returns bool value for Bool item type at index
737func (reader *ArrayValueReader) GetBool(index int) bool {
738 if index < 0 || index >= reader.length {
739 return false
740 }
741 val := *(*byte)(unsafe.Pointer(uintptr(reader.value) + uintptr(index/8)))
742 return val&(0x1<<uint8(index%8)) != 0x0
743}
744
745// Get returns the buffer pointer for the index-th item
746func (reader *ArrayValueReader) Get(index int) unsafe.Pointer {

Callers 2

arrayValueCompareFunction · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected