Class: ArrowFormat::Float32Type

Inherits:
FloatingPointType show all
Defined in:
lib/arrow-format/type.rb

Instance Attribute Summary

Attributes inherited from FloatingPointType

#precision

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from FloatingPointType

#to_flatbuffers

Methods inherited from Type

#to_s

Constructor Details

#initializeFloat32Type

Returns a new instance of Float32Type.



303
304
305
# File 'lib/arrow-format/type.rb', line 303

def initialize
  super(:single)
end

Class Method Details

.singletonObject



298
299
300
# File 'lib/arrow-format/type.rb', line 298

def singleton
  @singleton ||= new
end

Instance Method Details

#buffer_typeObject



311
312
313
# File 'lib/arrow-format/type.rb', line 311

def buffer_type
  :f32
end

#build_array(size, validity_buffer, values_buffer) ⇒ Object



315
316
317
# File 'lib/arrow-format/type.rb', line 315

def build_array(size, validity_buffer, values_buffer)
  Float32Array.new(size, validity_buffer, values_buffer)
end

#nameObject



307
308
309
# File 'lib/arrow-format/type.rb', line 307

def name
  "Float32"
end