Class: Arrayr::Value

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

Instance Method Summary collapse

Constructor Details

#initialize(value = nil) ⇒ Value

Returns a new instance of Value.



28
29
30
# File 'lib/arrayr.rb', line 28

def initialize(value=nil)
  @value = value
end

Instance Method Details

#to_aObject



31
32
33
34
# File 'lib/arrayr.rb', line 31

def to_a
  return nil if @value.nil?
  @value.split(',').map(&:strip)
end