brocade_vrouter 0.2.1 → 0.2.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7b91e6f3f19bccdbfdc5c66262469a43fa287041
4
- data.tar.gz: f59f880685c83a46baf23a7e0ad8c5b4e5c938aa
3
+ metadata.gz: f0916f52ce7f134b0c2f7d45600fe605750bfe7f
4
+ data.tar.gz: 8dfc79c74bbf9dd5247226a2c94bd0903260f348
5
5
  SHA512:
6
- metadata.gz: b5a4a4f8d24f82f084132ca0b367030b17de56763835ccf473e45e7abc14d96c13302c8c5ebb841bba8be1bdbde3e4361fc0e903be7a6992843eb8384d0f9bd1
7
- data.tar.gz: 9c7165ccd706289731b952ab219acaa3c90847d90e0e011156d1686b6e632d9c7222fd0f0b530febd6198fe6ccd95e90618b53d5edbb2fb5a79d06f0f1294436
6
+ metadata.gz: 8192680c0587fca8ccc185433e19ea8dffa187c47088a90dbbcee277de8122c85be8f29a9116796eaa865153b342e56369cf7baaa2fc67a74b3fa3938a358ca0
7
+ data.tar.gz: a7c73f951c1389b6ced31cb875d420b1c8fdff4019b10cf5281330f95cad321e7c9b844169df6580ace3856131cd903a5f2f2c17d0197d19ce394843603e7b65
@@ -21,12 +21,17 @@ module BrocadeVRouter
21
21
 
22
22
  private
23
23
 
24
- [:address, :route].each do |name|
25
- define_method name do |value|
26
- addresses = Array(value).map { |v| URI.escape v.to_s, SEPARATOR }
27
- @paths << generate_paths!(name, addresses)
28
- @paths.last
29
- end
24
+ def route(value, &blk)
25
+ address = URI.escape value.to_s, SEPARATOR
26
+ @paths << address
27
+ @paths << generate_paths!(:route, address, nil, &blk)
28
+ @paths.last
29
+ end
30
+
31
+ def address(value, &blk)
32
+ addresses = Array(value).map { |v| URI.escape v.to_s, SEPARATOR }
33
+ @paths << generate_paths!(:address, addresses, nil, &blk)
34
+ @paths.last
30
35
  end
31
36
 
32
37
  def method_missing(*args, &blk)
@@ -1,3 +1,3 @@
1
1
  module BrocadeVRouter
2
- VERSION = '0.2.1'
2
+ VERSION = '0.2.2'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: brocade_vrouter
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Konstantin Kosmatov