rsc 0.4.0 → 0.4.1

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: abd05c2d664728dadb702b64f048d4464a3fcdae
4
- data.tar.gz: f3e3fecec0cc821b87bc448eed133fb7e789b07a
3
+ metadata.gz: 592ee3af7df9056cfaed66982f44474a8af559f7
4
+ data.tar.gz: 2f7554f683609a6a1a46a01f4c0bc205c286454d
5
5
  SHA512:
6
- metadata.gz: 668c6a4e39dc1a5c11aa6f55ec92c1cc30a42fbfd6568d4913b923cb3074eb727b84c074141d0f7104d4b9cb95e331a8a1f424453b92b29a653dd386b817890f
7
- data.tar.gz: f2dfbf1cf9d33c162754d33c0a06f105b43952431bc305d30ebf70b0ce48574110f99043e752ee8cb8ac819c70dfa1e2b92ffb518d5fce9f79e21b9b57b61985
6
+ metadata.gz: 0c07b67164eafba644d0b6a2931ee70cdc5e0db62c9ddf51b5e7df944bef8c66ebeeda210112a0e249b32fccd87c5ae8745f72172e83d1f29e5ee4499ee1d5af
7
+ data.tar.gz: 62f4a4eae5b011175535742e98367e7eec1459294773bc054edefa8f036618e3470484c90ba78eb274b0de2bd240427ea8df8b875ecbc00e11de293364b02826
Binary file
data.tar.gz.sig CHANGED
Binary file
data/lib/rsc.rb CHANGED
@@ -9,9 +9,11 @@ require 'rexle'
9
9
 
10
10
  class Rse
11
11
 
12
- def self.call(x)
13
- RSC.new.get(x)
14
- end
12
+ def self.call(x) RSC.new.get(x) end
13
+ def self.get(x) RSC.new.get(x) end
14
+ def self.post(x, val) RSC.new.post(x, val) end
15
+ def self.delete(x) RSC.new.delete(x) end
16
+ def self.put(x, val) RSC.new.put(x, val) end
15
17
 
16
18
  end
17
19
 
@@ -28,10 +30,11 @@ class RSC
28
30
  a = doc.root.xpath 'job/attribute::id'
29
31
 
30
32
  a.each do |attr|
31
- method_name = attr.value.gsub('-','_')
33
+ method_name = attr.value.gsub('-','_')
32
34
  method = "def %s(*args); run_job('%s', args) ; end" % \
33
35
  ([method_name] * 2)
34
- self.instance_eval(method)
36
+ self.instance_eval(method)
37
+
35
38
  end
36
39
 
37
40
  end
@@ -71,7 +74,7 @@ class RSC
71
74
  s ? run_uri(s, :post, value: val) : @obj.post
72
75
  end
73
76
 
74
- def put(s)
77
+ def put(s=nil, val=nil)
75
78
  s ? run_uri(s, :put, value: val) : @obj.put
76
79
  end
77
80
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rsc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Robertson
@@ -30,7 +30,7 @@ cert_chain:
30
30
  o+hpgqEdXScsw0ZCQMvy0aH5DiiF2mtGr84n+mevsXQKg0IsjBEvA6StSJ63eMpL
31
31
  dTs=
32
32
  -----END CERTIFICATE-----
33
- date: 2018-06-02 00:00:00.000000000 Z
33
+ date: 2018-06-21 00:00:00.000000000 Z
34
34
  dependencies:
35
35
  - !ruby/object:Gem::Dependency
36
36
  name: rexle
metadata.gz.sig CHANGED
Binary file