Sha256: bd09c0846a6f741a214bedceead0bd3fa1576b83a02ae9655c890c7a301261d7
Contents?: true
Size: 434 Bytes
Versions: 6
Compression:
Stored size: 434 Bytes
Contents
# -*- coding: utf-8 -*- module Xot module Setter def set (*args) first = args.shift if first.kind_of? Hash first.each {|name, value| set_value__ name, value} else set_value__ first, *args end end private def set_value__ (name, *values) raise ArgumentError unless name && !values.empty? __send__ "#{name}=", *values end end# Setter end# Xot
Version data entries
6 entries across 6 versions & 1 rubygems
Version | Path |
---|---|
xot-0.1.12 | lib/xot/setter.rb |
xot-0.1.11 | lib/xot/setter.rb |
xot-0.1.10 | lib/xot/setter.rb |
xot-0.1.9 | lib/xot/setter.rb |
xot-0.1.8 | lib/xot/setter.rb |
xot-0.1.7 | lib/xot/setter.rb |