diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2012-06-26 16:25:35 +0200 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2012-06-26 16:25:35 +0200 |
commit | 842cf74d34c9fe95c43449c2d662cd0fc19b25f9 (patch) | |
tree | a03852e649e48c0cca8c72f993608c0edad7b916 /lib | |
parent | 85765f11fe12912dffa7873c2f291e28221d901f (diff) | |
download | edoors-ruby-842cf74d34c9fe95c43449c2d662cd0fc19b25f9.zip edoors-ruby-842cf74d34c9fe95c43449c2d662cd0fc19b25f9.tar.gz |
Particle,Link: use @raise yard tag
Diffstat (limited to 'lib')
-rw-r--r-- | lib/edoors/link.rb | 2 | ||||
-rw-r--r-- | lib/edoors/particle.rb | 4 |
2 files changed, 6 insertions, 0 deletions
diff --git a/lib/edoors/link.rb b/lib/edoors/link.rb index 8676979..ede2cd4 100644 --- a/lib/edoors/link.rb +++ b/lib/edoors/link.rb @@ -64,6 +64,8 @@ module Edoors # # @param [Hash] o belongs to JSON parser # + # @raise Edoors::Exception if the json kls attribute is wrong + # def self.json_create o raise Edoors::Exception.new "JSON #{o['kls']} != #{self.name}" if o['kls'] != self.name self.new o['src'], o['dsts'], o['keys'], o['value'] diff --git a/lib/edoors/particle.rb b/lib/edoors/particle.rb index 983af01..c7244d0 100644 --- a/lib/edoors/particle.rb +++ b/lib/edoors/particle.rb @@ -104,6 +104,8 @@ module Edoors # # @param [Hash] o belongs to JSON parser # + # @raise Edoors::Exception if the json kls attribute is wrong + # def self.json_create o raise Edoors::Exception.new "JSON #{o['kls']} != #{self.name}" if o['kls'] != self.name self.new o @@ -151,6 +153,8 @@ module Edoors # # @param [Array] dsts destinations to add # + # @raise Edoors::Exception if a destination is not acceptable + # # The parameters are checked before beeing added. # they must not be empty or be '?' or start with '/' # or contain '/?' or '//' or '\s+' |