data-validator 1.1.1 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/data.rb +40 -0
- data/lib/data/validator.rb +1 -0
- data/lib/data/validator/version.rb +1 -1
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 30f52452dbb7b555d9d1f9730387db0bfb16295c
|
4
|
+
data.tar.gz: 3ce763214022495c6f36e43185cef9a442280c23
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8d2989cd6e3e98aafe5ee7ae8695fa69ad966cc2041f6bba6050f621162ef7c0e3e84726d18288b0ef539ef6d55e56fd8958c04a7eac3784d63b6e1bb7d968f7
|
7
|
+
data.tar.gz: 495f5fa66411e5e4f32fc2084732efd0ef192223e5e0327db935beded455a967357b38fbbfe5aff446636aa3c6a98500555be5ec0e9f7f7ce88cb93a478d5e09
|
data/lib/data.rb
ADDED
@@ -0,0 +1,40 @@
|
|
1
|
+
#! /your/favourite/path/to/ruby
|
2
|
+
# -*- mode: ruby; coding: utf-8; indent-tabs-mode: nil; ruby-indent-level 2 -*-
|
3
|
+
|
4
|
+
# Copyright (c) 2018 Urabe, Shyouhei
|
5
|
+
#
|
6
|
+
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
+
# of this software and associated documentation files (the "Software"), to deal
|
8
|
+
# in the Software without restriction, including without limitation the rights
|
9
|
+
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
+
# copies of the Software, and to permit persons to whom the Software is
|
11
|
+
# furnished to do so, subject to the following conditions:
|
12
|
+
#
|
13
|
+
# The above copyright notice and this permission notice shall be
|
14
|
+
# included in all copies or substantial portions of the Software.
|
15
|
+
#
|
16
|
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
+
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
+
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
+
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
+
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
+
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
22
|
+
# SOFTWARE.
|
23
|
+
|
24
|
+
# Toplevel namespace `::Data` got deprecated, and will eventually be disappear.
|
25
|
+
# However we are using it because p5-Data-Validator is in this namespace. This
|
26
|
+
# has nothing to do with the deprecation of Ruby's `::Data`.
|
27
|
+
if !defined? ::Data then
|
28
|
+
Data = Class.new # create one here
|
29
|
+
elsif defined? ::Warning then
|
30
|
+
# We have to shut up the deprecation warning.
|
31
|
+
class << Warning
|
32
|
+
prepend Module.new {
|
33
|
+
def warn str
|
34
|
+
super unless /::Data is deprecated/ =~ str
|
35
|
+
end
|
36
|
+
}
|
37
|
+
end
|
38
|
+
else
|
39
|
+
# This ruby is very old. We don't have to do anything.
|
40
|
+
end
|
data/lib/data/validator.rb
CHANGED
@@ -20,6 +20,7 @@
|
|
20
20
|
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
21
|
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
22
22
|
# SOFTWARE.
|
23
|
+
require_relative '../data'
|
23
24
|
Data::Validator = Class.new # @!parse class Data::Validator; end
|
24
25
|
require_relative "validator/version"
|
25
26
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: data-validator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Urabe, Shyouhei
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-11-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -121,6 +121,7 @@ files:
|
|
121
121
|
- README.md
|
122
122
|
- Rakefile
|
123
123
|
- data-validator.gemspec
|
124
|
+
- lib/data.rb
|
124
125
|
- lib/data/validator.rb
|
125
126
|
- lib/data/validator/error.rb
|
126
127
|
- lib/data/validator/recursive.rb
|
@@ -158,7 +159,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
158
159
|
version: '0'
|
159
160
|
requirements: []
|
160
161
|
rubyforge_project:
|
161
|
-
rubygems_version: 2.
|
162
|
+
rubygems_version: 2.4.5.4
|
162
163
|
signing_key:
|
163
164
|
specification_version: 4
|
164
165
|
summary: p5-Data-Validator / p5-Data-Validator-Recursive port
|