Class: ContextIO::EmailAddress

Inherits:
Object
  • Object
show all
Defined in:
lib/contextio/email_address.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.association_nameObject



5
6
7
# File 'lib/contextio/email_address.rb', line 5

def self.association_name
  :email_address
end

Instance Method Details

#deleteObject



51
52
53
# File 'lib/contextio/email_address.rb', line 51

def delete
  api.request(:delete, resource_url)['success']
end

#primary?Boolean

Returns:

  • (Boolean)


43
44
45
# File 'lib/contextio/email_address.rb', line 43

def primary?
  !!primary
end

#set_primaryObject



47
48
49
# File 'lib/contextio/email_address.rb', line 47

def set_primary
  api.request(:post, resource_url, primary: 1)['success']
end

#validated?Boolean

Returns:

  • (Boolean)


39
40
41
# File 'lib/contextio/email_address.rb', line 39

def validated?
  !!validated
end