Class: PrioTicket::Ticket
- Inherits:
-
Object
- Object
- PrioTicket::Ticket
- Defined in:
- lib/prioticket/ticket.rb
Overview
Describes a single result from the [TicketList]
Instance Attribute Summary collapse
-
#distributor_id ⇒ Object
Returns the value of attribute distributor_id.
-
#identifier ⇒ Object
Returns the value of attribute identifier.
-
#ticket_id ⇒ Object
Returns the value of attribute ticket_id.
-
#ticket_title ⇒ Object
Returns the value of attribute ticket_title.
-
#txt_language ⇒ Object
Returns the value of attribute txt_language.
-
#venue_name ⇒ Object
Returns the value of attribute venue_name.
Instance Method Summary collapse
-
#details ⇒ Object
Queries the TicketDetail method and retruns a [TicketDetails] object.
-
#initialize(args) ⇒ Ticket
constructor
A new instance of Ticket.
Constructor Details
#initialize(args) ⇒ Ticket
Returns a new instance of Ticket.
16 17 18 19 20 21 |
# File 'lib/prioticket/ticket.rb', line 16 def initialize(args) return if args.nil? args.each do |k,v| PrioTicket.parse_json_value(self, k,v) end end |
Instance Attribute Details
#distributor_id ⇒ Object
Returns the value of attribute distributor_id.
10 11 12 |
# File 'lib/prioticket/ticket.rb', line 10 def distributor_id @distributor_id end |
#identifier ⇒ Object
Returns the value of attribute identifier.
9 10 11 |
# File 'lib/prioticket/ticket.rb', line 9 def identifier @identifier end |
#ticket_id ⇒ Object
Returns the value of attribute ticket_id.
11 12 13 |
# File 'lib/prioticket/ticket.rb', line 11 def ticket_id @ticket_id end |
#ticket_title ⇒ Object
Returns the value of attribute ticket_title.
12 13 14 |
# File 'lib/prioticket/ticket.rb', line 12 def ticket_title @ticket_title end |
#txt_language ⇒ Object
Returns the value of attribute txt_language.
14 15 16 |
# File 'lib/prioticket/ticket.rb', line 14 def txt_language @txt_language end |
#venue_name ⇒ Object
Returns the value of attribute venue_name.
13 14 15 |
# File 'lib/prioticket/ticket.rb', line 13 def venue_name @venue_name end |
Instance Method Details
#details ⇒ Object
Queries the TicketDetail method and retruns a [TicketDetails] object.
28 29 30 |
# File 'lib/prioticket/ticket.rb', line 28 def details PrioTicket::TicketDetails.find(distributor_id: distributor_id, ticket_id: ticket_id, identifier: identifier) end |