Class | Request::SetEarsPosition |
In: |
lib/violet/request.rb
|
Parent: | Base::Event |
MIN_POS | = | 0 |
MAX_POS | = | 16 |
# File lib/violet/request.rb, line 114 114: def initialize h 115: @h = h.dup 116: raise ArgumentError.new('at least :posright or :posleft must be set') unless @h[:posleft] or @h[:posright] 117: raise ArgumentError.new(":posright must be between #{MIN_POS} and #{MAX_POS}") if @h[:posright] and not @h[:posright].to_i.between?(MIN_POS,MAX_POS) 118: raise ArgumentError.new(":posleft must be between #{MIN_POS} and #{MAX_POS}") if @h[:posleft ] and not @h[:posleft ].to_i.between?(MIN_POS,MAX_POS) 119: end