Class: NArray

Inherits:
Object
  • Object
show all
Defined in:
lib/ext/narray_ext.rb

Instance Method Summary collapse

Instance Method Details

#typeObject



6
7
8
9
10
11
12
13
14
15
16
17
18
19
# File 'lib/ext/narray_ext.rb', line 6

def type
  case typecode
  when 1 then :byte
  when 2 then :sint
  when 3 then :int
  when 4 then :sfloat
  when 5 then :float
  when 6 then :scomplex
  when 7 then :complex
  when 8 then :object
  else
    raise "Unknown typecode: #{typecode}"
  end
end