Class: Commandorobo::Arguments

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(raw) ⇒ Arguments

Returns a new instance of Arguments.



75
76
77
# File 'lib/commandorobo.rb', line 75

def initialize(raw)
    @raw = raw
end

Instance Attribute Details

#rawObject (readonly)

Returns the value of attribute raw.



74
75
76
# File 'lib/commandorobo.rb', line 74

def raw
  @raw
end

Instance Method Details

#noswitchObject



83
84
85
# File 'lib/commandorobo.rb', line 83

def noswitch
    Commandorobo::Utils::remove_switch(@raw.join(' '))
end

#switchesObject



79
80
81
# File 'lib/commandorobo.rb', line 79

def switches
    Commandorobo::Utils::consume_switch(@raw.join(' '))
end