Class: RParsec::Failure
- Inherits:
-
Object
- Object
- RParsec::Failure
- Defined in:
- lib/rparsec/error.rb
Overview
:nodoc:
Instance Attribute Summary collapse
-
#index ⇒ Object
Returns the value of attribute index.
-
#input ⇒ Object
readonly
Returns the value of attribute input.
Instance Method Summary collapse
-
#initialize(ind, input, message = nil) ⇒ Failure
constructor
A new instance of Failure.
- #msg ⇒ Object
Constructor Details
#initialize(ind, input, message = nil) ⇒ Failure
Returns a new instance of Failure.
13 14 15 16 17 |
# File 'lib/rparsec/error.rb', line 13 def initialize(ind, input, = nil) @index = ind @input = input @msg = end |
Instance Attribute Details
#index ⇒ Object
Returns the value of attribute index.
20 21 22 |
# File 'lib/rparsec/error.rb', line 20 def index @index end |
#input ⇒ Object (readonly)
Returns the value of attribute input.
19 20 21 |
# File 'lib/rparsec/error.rb', line 19 def input @input end |
Instance Method Details
#msg ⇒ Object
22 |
# File 'lib/rparsec/error.rb', line 22 def msg = @msg.to_s |