Class: Xrc::Parser
- Inherits:
-
REXML::Parsers::SAX2Parser
- Object
- REXML::Parsers::SAX2Parser
- Xrc::Parser
- Defined in:
- lib/xrc/parser.rb
Constant Summary collapse
- EVENTS =
[ :cdata, :characters, :end_document, :end_element, :start_element, ]
Instance Attribute Summary collapse
-
#block ⇒ Object
readonly
Returns the value of attribute block.
-
#current ⇒ Object
Returns the value of attribute current.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(options, &block) ⇒ Parser
constructor
A new instance of Parser.
Constructor Details
#initialize(options, &block) ⇒ Parser
Returns a new instance of Parser.
15 16 17 18 19 |
# File 'lib/xrc/parser.rb', line 15 def initialize(, &block) super([:socket]) @block = block bind end |
Instance Attribute Details
#block ⇒ Object (readonly)
Returns the value of attribute block.
13 14 15 |
# File 'lib/xrc/parser.rb', line 13 def block @block end |
#current ⇒ Object
Returns the value of attribute current.
11 12 13 |
# File 'lib/xrc/parser.rb', line 11 def current @current end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
13 14 15 |
# File 'lib/xrc/parser.rb', line 13 def @options end |