json-ld 0.3.0 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.3.0
1
+ 0.3.1
@@ -89,7 +89,7 @@ module JSON
89
89
  # A list containing another list was detected.
90
90
  LIST_OF_LISTS_DETECTED = 3
91
91
 
92
- attr :code
92
+ attr_reader :code
93
93
 
94
94
  class Lossy < ProcessingError
95
95
  def initialize(*args)
@@ -121,7 +121,7 @@ module JSON
121
121
  # There was a problem encountered loading a remote context.
122
122
  LOAD_ERROR = 2
123
123
 
124
- attr :code
124
+ attr_reader :code
125
125
 
126
126
  class Syntax < InvalidContext
127
127
  def initialize(*args)
@@ -147,7 +147,7 @@ module JSON
147
147
  # More than one embed of a given subject IRI is not allowed, and if requested, must result in this exception.
148
148
  MULTIPLE_EMBEDS = 2
149
149
 
150
- attr :code
150
+ attr_reader :code
151
151
 
152
152
  class Syntax < InvalidFrame
153
153
  def initialize(*args)
@@ -15,23 +15,23 @@ module JSON::LD
15
15
 
16
16
  # The base IRI of the context, if loaded remotely.
17
17
  #
18
- # @attr [RDF::URI]
19
- attr :context_base, true
18
+ # @attr_accessor [RDF::URI]
19
+ attr_accessor :context_base
20
20
 
21
21
  # A list of current, in-scope mappings from term to IRI.
22
22
  #
23
- # @attr [Hash{String => String}]
24
- attr :mappings, true
23
+ # @attr_accessor [Hash{String => String}]
24
+ attr_accessor :mappings
25
25
 
26
26
  # Reverse mappings from IRI to a term or CURIE
27
27
  #
28
- # @attr [Hash{RDF::URI => String}]
29
- attr :iri_to_curie, true
28
+ # @attr_accessor [Hash{RDF::URI => String}]
29
+ attr_accessor :iri_to_curie
30
30
 
31
31
  # Reverse mappings from IRI to term only for terms, not CURIEs
32
32
  #
33
- # @attr [Hash{RDF::URI => String}]
34
- attr :iri_to_term, true
33
+ # @attr_accessor [Hash{RDF::URI => String}]
34
+ attr_accessor :iri_to_term
35
35
 
36
36
  # Type coersion
37
37
  #
@@ -41,8 +41,8 @@ module JSON::LD
41
41
  # the value `@id` asserts that all vocabulary terms listed should undergo coercion to an IRI,
42
42
  # including CURIE processing for compact IRI Expressions like `foaf:homepage`.
43
43
  #
44
- # @attr [Hash{String => String}]
45
- attr :coercions, true
44
+ # @attr_accessor [Hash{String => String}]
45
+ attr_accessor :coercions
46
46
 
47
47
  # List coercion
48
48
  #
@@ -50,8 +50,8 @@ module JSON::LD
50
50
  # A value of @list indicates that arrays of values are to be treated as an ordered list.
51
51
  # A value of @set indicates that arrays are to be treated as unordered and that
52
52
  # singular values are always coerced to an array form on expansion and compaction.
53
- # @attr [Hash{String => String}]
54
- attr :containers, true
53
+ # @attr_accessor [Hash{String => String}]
54
+ attr_accessor :containers
55
55
 
56
56
  # Language coercion
57
57
  #
@@ -60,30 +60,31 @@ module JSON::LD
60
60
  # the value is the language to coerce to. If no property-specific language is given,
61
61
  # any default language from the context is used.
62
62
  #
63
- # @attr [Hash{String => String}]
64
- attr :languages, true
63
+ # @attr_accessor [Hash{String => String}]
64
+ attr_accessor :languages
65
65
 
66
66
  # Default language
67
67
  #
68
68
  #
69
69
  # This adds a language to plain strings that aren't otherwise coerced
70
- # @attr [String]
71
- attr :default_language, true
70
+ # @attr_accessor [String]
71
+ attr_accessor :default_language
72
72
 
73
73
  # Default vocabulary
74
74
  #
75
75
  #
76
76
  # Sets the default vocabulary used for expanding terms which
77
77
  # aren't otherwise absolute IRIs
78
- # @attr [String]
79
- attr :vocab, true
78
+ # @attr_accessor [String]
79
+ attr_accessor :vocab
80
80
 
81
81
  # Global options used in generating IRIs
82
- # @attr [Hash] options
83
- attr :options, true
82
+ # @attr_accessor [Hash] options
83
+ attr_accessor :options
84
84
 
85
85
  # A context provided to us that we can use without re-serializing
86
- attr :provided_context, true
86
+ # @attr_accessor [EvaluationContext]
87
+ attr_accessor :provided_context
87
88
 
88
89
  ##
89
90
  # Create new evaluation context
@@ -54,11 +54,11 @@ module JSON::LD
54
54
  include Utils
55
55
  format Format
56
56
 
57
- # @attr [RDF::Graph] Graph of statements serialized
58
- attr :graph
57
+ # @attr_reader [RDF::Graph] Graph of statements serialized
58
+ attr_reader :graph
59
59
 
60
- # @attr [EvaluationContext] context used to load and administer contexts
61
- attr :context
60
+ # @attr_reader [EvaluationContext] context used to load and administer contexts
61
+ attr_reader :context
62
62
 
63
63
  ##
64
64
  # Override normal symbol generation
@@ -10,7 +10,7 @@ describe JSON::LD do
10
10
  m.entries.each do |t|
11
11
  specify "#{t.property('input')}: #{t.name}" do
12
12
  begin
13
- pending("resolution of term rank in compact-0018") if t.property('input') == 'compact-0018-in.jsonld'
13
+ #pending("resolution of term rank in compact-0018") if t.property('input') == 'compact-0018-in.jsonld'
14
14
  t.debug = ["test: #{t.inspect}", "source: #{t.input.read}"]
15
15
  t.debug << "context: #{t.context.read}" if t.property('context')
16
16
  result = JSON::LD::API.compact(t.input, t.context, nil,
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: json-ld
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-10-20 00:00:00.000000000 Z
12
+ date: 2012-11-06 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rdf