Class: Contact

Inherits:
Object
  • Object
show all
Extended by:
ActiveModel::Naming
Includes:
ActiveModel::Conversion, ActiveModel::Validations
Defined in:
lib/forge/app/models/contact.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ Contact

Returns a new instance of Contact.



12
13
14
15
16
# File 'lib/forge/app/models/contact.rb', line 12

def initialize(attributes = {})
  attributes.each do |name, value|
    send("#{name}=", value)
  end
end

Instance Attribute Details

#contentObject

Returns the value of attribute content.



6
7
8
# File 'lib/forge/app/models/contact.rb', line 6

def content
  @content
end

#emailObject

Returns the value of attribute email.



6
7
8
# File 'lib/forge/app/models/contact.rb', line 6

def email
  @email
end

#nameObject

Returns the value of attribute name.



6
7
8
# File 'lib/forge/app/models/contact.rb', line 6

def name
  @name
end

#phoneObject

Returns the value of attribute phone.



6
7
8
# File 'lib/forge/app/models/contact.rb', line 6

def phone
  @phone
end

#subjectObject

Returns the value of attribute subject.



6
7
8
# File 'lib/forge/app/models/contact.rb', line 6

def subject
  @subject
end

Instance Method Details

#persisted?Boolean

Returns:

  • (Boolean)


18
19
20
# File 'lib/forge/app/models/contact.rb', line 18

def persisted?
  false
end