Class: RMail::Address::List

Inherits:
Array
  • Object
show all
Defined in:
lib/rmail/address.rb

Overview

RMail::Address::List is a simple subclass of the Array class that provides convenience methods for accessing the RMail::Address objects it contains.

Instance Method Summary collapse

Instance Method Details

#addressesObject

Returns an array of strings – the result of calling RMail::Address#address on each element of the list.



823
824
825
# File 'lib/rmail/address.rb', line 823

def addresses
  collect { |a| a.address }
end

#display_namesObject

Returns an array of strings – the result of calling RMail::Address#display_name on each element of the list.



805
806
807
# File 'lib/rmail/address.rb', line 805

def display_names
  collect { |a| a.display_name }
end

#domainsObject

Returns an array of strings – the result of calling RMail::Address#domain on each element of the list.



817
818
819
# File 'lib/rmail/address.rb', line 817

def domains
  collect { |a| a.domain }
end

#formatObject

Returns an array of strings – the result of calling RMail::Address#format on each element of the list.



829
830
831
# File 'lib/rmail/address.rb', line 829

def format
  collect { |a| a.format }
end

#localsObject

Returns an array of strings – the result of calling RMail::Address#local on each element of the list.



799
800
801
# File 'lib/rmail/address.rb', line 799

def locals
  collect { |a| a.local }
end

#namesObject

Returns an array of strings – the result of calling RMail::Address#name on each element of the list.



811
812
813
# File 'lib/rmail/address.rb', line 811

def names
  collect { |a| a.name }
end