rdf-rdfa 3.0.0 → 3.1.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -3,7 +3,7 @@ module RDF::RDFa
3
3
  ##
4
4
  # Nokogiri implementation of an XML parser.
5
5
  #
6
- # @see http://nokogiri.org/
6
+ # @see https://nokogiri.org/
7
7
  module Nokogiri
8
8
  ##
9
9
  # Returns the name of the underlying XML library.
@@ -34,13 +34,11 @@ module RDF::RDFa
34
34
  #
35
35
  # @return [String]
36
36
  def language
37
- language = case
38
- when @node.document.is_a?(::Nokogiri::HTML::Document) && @node.attributes["xml:lang"]
39
- @node.attributes["xml:lang"].to_s
40
- when @node.document.is_a?(::Nokogiri::HTML::Document) && @node.attributes["lang"]
41
- @node.attributes["lang"].to_s
37
+ case
42
38
  when @node.attribute_with_ns("lang", RDF::XML.to_s)
43
39
  @node.attribute_with_ns("lang", RDF::XML.to_s)
40
+ when @node.attribute("xml:lang")
41
+ @node.attribute("xml:lang").to_s
44
42
  when @node.attribute("lang")
45
43
  @node.attribute("lang").to_s
46
44
  end
@@ -51,7 +49,7 @@ module RDF::RDFa
51
49
  #
52
50
  # @return [String]
53
51
  def base
54
- @node.attribute_with_ns("base", RDF::XML.to_s)
52
+ @node.attribute_with_ns("base", RDF::XML.to_s) || @node.attribute('xml:base')
55
53
  end
56
54
 
57
55
  def display_path
@@ -160,7 +158,7 @@ module RDF::RDFa
160
158
  #
161
159
  # @param [Hash{Symbol => Object}] options
162
160
  # @return [void]
163
- def initialize_xml(input, options = {})
161
+ def initialize_xml(input, **options)
164
162
  require 'nokogiri' unless defined?(::Nokogiri)
165
163
  @doc = case input
166
164
  when ::Nokogiri::HTML::Document, ::Nokogiri::XML::Document
@@ -191,7 +189,7 @@ module RDF::RDFa
191
189
  end
192
190
 
193
191
  # Determine the host language and/or version from options and the input document
194
- def detect_host_language_version(input, options)
192
+ def detect_host_language_version(input, **options)
195
193
  @host_language = options[:host_language] ? options[:host_language].to_sym : nil
196
194
  @version = options[:version] ? options[:version].to_sym : nil
197
195
  return if @host_language && @version
@@ -202,8 +200,6 @@ module RDF::RDFa
202
200
  doc_type_string = input.children.detect {|c| c.is_a?(::Nokogiri::XML::DTD)}
203
201
  version_attr = input.root && input.root.attribute("version").to_s
204
202
  root_element = input.root.name.downcase
205
- root_namespace = input.root.namespace.to_s
206
- root_attrs = input.root.attributes
207
203
  content_type = case
208
204
  when root_element == "html" && input.is_a?(::Nokogiri::HTML::Document)
209
205
  "text/html"
@@ -226,7 +222,7 @@ module RDF::RDFa
226
222
  doc_type_string = head.match(%r(<!DOCTYPE[^>]*>)m).to_s
227
223
  root = head.match(%r(<[^!\?>]*>)m).to_s
228
224
  root_element = root.match(%r(^<(\S+)[ >])) ? $1 : ""
229
- version_attr = root.match(/version\s+=\s+(\S+)[\s">]/m) ? $1 : ""
225
+ version_attr = root.match(/version\s*=\s*"([^"]+)"/m) ? $1 : ""
230
226
  head_element = head.match(%r(<head.*<\/head>)mi)
231
227
  head_doc = ::Nokogiri::HTML.parse(head_element.to_s)
232
228
 
@@ -290,7 +286,9 @@ module RDF::RDFa
290
286
  # FIXME: Nokogiri version 1.5 thinks many HTML5 elements are invalid, so just ignore all Tag errors.
291
287
  # Nokogumbo might make this simpler
292
288
  if @host_language == :html5
293
- @doc.errors.reject {|e| e.to_s =~ /The doctype must be the first token in the document/}
289
+ @doc.errors.reject do |e|
290
+ e.to_s =~ %r{(The doctype must be the first token in the document)|(Expected a doctype token)|(Unexpected '\?' where start tag name is expected)}
291
+ end
294
292
  else
295
293
  @doc.errors.reject {|e| e.to_s =~ /(?:Tag \w+ invalid)|(?:Missing attribute name)/}
296
294
  end
@@ -306,10 +304,10 @@ module RDF::RDFa
306
304
  case @host_language
307
305
  when :xhtml1, :xhtml5, :html4, :html5
308
306
  base_el = @doc.at_css("html>head>base")
309
- base = base_el.attribute("href").to_s.split("#").first if base_el
307
+ base = base.join(base_el.attribute("href").to_s.split("#").first) if base_el
310
308
  else
311
- xml_base = root.attribute_with_ns("base", RDF::XML.to_s) if root
312
- base = xml_base if xml_base
309
+ xml_base = root.attribute_with_ns("base", RDF::XML.to_s) || root.attribute('xml:base') if root
310
+ base = base.join(xml_base) if xml_base
313
311
  end
314
312
 
315
313
  base
@@ -5,7 +5,7 @@ module RDF::RDFa
5
5
  ##
6
6
  # REXML implementation of an XML parser.
7
7
  #
8
- # @see http://www.germane-software.com/software/rexml/
8
+ # @see https://www.germane-software.com/software/rexml/
9
9
  module REXML
10
10
  ##
11
11
  # Returns the name of the underlying XML library.
@@ -39,6 +39,8 @@ module RDF::RDFa
39
39
  language = case
40
40
  when @node.attribute("lang", RDF::XML.to_s)
41
41
  @node.attribute("lang", RDF::XML.to_s)
42
+ when @node.attribute("xml:lang")
43
+ @node.attribute("xml:lang").to_s
42
44
  when @node.attribute("lang")
43
45
  @node.attribute("lang").to_s
44
46
  end
@@ -49,7 +51,7 @@ module RDF::RDFa
49
51
  #
50
52
  # @return [String]
51
53
  def base
52
- @node.attribute("base", RDF::XML.to_s)
54
+ @node.attribute("base", RDF::XML.to_s) || @node.attribute('xml:base')
53
55
  end
54
56
 
55
57
  def display_path
@@ -102,7 +104,7 @@ module RDF::RDFa
102
104
  ##
103
105
  # Inner text of an element
104
106
  #
105
- # @see http://apidock.com/ruby/REXML/Element/get_text#743-Get-all-inner-texts
107
+ # @see https://apidock.com/ruby/REXML/Element/get_text#743-Get-all-inner-texts
106
108
  # @return [String]
107
109
  def inner_text
108
110
  coder = HTMLEntities.new
@@ -114,7 +116,7 @@ module RDF::RDFa
114
116
  ##
115
117
  # Inner text of an element
116
118
  #
117
- # @see http://apidock.com/ruby/REXML/Element/get_text#743-Get-all-inner-texts
119
+ # @see https://apidock.com/ruby/REXML/Element/get_text#743-Get-all-inner-texts
118
120
  # @return [String]
119
121
  def inner_html
120
122
  @node.children.map(&:to_s).join
@@ -206,7 +208,7 @@ module RDF::RDFa
206
208
  #
207
209
  # @param [Hash{Symbol => Object}] options
208
210
  # @return [void]
209
- def initialize_xml(input, options = {})
211
+ def initialize_xml(input, **options)
210
212
  require 'rexml/document' unless defined?(::REXML)
211
213
  @doc = case input
212
214
  when ::REXML::Document
@@ -227,7 +229,7 @@ module RDF::RDFa
227
229
  end
228
230
 
229
231
  # Determine the host language and/or version from options and the input document
230
- def detect_host_language_version(input, options)
232
+ def detect_host_language_version(input, **options)
231
233
  @host_language = options[:host_language] ? options[:host_language].to_sym : nil
232
234
  @version = options[:version] ? options[:version].to_sym : nil
233
235
  return if @host_language && @version
@@ -238,8 +240,6 @@ module RDF::RDFa
238
240
  doc_type_string = input.doctype.to_s
239
241
  version_attr = input.root && input.root.attribute("version").to_s
240
242
  root_element = input.root.name.downcase
241
- root_namespace = input.root.namespace.to_s
242
- root_attrs = input.root.attributes
243
243
  content_type = "application/xhtml+html" # FIXME: what about other possible XML types?
244
244
  else
245
245
  content_type = input.content_type if input.respond_to?(:content_type)
@@ -257,7 +257,7 @@ module RDF::RDFa
257
257
  doc_type_string = head.match(%r(<!DOCTYPE[^>]*>)m).to_s
258
258
  root = head.match(%r(<[^!\?>]*>)m).to_s
259
259
  root_element = root.match(%r(^<(\S+)[ >])) ? $1 : ""
260
- version_attr = root.match(/version\s+=\s+(\S+)[\s">]/m) ? $1 : ""
260
+ version_attr = root.match(/version\s*=\s*"([^"]+)"/m) ? $1 : ""
261
261
  head_element = head.match(%r(<head.*<\/head>)mi)
262
262
  head_doc = ::REXML::Document.new(head_element.to_s)
263
263
 
@@ -329,10 +329,10 @@ module RDF::RDFa
329
329
  case @host_language
330
330
  when :xhtml1, :xhtml5, :html4, :html5
331
331
  base_el = ::REXML::XPath.first(@doc, "/html/head/base") rescue nil
332
- base = base_el.attribute("href").to_s.split("#").first if base_el
332
+ base = base.join(base_el.attribute("href").to_s.split("#").first) if base_el
333
333
  else
334
- xml_base = root.attribute("base", RDF::XML.to_s) if root
335
- base = xml_base if xml_base
334
+ xml_base = root.attribute("base", RDF::XML.to_s) || root.attribute('xml:base') if root
335
+ base = base.join(xml_base) if xml_base
336
336
  end
337
337
 
338
338
  base || @base_uri
@@ -1,137 +1,161 @@
1
1
  # -*- encoding: utf-8 -*-
2
+ # frozen_string_literal: true
3
+ # This file generated automatically using rdf vocabulary format from http://www.w3.org/ns/rdfa#
4
+ require 'rdf'
2
5
  module RDF
3
- class RDFA < Vocabulary("http://www.w3.org/ns/rdfa#")
6
+ # @!parse
7
+ # # Vocabulary for <http://www.w3.org/ns/rdfa#>
8
+ # #
9
+ # # RDFa Vocabulary for Term and Prefix Assignment, and for Processor Graph Reporting
10
+ # #
11
+ # # This document describes the RDFa Vocabulary for Term and Prefix Assignment. The Vocabulary is used to modify RDFa 1.1 processing behavior.
12
+ # # @version $Date: 2013-03-11 07:54:23 $
13
+ # class RDFA < RDF::Vocabulary
14
+ # # @return [RDF::Vocabulary::Term]
15
+ # attr_reader :PGClass
16
+ #
17
+ # # @return [RDF::Vocabulary::Term]
18
+ # attr_reader :Pattern
19
+ #
20
+ # # @return [RDF::Vocabulary::Term]
21
+ # attr_reader :PrefixOrTermMapping
22
+ #
23
+ # # @return [RDF::Vocabulary::Term]
24
+ # attr_reader :context
25
+ #
26
+ # # @return [RDF::Vocabulary::Term]
27
+ # attr_reader :copy
28
+ #
29
+ # # @return [RDF::Vocabulary::Term]
30
+ # attr_reader :prefix
31
+ #
32
+ # # @return [RDF::Vocabulary::Term]
33
+ # attr_reader :term
34
+ #
35
+ # # @return [RDF::Vocabulary::Term]
36
+ # attr_reader :uri
37
+ #
38
+ # # @return [RDF::Vocabulary::Term]
39
+ # attr_reader :usesVocabulary
40
+ #
41
+ # # @return [RDF::Vocabulary::Term]
42
+ # attr_reader :vocabulary
43
+ #
44
+ # # @return [RDF::Vocabulary::Term]
45
+ # attr_reader :DocumentError
46
+ #
47
+ # # @return [RDF::Vocabulary::Term]
48
+ # attr_reader :Error
49
+ #
50
+ # # @return [RDF::Vocabulary::Term]
51
+ # attr_reader :Info
52
+ #
53
+ # # @return [RDF::Vocabulary::Term]
54
+ # attr_reader :PrefixMapping
55
+ #
56
+ # # @return [RDF::Vocabulary::Term]
57
+ # attr_reader :PrefixRedefinition
58
+ #
59
+ # # @return [RDF::Vocabulary::Term]
60
+ # attr_reader :TermMapping
61
+ #
62
+ # # @return [RDF::Vocabulary::Term]
63
+ # attr_reader :UnresolvedCURIE
64
+ #
65
+ # # @return [RDF::Vocabulary::Term]
66
+ # attr_reader :UnresolvedTerm
67
+ #
68
+ # # @return [RDF::Vocabulary::Term]
69
+ # attr_reader :VocabReferenceError
70
+ #
71
+ # # @return [RDF::Vocabulary::Term]
72
+ # attr_reader :Warning
73
+ #
74
+ # end
75
+ RDFA = Class.new(RDF::Vocabulary("http://www.w3.org/ns/rdfa#")) do
76
+
77
+ # Ontology definition
78
+ ontology :"http://www.w3.org/ns/rdfa#",
79
+ "dc:creator": "http://www.ivan-herman.net/foaf#me".freeze,
80
+ "dc:date": "2013-01-18".freeze,
81
+ "dc:description": "This document describes the RDFa Vocabulary for Term and Prefix Assignment. The Vocabulary is used to modify RDFa 1.1 processing behavior.".freeze,
82
+ "dc:publisher": "http://www.w3.org/data#W3C".freeze,
83
+ "dc:title": "RDFa Vocabulary for Term and Prefix Assignment, and for Processor Graph Reporting".freeze,
84
+ isDefinedBy: "http://www.w3.org/TR/rdfa-core/#s_initialcontexts".freeze,
85
+ "owl:versionInfo": "$Date: 2013-03-11 07:54:23 $".freeze,
86
+ type: "owl:Ontology".freeze
87
+
4
88
  # Class definitions
5
- __property__ :DocumentError,
6
- comment: %(error condition; to be used when the document fails to be fully processed as a result of non-conformant host language markup).freeze,
7
- "dc:description" => %(error condition; to be used when the document fails to be fully processed as a result of non-conformant host language markup).freeze,
8
- label: "DocumentError".freeze,
9
- subClassOf: "rdfa:Error".freeze,
10
- type: "rdfs:Class".freeze
11
- __property__ :Error,
12
- comment: %(is the class for all error conditions).freeze,
13
- "dc:description" => %(is the class for all error conditions).freeze,
14
- label: "Error".freeze,
15
- subClassOf: "rdfa:PGClass".freeze.freeze,
16
- type: "rdfs:Class".freeze
17
- __property__ :Info,
18
- comment: %(is the class for all informations).freeze,
19
- "dc:description" => %(is the class for all informations).freeze,
20
- label: "Info".freeze,
21
- subClassOf: "rdfa:PGClass".freeze.freeze,
22
- type: "rdfs:Class".freeze
23
- __property__ :PGClass,
24
- comment: %(is the top level class of the hierarchy).freeze,
25
- "dc:description" => %(is the top level class of the hierarchy).freeze,
26
- label: "PGClass".freeze,
27
- type: ["rdfs:Class".freeze, "owl:Class".freeze]
28
- __property__ :Pattern,
29
- comment: %(Class to identify an \(RDF\) resource whose properties are to be copied to another resource).freeze,
30
- "dc:description" => %(Class to identify an \(RDF\) resource whose properties are to be copied to another resource).freeze,
31
- label: "Pattern".freeze,
32
- type: ["rdfs:Class".freeze, "owl:Class".freeze]
33
- __property__ :PrefixMapping,
34
- comment: %(is the class for prefix mappings).freeze,
35
- "dc:description" => %(is the class for prefix mappings).freeze,
36
- label: "PrefixMapping".freeze,
37
- subClassOf: "rdfa:PrefixOrTermMapping".freeze.freeze,
38
- type: "rdfs:Class".freeze
39
- __property__ :PrefixOrTermMapping,
40
- comment: %(is the top level class for prefix or term mappings).freeze,
41
- "dc:description" => %(is the top level class for prefix or term mappings).freeze,
42
- label: "PrefixOrTermMapping".freeze,
43
- type: ["rdfs:Class".freeze, "owl:Class".freeze]
44
- __property__ :PrefixRedefinition,
45
- comment: %(warning; to be used when a prefix, either from the initial context or inherited from an ancestor node, is redefined in an element).freeze,
46
- "dc:description" => %(warning; to be used when a prefix, either from the initial context or inherited from an ancestor node, is redefined in an element).freeze,
47
- label: "PrefixRedefinition".freeze,
48
- subClassOf: "rdfa:Warning".freeze.freeze,
49
- type: "rdfs:Class".freeze
50
- __property__ :TermMapping,
51
- comment: %(is the class for term mappings).freeze,
52
- "dc:description" => %(is the class for term mappings).freeze,
53
- label: "TermMapping".freeze,
54
- subClassOf: "rdfa:PrefixOrTermMapping".freeze.freeze,
55
- type: "rdfs:Class".freeze
56
- __property__ :UnresolvedCURIE,
57
- comment: %(warning; to be used when a CURIE prefix fails to be resolved).freeze,
58
- "dc:description" => %(warning; to be used when a CURIE prefix fails to be resolved).freeze,
59
- label: "UnresolvedCURIE".freeze,
60
- subClassOf: "rdfa:Warning".freeze.freeze,
61
- type: "rdfs:Class".freeze
62
- __property__ :UnresolvedTerm,
63
- comment: %(warning; to be used when a Term fails to be resolved).freeze,
64
- "dc:description" => %(warning; to be used when a Term fails to be resolved).freeze,
65
- label: "UnresolvedTerm".freeze,
66
- subClassOf: "rdfa:Warning".freeze.freeze,
67
- type: "rdfs:Class".freeze
68
- __property__ :VocabReferenceError,
69
- comment: %(warning; to be used when the value of a @vocab attribute cannot be dereferenced, hence the vocabulary expansion cannot be completed).freeze,
70
- "dc:description" => %(warning; to be used when the value of a @vocab attribute cannot be dereferenced, hence the vocabulary expansion cannot be completed).freeze,
71
- label: "VocabReferenceError".freeze,
72
- subClassOf: "rdfa:Warning".freeze.freeze,
73
- type: "rdfs:Class".freeze
74
- __property__ :Warning,
75
- comment: %(is the class for all warnings).freeze,
76
- "dc:description" => %(is the class for all warnings).freeze,
77
- label: "Warning".freeze,
78
- subClassOf: "rdfa:PGClass".freeze.freeze,
79
- type: "rdfs:Class".freeze
89
+ term :PGClass,
90
+ "dc:description": "is the top level class of the hierarchy".freeze,
91
+ type: ["owl:Class".freeze, "rdfs:Class".freeze]
92
+ term :Pattern,
93
+ "dc:description": "Class to identify an (RDF) resource whose properties are to be copied to another resource".freeze,
94
+ type: ["owl:Class".freeze, "rdfs:Class".freeze]
95
+ term :PrefixOrTermMapping,
96
+ "dc:description": "is the top level class for prefix or term mappings".freeze,
97
+ type: ["owl:Class".freeze, "rdfs:Class".freeze]
80
98
 
81
99
  # Property definitions
82
- __property__ :context,
83
- comment: %(provides extra context for the error, eg, http response, an XPointer/XPath information, or simply the URI that created the error).freeze,
84
- "dc:description" => %(provides extra context for the error, eg, http response, an XPointer/XPath information, or simply the URI that created the error).freeze,
100
+ property :context,
101
+ "dc:description": "provides extra context for the error, eg, http response, an XPointer/XPath information, or simply the URI that created the error".freeze,
85
102
  domain: "rdfa:PGClass".freeze,
86
- label: "context".freeze,
87
- type: ["rdf:Property".freeze, "owl:ObjectProperty".freeze]
88
- __property__ :copy,
89
- comment: %(identifies the resource \(i.e., pattern\) whose properties and values should be copied to replace the current triple \(retaining the subject of the triple\).).freeze,
90
- "dc:description" => %(identifies the resource \(i.e., pattern\) whose properties and values should be copied to replace the current triple \(retaining the subject of the triple\).).freeze,
91
- label: "copy".freeze,
92
- type: ["rdf:Property".freeze, "owl:ObjectProperty".freeze]
93
- __property__ :prefix,
94
- comment: %(defines a prefix mapping for a URI; the value is supposed to be a NMTOKEN).freeze,
95
- "dc:description" => %(defines a prefix mapping for a URI; the value is supposed to be a NMTOKEN).freeze,
103
+ type: ["owl:ObjectProperty".freeze, "rdf:Property".freeze]
104
+ property :copy,
105
+ "dc:description": "identifies the resource (i.e., pattern) whose properties and values should be copied to replace the current triple (retaining the subject of the triple).".freeze,
106
+ type: ["owl:ObjectProperty".freeze, "rdf:Property".freeze]
107
+ property :prefix,
108
+ "dc:description": "defines a prefix mapping for a URI; the value is supposed to be a NMTOKEN".freeze,
96
109
  domain: "rdfa:PrefixMapping".freeze,
97
- label: "prefix".freeze,
98
- type: ["rdf:Property".freeze, "owl:DatatypeProperty".freeze]
99
- __property__ :term,
100
- comment: %(defines a term mapping for a URI; the value is supposed to be a NMTOKEN).freeze,
101
- "dc:description" => %(defines a term mapping for a URI; the value is supposed to be a NMTOKEN).freeze,
110
+ type: ["owl:DatatypeProperty".freeze, "rdf:Property".freeze]
111
+ property :term,
112
+ "dc:description": "defines a term mapping for a URI; the value is supposed to be a NMTOKEN".freeze,
102
113
  domain: "rdfa:TermMapping".freeze,
103
- label: "term".freeze,
104
- type: ["rdf:Property".freeze, "owl:DatatypeProperty".freeze]
105
- __property__ :uri,
106
- comment: %(defines the URI for either a prefix or a term mapping; the value is supposed to be an absolute URI).freeze,
107
- "dc:description" => %(defines the URI for either a prefix or a term mapping; the value is supposed to be an absolute URI).freeze,
114
+ type: ["owl:DatatypeProperty".freeze, "rdf:Property".freeze]
115
+ property :uri,
116
+ "dc:description": "defines the URI for either a prefix or a term mapping; the value is supposed to be an absolute URI".freeze,
108
117
  domain: "rdfa:PrefixOrTermMapping".freeze,
109
- label: "uri".freeze,
110
- type: ["rdf:Property".freeze, "owl:DatatypeProperty".freeze]
111
- __property__ :usesVocabulary,
112
- comment: %(provides a relationship between the host document and a vocabulary defined using the @vocab facility of RDFa1.1).freeze,
113
- "dc:description" => %(provides a relationship between the host document and a vocabulary defined using the @vocab facility of RDFa1.1).freeze,
114
- label: "usesVocabulary".freeze,
115
- type: ["rdf:Property".freeze, "owl:ObjectProperty".freeze]
116
- __property__ :vocabulary,
117
- comment: %(defines an absolute URI to be used as a default vocabulary; the value is can be any string; for documentation purposes it is advised to use the string 'true' or 'True'.).freeze,
118
- "dc:description" => %(defines an absolute URI to be used as a default vocabulary; the value is can be any string; for documentation purposes it is advised to use the string 'true' or 'True'.).freeze,
119
- label: "vocabulary".freeze,
120
- type: ["rdf:Property".freeze, "owl:DatatypeProperty".freeze]
118
+ type: ["owl:DatatypeProperty".freeze, "rdf:Property".freeze]
119
+ property :usesVocabulary,
120
+ "dc:description": "provides a relationship between the host document and a vocabulary\n\tdefined using the @vocab facility of RDFa1.1".freeze,
121
+ type: ["owl:ObjectProperty".freeze, "rdf:Property".freeze]
122
+ property :vocabulary,
123
+ "dc:description": "defines an absolute URI to be used as a default vocabulary; the value is can be any string; for documentation purposes it is advised to use the string 'true' or 'True'.".freeze,
124
+ type: ["owl:DatatypeProperty".freeze, "rdf:Property".freeze]
121
125
 
122
126
  # Extra definitions
123
- __property__ :"",
124
- "dc:creator" => %(http://www.ivan-herman.net/foaf#me).freeze,
125
- "dc:date" => %(2013-01-18).freeze,
126
- "dc:description" => %(This document describes the RDFa Vocabulary for Term and Prefix Assignment. The Vocabulary is used to modify RDFa 1.1 processing behavior.).freeze,
127
- "dc:publisher" => %(http://www.w3.org/data#W3C).freeze,
128
- "dc:title" => %(RDFa Vocabulary for Term and Prefix Assignment, and for Processor Graph Reporting).freeze,
129
- label: "".freeze,
130
- "owl:versionInfo" => %($Date: 2013-03-11 07:54:23 $).freeze,
131
- "rdfs:isDefinedBy" => %(http://www.w3.org/TR/rdfa-core/#s_initialcontexts).freeze,
132
- type: "owl:Ontology".freeze
127
+ term :DocumentError,
128
+ "dc:description": "error condition; to be used when the document fails to be fully processed as a result of non-conformant host language markup".freeze,
129
+ subClassOf: "rdfa:Error".freeze
130
+ term :Error,
131
+ "dc:description": "is the class for all error conditions".freeze,
132
+ subClassOf: "rdfa:PGClass".freeze
133
+ term :Info,
134
+ "dc:description": "is the class for all informations".freeze,
135
+ subClassOf: "rdfa:PGClass".freeze
136
+ term :PrefixMapping,
137
+ "dc:description": "is the class for prefix mappings".freeze,
138
+ subClassOf: "rdfa:PrefixOrTermMapping".freeze
139
+ term :PrefixRedefinition,
140
+ "dc:description": "warning; to be used when a prefix, either from the initial context or inherited from an ancestor node, is redefined in an element".freeze,
141
+ subClassOf: "rdfa:Warning".freeze
142
+ term :TermMapping,
143
+ "dc:description": "is the class for term mappings".freeze,
144
+ subClassOf: "rdfa:PrefixOrTermMapping".freeze
145
+ term :UnresolvedCURIE,
146
+ "dc:description": "warning; to be used when a CURIE prefix fails to be resolved".freeze,
147
+ subClassOf: "rdfa:Warning".freeze
148
+ term :UnresolvedTerm,
149
+ "dc:description": "warning; to be used when a Term fails to be resolved".freeze,
150
+ subClassOf: "rdfa:Warning".freeze
151
+ term :VocabReferenceError,
152
+ "dc:description": "warning; to be used when the value of a @vocab attribute cannot be dereferenced, hence the vocabulary expansion cannot be completed".freeze,
153
+ subClassOf: "rdfa:Warning".freeze
154
+ term :Warning,
155
+ "dc:description": "is the class for all warnings".freeze,
156
+ subClassOf: "rdfa:PGClass".freeze
133
157
  end
134
158
 
135
- class XML < Vocabulary("http://www.w3.org/XML/1998/namespace"); end
136
- class XSI < Vocabulary("http://www.w3.org/2001/XMLSchema-instance"); end
159
+ XML = Class.new(Vocabulary("http://www.w3.org/XML/1998/namespace"))
160
+ XSI = Class.new(Vocabulary("http://www.w3.org/2001/XMLSchema-instance"))
137
161
  end