class OptimistXL::BooleanOption
Flag option. Has no arguments. Can be negated with “no-”.
Public Class Methods
new()
click to toggle source
Calls superclass method
OptimistXL::Option::new
# File lib/optimist_xl.rb, line 1134 def initialize super() @default = false @min_args = 0 @max_args = 0 end
Public Instance Methods
parse(_paramlist, neg_given)
click to toggle source
# File lib/optimist_xl.rb, line 1141 def parse(_paramlist, neg_given) return(self.name.to_s =~ /^no_/ ? neg_given : !neg_given) end