Module: Spree::Core::EnvironmentExtension::InstanceMethods
- Defined in:
- lib/spree/core/environment_extension.rb
Instance Method Summary collapse
Instance Method Details
#add_class(name) ⇒ Object
8 9 10 11 12 13 14 15 16 17 |
# File 'lib/spree/core/environment_extension.rb', line 8 def add_class(name) self.instance_variable_set "@#{name}", Set.new create_method( "#{name}=".to_sym ) { |val| instance_variable_set( "@" + name, val) } create_method( name.to_sym ) { instance_variable_get( "@" + name ) } end |