Class: UnfuddleMyEmail::EmailTicket
- Inherits:
-
Object
- Object
- UnfuddleMyEmail::EmailTicket
- Defined in:
- lib/unfuddle_my_email/email_ticket.rb
Overview
Create an XML formatted ticket.
Expects an object that responds to the following methods:
-
subject: The summary for the ticket -
from: An array of authors -
body: Will be added the the ticket description
Instance Attribute Summary collapse
-
#message ⇒ Object
Returns the value of attribute message.
Instance Method Summary collapse
-
#initialize(message) ⇒ EmailTicket
constructor
A new instance of EmailTicket.
-
#to_xml ⇒ Object
Returns an XML representation of an Unfuddle ticket.
Constructor Details
#initialize(message) ⇒ EmailTicket
14 15 16 |
# File 'lib/unfuddle_my_email/email_ticket.rb', line 14 def initialize() = end |
Instance Attribute Details
#message ⇒ Object
Returns the value of attribute message.
12 13 14 |
# File 'lib/unfuddle_my_email/email_ticket.rb', line 12 def end |
Instance Method Details
#to_xml ⇒ Object
Returns an XML representation of an Unfuddle ticket.
20 21 22 23 24 25 26 27 |
# File 'lib/unfuddle_my_email/email_ticket.rb', line 20 def to_xml builder = Builder::XmlMarkup.new return xml = builder.ticket { |ticket| ticket.priority "1" ticket.summary subject ticket.description description } end |