json_world 0.2.3 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b7b56b307c4758732de7859e29486dda4220e9aa
4
- data.tar.gz: 4e517e903417601c1a0bd00b85bea8ac7b57115d
3
+ metadata.gz: 0d566b1f9bc9d32f2979c9e629244dc1c5131252
4
+ data.tar.gz: ac1806e0220c8c42eb30a390408e06f471c44ff7
5
5
  SHA512:
6
- metadata.gz: f28e1be23b4808aba464c37d0571c4522a631e1760bbab777ab6cb55dd8bbd8a48653d19bed85c3e855ab236a312a02b8719d0c3ae70f77a1a40f9195a37f7c7
7
- data.tar.gz: 6490379be8b89de6e77d3a336c52004ed07d86b6962d1a71ee29604a3b5ece590b82ecf9273b40938758f7da89f45c65944bebd3804f405b8c69879d192febf2
6
+ metadata.gz: c66833b2015116854e25b2ce04733fa16664cbe58731c925c64a95c954aee8ccf292b04ed2fe1250ba2d02be9a3429a01af6f8fa54620d6ef054f4c5be83fa48
7
+ data.tar.gz: 2a00605c40d2a2b258c10b9c50b5f8219bdc27789747b515b61e75da71a808539887a292b7887823532680bd5552312cd2c88d59ab2702e493a5f60fa8d14dc8
data/CHANGELOG.md CHANGED
@@ -1,3 +1,6 @@
1
+ ## 0.2.4
2
+ - Support `$schema` property
3
+
1
4
  ## 0.2.3
2
5
  - Add :target_schema option on link definition
3
6
 
@@ -23,6 +23,7 @@ module JsonWorld
23
23
  # @return [Hash]
24
24
  def as_json_schema
25
25
  {
26
+ '$schema': schema,
26
27
  description: description,
27
28
  links: links_as_json_schema,
28
29
  properties: properties_as_json_schema,
@@ -120,6 +121,11 @@ module JsonWorld
120
121
  def title(value = nil)
121
122
  @title ||= value
122
123
  end
124
+
125
+ # @return [String, nil]
126
+ def schema(value = nil)
127
+ @schema ||= value
128
+ end
123
129
  end
124
130
  end
125
131
  end
@@ -1,3 +1,3 @@
1
1
  module JsonWorld
2
- VERSION = "0.2.3"
2
+ VERSION = "0.2.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: json_world
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryo Nakamura
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-02-25 00:00:00.000000000 Z
11
+ date: 2016-08-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -122,9 +122,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
122
122
  version: '0'
123
123
  requirements: []
124
124
  rubyforge_project:
125
- rubygems_version: 2.4.5
125
+ rubygems_version: 2.4.5.1
126
126
  signing_key:
127
127
  specification_version: 4
128
128
  summary: Provides DSL to define JSON Schema representation of your class.
129
129
  test_files: []
130
- has_rdoc: