mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
-
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6441 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
f2b75020ba
commit
3289dfc78b
13 changed files with 246 additions and 123 deletions
|
@ -14,6 +14,10 @@ module REXML
|
|||
@tag_stack = []
|
||||
end
|
||||
|
||||
def add_listener( listener )
|
||||
@parser.add_listener( listener )
|
||||
end
|
||||
|
||||
# Listen arguments:
|
||||
#
|
||||
# Symbol, Array, Block
|
||||
|
@ -89,6 +93,7 @@ module REXML
|
|||
if procs or listeners
|
||||
# break out the namespace declarations
|
||||
# The attributes live in event[2]
|
||||
event[2].each {|n, v| event[2][n] = @parser.normalize(v)}
|
||||
nsdecl = event[2].find_all { |n, value| n =~ /^xmlns(:|$)/ }
|
||||
nsdecl.collect! { |n, value| [ n[6..-1], value ] }
|
||||
@namespace_stack.push({})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue