lib/rdf/rdfxml/reader.rb
# ID attribute must be an NCName
ID attribute must be an NCName
ID attribute must be an NCName
def id_check(el, id, base)
      add_error(el, "ID addtribute '#{id}' must be a NCName") unless NC_REGEXP.match(id)
      if base
        uri = uri(base, "##{id}")
        add_error(el, "ID addtribute '#{id}' may only be defined once for the same URI") if prefix(id) && RDF::URI(prefix(id)) == uri
        RDF::URI(prefix(id, uri))
      else
        id
      end
    end
def id_check ( el , id , base ) add_error ( el , "ID addtribute '#{id}' must be a NCName" ) unless NC_REGEXP . match ( id ) if base uri = uri ( base , "##{id}" ) add_error ( el , "ID addtribute '#{id}' may only be defined once for the same URI" ) if prefix ( id ) && RDF :: URI ( prefix ( id ) ) == uri RDF :: URI ( prefix ( id , uri ) ) else id end end
ID attribute must be an NCName
ID attribute must be an NCName
# ID may only be specified once for the same URI # Returns URI, in this case
el
<not_specific>
id
<not_specific>
base
<not_specific>