Class: CLI::Kit::Args::Tokenizer::Token
- Inherits:
-
Object
- Object
- CLI::Kit::Args::Tokenizer::Token
- Defined in:
- lib/cli/kit/args/tokenizer.rb
Constant Summary collapse
- OptionName =
Class.new(Token)
- LongOptionName =
Class.new(OptionName)
- ShortOptionName =
Class.new(OptionName)
- OptionValue =
Class.new(Token)
- PositionalArgument =
Class.new(Token)
- OptionValueOrPositionalArgument =
Class.new(Token)
- UnparsedArgument =
Class.new(Token)
Instance Attribute Summary collapse
-
#value ⇒ Object
readonly
: String.
Instance Method Summary collapse
-
#==(other) ⇒ Object
: (untyped other) -> bool.
-
#initialize(value) ⇒ Token
constructor
: (String value) -> void.
-
#inspect ⇒ Object
: -> String.
Constructor Details
#initialize(value) ⇒ Token
: (String value) -> void
30 31 32 |
# File 'lib/cli/kit/args/tokenizer.rb', line 30 def initialize(value) @value = value end |
Instance Attribute Details
#value ⇒ Object (readonly)
: String
27 28 29 |
# File 'lib/cli/kit/args/tokenizer.rb', line 27 def value @value end |
Instance Method Details
#==(other) ⇒ Object
: (untyped other) -> bool
40 41 42 |
# File 'lib/cli/kit/args/tokenizer.rb', line 40 def ==(other) self.class == other.class && @value == other.value end |
#inspect ⇒ Object
: -> String
35 36 37 |
# File 'lib/cli/kit/args/tokenizer.rb', line 35 def inspect "#<#{self.class.name} #{@value}>" end |