Class: UserConfiguration
- Inherits:
-
Object
- Object
- UserConfiguration
- Defined in:
- lib/user_configuration.rb
Instance Attribute Summary collapse
-
#email ⇒ Object
readonly
Returns the value of attribute email.
-
#initials ⇒ Object
readonly
Returns the value of attribute initials.
-
#key ⇒ Object
readonly
Returns the value of attribute key.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(name: nil, email: nil, key: nil, initials: nil) ⇒ UserConfiguration
constructor
A new instance of UserConfiguration.
Constructor Details
#initialize(name: nil, email: nil, key: nil, initials: nil) ⇒ UserConfiguration
Returns a new instance of UserConfiguration.
4 5 6 7 8 9 10 11 |
# File 'lib/user_configuration.rb', line 4 def initialize(name: nil, email: nil, key: nil, initials: nil) @name = name @email = email @key = key @initials = initials raise 'User Information Missing' unless everything_defined? end |
Instance Attribute Details
#email ⇒ Object (readonly)
Returns the value of attribute email.
2 3 4 |
# File 'lib/user_configuration.rb', line 2 def email @email end |
#initials ⇒ Object (readonly)
Returns the value of attribute initials.
2 3 4 |
# File 'lib/user_configuration.rb', line 2 def initials @initials end |
#key ⇒ Object (readonly)
Returns the value of attribute key.
2 3 4 |
# File 'lib/user_configuration.rb', line 2 def key @key end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
2 3 4 |
# File 'lib/user_configuration.rb', line 2 def name @name end |
Instance Method Details
#==(other) ⇒ Object
13 14 15 |
# File 'lib/user_configuration.rb', line 13 def ==(other) state_variables == other.state_variables end |