Class: Preferences

Inherits:
Object
  • Object
show all
Includes:
ActiveModel::Model
Defined in:
app/models/preferences.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.attributesObject



4
5
6
# File 'app/models/preferences.rb', line 4

def self.attributes
  [:uppercase_mode]
end

.from_attributes(*args) ⇒ Object



10
11
12
# File 'app/models/preferences.rb', line 10

def self.from_attributes(*args)
  new self.attributes.zip(args).to_h
end

Instance Method Details

#uppercase?Boolean

Returns:

  • (Boolean)


14
15
16
# File 'app/models/preferences.rb', line 14

def uppercase?
  uppercase_mode
end