Sha256: 9fdf67333b6c0b300ef30609ff579009a03a1c375a617532ee255a2c091ad650
Contents?: true
Size: 477 Bytes
Versions: 1
Compression:
Stored size: 477 Bytes
Contents
module Rules module Parameters require 'rules/parameters/parameter' require 'rules/parameters/attribute' require 'rules/parameters/constant' @@constants ||= {} def self.constants @@constants end def self.define_constant(key, &block) raise "Constant #{key} already exists" if @@constants[key] constant = Constant.new(key) constant.instance_eval(&block) if block_given? @@constants[key] = constant end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
rules-0.0.1 | lib/rules/parameters.rb |