Class: GeneralMail

Inherits:
Mail
  • Object
show all
Defined in:
lib/sinatra/extensions/generalmail.rb

Instance Method Summary collapse

Methods inherited from Mail

#from, #send, #to

Constructor Details

#initialize(args) ⇒ GeneralMail

Returns a new instance of GeneralMail.



4
5
6
7
8
9
# File 'lib/sinatra/extensions/generalmail.rb', line 4

def initialize(args)
  super(args)
  @subject = args[:subject]
  @description = args[:description]
  @link = args[:link]
end

Instance Method Details

#subjectObject



15
16
17
# File 'lib/sinatra/extensions/generalmail.rb', line 15

def subject
  @subject
end

#templateObject



11
12
13
# File 'lib/sinatra/extensions/generalmail.rb', line 11

def template
  'general'
end

#valuesObject



19
20
21
22
23
24
# File 'lib/sinatra/extensions/generalmail.rb', line 19

def values
  data = {}
  data["{description}"] = @description
  data["{link}"] = @link
  data
end