Class: WelcomeCycle::EmailRegister

Inherits:
Object
  • Object
show all
Includes:
Singleton
Defined in:
lib/welcome_cycle/email_register.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeEmailRegister

Returns a new instance of EmailRegister.



8
9
10
# File 'lib/welcome_cycle/email_register.rb', line 8

def initialize
  @emails = []
end

Instance Attribute Details

#emailsObject

Returns the value of attribute emails.



6
7
8
# File 'lib/welcome_cycle/email_register.rb', line 6

def emails
  @emails
end

Instance Method Details

#<<(email) ⇒ Object



12
13
14
# File 'lib/welcome_cycle/email_register.rb', line 12

def <<(email)
  @emails << email
end

#eachObject



16
17
18
# File 'lib/welcome_cycle/email_register.rb', line 16

def each
  @emails.each { |email| yield(email) }
end