Class: Clever::Models::District
- Inherits:
-
Object
- Object
- Clever::Models::District
- Defined in:
- lib/clever/models/district.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(params) ⇒ District
constructor
A new instance of District.
Constructor Details
#initialize(params) ⇒ District
Returns a new instance of District.
4 5 6 |
# File 'lib/clever/models/district.rb', line 4 def initialize params params.each { |k,v| instance_variable_set("@#{k}", v) unless v.nil? } end |
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id.
2 3 4 |
# File 'lib/clever/models/district.rb', line 2 def id @id end |
#name ⇒ Object
Returns the value of attribute name.
2 3 4 |
# File 'lib/clever/models/district.rb', line 2 def name @name end |