Class: Mailtrap::ContactList

Inherits:
Struct
  • Object
show all
Defined in:
lib/mailtrap/contact_list.rb

Overview

Data Transfer Object for Contact List

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#idInteger (readonly)

The contact list ID

Returns:

  • (Integer)

    the current value of id



8
9
10
# File 'lib/mailtrap/contact_list.rb', line 8

def id
  @id
end

#nameString (readonly)

The name of the contact list

Returns:

  • (String)

    the current value of name



8
9
10
# File 'lib/mailtrap/contact_list.rb', line 8

def name
  @name
end

Instance Method Details

#to_hHash

Returns The contact list attributes as a hash.

Returns:

  • (Hash)

    The contact list attributes as a hash



10
11
12
# File 'lib/mailtrap/contact_list.rb', line 10

def to_h
  super.compact
end