almundo-restconnector 2.0.14 → 2.0.15

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/almundo-restconnector.rb +13 -0
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 914381b055514d37928a4008bc7cb260f01eec69
4
- data.tar.gz: 67033a23339ebb0cf8ead19352574fee2441948b
3
+ metadata.gz: 5e2e8223916c8c045e91a2b32ea034e028cfc173
4
+ data.tar.gz: 819fd51e775822b22e44d0986b1c3c355b2fee95
5
5
  SHA512:
6
- metadata.gz: ba45677132b4a698a2afec3e211f327f5431497dae5e576d062281862d72e7c6833e36578215174a3a6e86fc532fca496ab96cb1c574d79a508588f65fd36406
7
- data.tar.gz: e954dde0dda28ab762995af1c88725ad3c1081993e714d29b11d531b12b62533170ea1234e45dcb60ce8df3f9ae65a61e6a2438210dfdfb9a502de0dc83d68e9
6
+ metadata.gz: d21727668a26fad5162f99f2165ea8ad409cbc50454732a2e5cc0df7d0526d52c2324d41c57c3f33b0a6d6f25e60c4bd5108239a6f161bf2a2cfdfa4c7e1a573
7
+ data.tar.gz: dfa41669718c548280fcae5b3eed4fc1aa982ca03c5a99aead41e684ebe1c027a595b7eb8cd05e8d53102fad2eb2d4d3f2329cede1e76296f223b7b78cfb1256
@@ -78,6 +78,17 @@ class RestConnector
78
78
  return self
79
79
  end
80
80
 
81
+ def delete(uri)
82
+ @@logger.debug "[RestConnector] setting DELETE request uri '#{uri}'"
83
+
84
+ @method = "DELETE"
85
+ @uri = URI uri
86
+
87
+ create_http_request
88
+
89
+ return self
90
+ end
91
+
81
92
  #######################
82
93
  ## => PARAMS METHODS
83
94
  #######################
@@ -208,6 +219,8 @@ class RestConnector
208
219
  @request = Net::HTTP::Post.new(@uri, initheader = {'Content-Type' =>'application/json'})
209
220
  when "PUT"
210
221
  @request = Net::HTTP::Put.new(@uri, initheader = {'Content-Type' =>'application/json'})
222
+ when "DELETE"
223
+ @request = Net::HTTP::Delete.new(@uri)
211
224
  end
212
225
  end
213
226
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: almundo-restconnector
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.14
4
+ version: 2.0.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matías Sueiro
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-12 00:00:00.000000000 Z
11
+ date: 2015-02-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json