Class: CLI::Kit::Args::Parser::Node::Argument

Inherits:
CLI::Kit::Args::Parser::Node show all
Defined in:
lib/cli/kit/args/parser/node.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value) ⇒ Argument

: (String value) -> void



88
89
90
91
# File 'lib/cli/kit/args/parser/node.rb', line 88

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

Instance Attribute Details

#valueObject (readonly)

: String



85
86
87
# File 'lib/cli/kit/args/parser/node.rb', line 85

def value
  @value
end

Instance Method Details

#==(other) ⇒ Object

: (untyped other) -> bool



99
100
101
# File 'lib/cli/kit/args/parser/node.rb', line 99

def ==(other)
  !!(super(other) && @value == other.value)
end

#inspectObject

: -> String



94
95
96
# File 'lib/cli/kit/args/parser/node.rb', line 94

def inspect
  "#<#{self.class.name} #{@value}>"
end