Class: Splicer::DnsMadeEasy::Domain
- Inherits:
-
Object
- Object
- Splicer::DnsMadeEasy::Domain
- Defined in:
- lib/splicer/dns_made_easy/domain.rb
Instance Attribute Summary collapse
-
#data ⇒ Object
readonly
Returns the value of attribute data.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
Instance Method Summary collapse
-
#initialize(params = {}) ⇒ Domain
constructor
A new instance of Domain.
- #persisted? ⇒ Boolean (also: #id?)
Constructor Details
#initialize(params = {}) ⇒ Domain
Returns a new instance of Domain.
7 8 9 10 |
# File 'lib/splicer/dns_made_easy/domain.rb', line 7 def initialize(params={}) @id = params['id'] @data = params end |
Instance Attribute Details
#data ⇒ Object (readonly)
Returns the value of attribute data.
5 6 7 |
# File 'lib/splicer/dns_made_easy/domain.rb', line 5 def data @data end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
5 6 7 |
# File 'lib/splicer/dns_made_easy/domain.rb', line 5 def id @id end |
Instance Method Details
#persisted? ⇒ Boolean Also known as: id?
12 13 14 |
# File 'lib/splicer/dns_made_easy/domain.rb', line 12 def persisted? !!@id end |