Google

def initialize source super() md = source.match( ATTLISTDECL, true ) raise ParseException.new( "Bad ATTLIST declaration!", source ) if md.nil? @element = md[1] @contents = md[0] @pairs = {} values = md[0].scan( ATTDEF ) values.each do |attdef| unless attdef[3] == "#IMPLIED" attdef.compact! val = attdef[3] val = attdef[4] if val == "#FIXED " @pairs[attdef[0]] = val end end end