casual_helper 0.0.14 → 0.0.15

Sign up to get free protection for your applications and to get access to all the features.
data/lib/casual_helper.rb CHANGED
@@ -175,12 +175,25 @@ module CasualHelper
175
175
  post "#{@api_server.to_s}/v0/taps/#{tap_id}/update", { :feedback => { :comments => [comment_string] } }
176
176
  end
177
177
 
178
+ #COUNTERS
179
+
178
180
  def update_counters_tap(tap_id, counter_id, amount)
179
181
  return if are_invalid tap_id, counter_id, amount
180
182
  counters_hash = Hash.new
181
183
  counters_hash[counter_id] = amount
182
184
  post "#{@api_server.to_s}/v0/taps/#{tap_id}/update", { :feedback => { :counters => counters_hash } }
183
185
  end
186
+
187
+ #TAGS
188
+ def set_tags_tap(tap_id, tags)
189
+ return if are_invalid tap_id, tags
190
+ post "#{@api_server.to_s}/v0/taps/#{tap_id}/update", {:feedback => { :set_tags => tags}}
191
+ end
192
+
193
+ def unset_tags_tap(tap_id, tags)
194
+ return if are_invalid tap_id, tags
195
+ post "#{@api_server.to_s}/v0/taps/#{tap_id}/update", {:feedback => { :unset_tags => tags}}
196
+ end
184
197
 
185
198
  # @return hash with attributes passed in and readable_id
186
199
  def get_config(id)
@@ -1,3 +1,3 @@
1
1
  module CasualHelper
2
- VERSION = "0.0.14"
2
+ VERSION = "0.0.15"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: casual_helper
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.14
4
+ version: 0.0.15
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-10-23 00:00:00.000000000 Z
12
+ date: 2012-11-26 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rest-client