MCPcopy Create free account
hub / github.com/apache/iotdb-client-go / getFloatByTsBlockColumnIndex

Method getFloatByTsBlockColumnIndex

client/rpcdataset.go:376–387  ·  view source on GitHub ↗
(tsBlockColumnIndex int32)

Source from the content-addressed store, hash-verified

374}
375
376func (s *IoTDBRpcDataSet) getFloatByTsBlockColumnIndex(tsBlockColumnIndex int32) (float32, error) {
377 if err := s.checkRecord(); err != nil {
378 return 0, err
379 }
380 if !s.isNull(tsBlockColumnIndex, s.tsBlockIndex) {
381 s.lastReadWasNull = false
382 return s.curTsBlock.GetColumn(tsBlockColumnIndex).GetFloat(s.tsBlockIndex)
383 } else {
384 s.lastReadWasNull = true
385 return 0, nil
386 }
387}
388
389func (s *IoTDBRpcDataSet) getIntByIndex(columnIndex int32) (int32, error) {
390 if index, err := s.getTsBlockColumnIndexForColumnIndex(columnIndex); err != nil {

Callers 2

getFloatByIndexMethod · 0.95
getFloatMethod · 0.95

Calls 4

checkRecordMethod · 0.95
isNullMethod · 0.95
GetColumnMethod · 0.80
GetFloatMethod · 0.65

Tested by

no test coverage detected