Module: ActsAsPreferenced::ClassMethods

Defined in:
lib/acts_as_preferenced.rb

Instance Method Summary collapse

Instance Method Details

#all_preferencesObject



49
50
51
# File 'lib/acts_as_preferenced.rb', line 49

def all_preferences
  preference_config.all_preferences
end

#preference_sectionsObject

TODO: Those methods should only be available when preferences are actually defined



41
42
43
# File 'lib/acts_as_preferenced.rb', line 41

def preference_sections
  preference_config.sections.keys
end

#preferences_for_section(section) ⇒ Object



45
46
47
# File 'lib/acts_as_preferenced.rb', line 45

def preferences_for_section( section )
  preference_config.sections[section]
end