Class: Commander::OptionMatch

Inherits:
Struct
  • Object
show all
Defined in:
lib/nub/commander.rb

Instance Method Summary collapse

Instance Method Details

#flag?Boolean

Returns:

  • (Boolean)


289
290
291
# File 'lib/nub/commander.rb', line 289

def flag?
  return opt.type == FalseClass || opt.type == TrueClass
end

#hit?Boolean

Returns:

  • (Boolean)


286
287
288
# File 'lib/nub/commander.rb', line 286

def hit?
  return !!sym
end