Class: ActiveAdmin::SettingsNode

Inherits:
Object
  • Object
show all
Defined in:
lib/active_admin/settings_node.rb

Class Method Summary collapse

Class Method Details

.build(superclass = self) ⇒ Object

Returns anonymous class with same accessors as the superclass.

Returns:

  • anonymous class with same accessors as the superclass.


9
10
11
# File 'lib/active_admin/settings_node.rb', line 9

def build(superclass = self)
  Class.new(superclass)
end

.register(name, value) ⇒ Object


13
14
15
16
# File 'lib/active_admin/settings_node.rb', line 13

def register(name, value)
  class_attribute name
  send "#{name}=", value
end