xmlrpc 0.1.1 → 0.2.0
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/xmlrpc.rb +1 -1
- data/lib/xmlrpc/client.rb +2 -2
- data/lib/xmlrpc/create.rb +3 -3
- data/lib/xmlrpc/datetime.rb +7 -13
- data/xmlrpc.gemspec +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e530f6549df0b95a5cbd2faa74bef693a81eafcd
|
4
|
+
data.tar.gz: 3c65eeaf3821a27fc70552db6a87a63ca7fc214a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cf7f4bfdc77f4d03c2e70c82d8a49dfc7965b17f0ee7d1d81a84f017cb4c3f7f1f48a6391cee19bc0ffff14a108aacb026684240f3c577cfa2ff02746e530445
|
7
|
+
data.tar.gz: 16fc37829decede3b0e807d8c5e2f696de6dbd8bdb19e2190b3847bc26bedf383cf0a4b54b21c31170c07905a10ccf5aec02d774471962d675cbb8faf47fe76f
|
data/lib/xmlrpc.rb
CHANGED
data/lib/xmlrpc/client.rb
CHANGED
@@ -237,7 +237,7 @@ module XMLRPC # :nodoc:
|
|
237
237
|
# Each parameter of +args+ must be of one of the following types,
|
238
238
|
# where Hash, Struct and Array can contain any of these listed _types_:
|
239
239
|
#
|
240
|
-
# *
|
240
|
+
# * Integer
|
241
241
|
# * TrueClass, FalseClass, +true+, +false+
|
242
242
|
# * String, Symbol
|
243
243
|
# * Float
|
@@ -255,7 +255,7 @@ module XMLRPC # :nodoc:
|
|
255
255
|
#
|
256
256
|
# The type of the return-value is one of the types shown above.
|
257
257
|
#
|
258
|
-
#
|
258
|
+
# An Integer is only allowed when it fits in 32-bit. A XML-RPC
|
259
259
|
# +dateTime.iso8601+ type is always returned as a XMLRPC::DateTime object.
|
260
260
|
# Struct is never returned, only a Hash, the same for a Symbol, where as a
|
261
261
|
# String is always returned. XMLRPC::Base64 is returned as a String from
|
data/lib/xmlrpc/create.rb
CHANGED
@@ -176,15 +176,15 @@ module XMLRPC # :nodoc:
|
|
176
176
|
def conv2value(param) # :doc:
|
177
177
|
|
178
178
|
val = case param
|
179
|
-
when
|
180
|
-
# XML-RPC's int is 32bit int
|
179
|
+
when Integer
|
180
|
+
# XML-RPC's int is 32bit int
|
181
181
|
if Config::ENABLE_BIGINT
|
182
182
|
@writer.tag("i4", param.to_s)
|
183
183
|
else
|
184
184
|
if param >= -(2**31) and param <= (2**31-1)
|
185
185
|
@writer.tag("i4", param.to_s)
|
186
186
|
else
|
187
|
-
raise "
|
187
|
+
raise "Integer is too big! Must be signed 32-bit integer!"
|
188
188
|
end
|
189
189
|
end
|
190
190
|
when TrueClass, FalseClass
|
data/lib/xmlrpc/datetime.rb
CHANGED
@@ -24,7 +24,7 @@ class DateTime
|
|
24
24
|
#
|
25
25
|
# Raises ArgumentError if the given +value+ is out of range, or in the case
|
26
26
|
# of XMLRPC::DateTime#year= if +value+ is not of type Integer.
|
27
|
-
def year=
|
27
|
+
def year=(value)
|
28
28
|
raise ArgumentError, "date/time out of range" unless value.is_a? Integer
|
29
29
|
@year = value
|
30
30
|
end
|
@@ -32,7 +32,7 @@ class DateTime
|
|
32
32
|
# Set +value+ as the new date/time component.
|
33
33
|
#
|
34
34
|
# Raises an ArgumentError if the given +value+ isn't between 1 and 12.
|
35
|
-
def month=
|
35
|
+
def month=(value)
|
36
36
|
raise ArgumentError, "date/time out of range" unless (1..12).include? value
|
37
37
|
@month = value
|
38
38
|
end
|
@@ -40,7 +40,7 @@ class DateTime
|
|
40
40
|
# Set +value+ as the new date/time component.
|
41
41
|
#
|
42
42
|
# Raises an ArgumentError if the given +value+ isn't between 1 and 31.
|
43
|
-
def day=
|
43
|
+
def day=(value)
|
44
44
|
raise ArgumentError, "date/time out of range" unless (1..31).include? value
|
45
45
|
@day = value
|
46
46
|
end
|
@@ -48,7 +48,7 @@ class DateTime
|
|
48
48
|
# Set +value+ as the new date/time component.
|
49
49
|
#
|
50
50
|
# Raises an ArgumentError if the given +value+ isn't between 0 and 24.
|
51
|
-
def hour=
|
51
|
+
def hour=(value)
|
52
52
|
raise ArgumentError, "date/time out of range" unless (0..24).include? value
|
53
53
|
@hour = value
|
54
54
|
end
|
@@ -56,7 +56,7 @@ class DateTime
|
|
56
56
|
# Set +value+ as the new date/time component.
|
57
57
|
#
|
58
58
|
# Raises an ArgumentError if the given +value+ isn't between 0 and 59.
|
59
|
-
def min=
|
59
|
+
def min=(value)
|
60
60
|
raise ArgumentError, "date/time out of range" unless (0..59).include? value
|
61
61
|
@min = value
|
62
62
|
end
|
@@ -64,7 +64,7 @@ class DateTime
|
|
64
64
|
# Set +value+ as the new date/time component.
|
65
65
|
#
|
66
66
|
# Raises an ArgumentError if the given +value+ isn't between 0 and 59.
|
67
|
-
def sec=
|
67
|
+
def sec=(value)
|
68
68
|
raise ArgumentError, "date/time out of range" unless (0..59).include? value
|
69
69
|
@sec = value
|
70
70
|
end
|
@@ -87,16 +87,10 @@ class DateTime
|
|
87
87
|
end
|
88
88
|
|
89
89
|
# Return a Time object of the date/time which represents +self+.
|
90
|
-
# If the <code>@year</code> is below 1970, this method returns +nil+,
|
91
|
-
# because Time cannot handle years below 1970.
|
92
90
|
#
|
93
91
|
# The timezone used is GMT.
|
94
92
|
def to_time
|
95
|
-
|
96
|
-
Time.gm(*to_a)
|
97
|
-
else
|
98
|
-
nil
|
99
|
-
end
|
93
|
+
Time.gm(*to_a)
|
100
94
|
end
|
101
95
|
|
102
96
|
# Return a Date object of the date which represents +self+.
|
data/xmlrpc.gemspec
CHANGED
@@ -18,7 +18,7 @@ Gem::Specification.new do |spec|
|
|
18
18
|
spec.bindir = "exe"
|
19
19
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
20
20
|
spec.require_paths = ["lib"]
|
21
|
-
spec.required_ruby_version = ">= 2.4.
|
21
|
+
spec.required_ruby_version = ">= 2.4.0"
|
22
22
|
|
23
23
|
spec.add_development_dependency "bundler"
|
24
24
|
spec.add_development_dependency "rake"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xmlrpc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- SHIBATA Hiroshi
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-12-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -91,7 +91,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
91
91
|
requirements:
|
92
92
|
- - ">="
|
93
93
|
- !ruby/object:Gem::Version
|
94
|
-
version: 2.4.
|
94
|
+
version: 2.4.0
|
95
95
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
96
96
|
requirements:
|
97
97
|
- - ">="
|
@@ -99,7 +99,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
99
99
|
version: '0'
|
100
100
|
requirements: []
|
101
101
|
rubyforge_project:
|
102
|
-
rubygems_version: 2.6.
|
102
|
+
rubygems_version: 2.6.8
|
103
103
|
signing_key:
|
104
104
|
specification_version: 4
|
105
105
|
summary: XMLRPC is a lightweight protocol that enables remote procedure calls over
|