// Copyright 2014 Apple Inc.  All Rights Reserved.
(function(){return function(e,t,r){var a=Scanner.fromMessage(e);a.setLocale(t);var n,i,o,p,m,s,c,g,u,x,h,d="Confirmed",E=[],l=[];n=a.getSpan().innerCapture(regExpFormatted(/\1\s(.*)/,r.personUnderNamePrefix),1),[,h,x]=a.getSpan().innerCapture(regExpFormatted(/\1\s(\D+)\s([\d\,\.]+)/,r.pricePrefix));for(var f=a.getSpan().nextRegExp(regExpFormatted(/\1\s(.*)/,r.ticketNumberPrefix));f!==a.getNullSpan();){var v={};v.ticketNumber=f.innerCapture(regExpFormatted(/\1\s(.*)/,r.ticketNumberPrefix),1),f=a.getSpan().withInterval(f.getEnd(),a.getSpan().getEnd()),v.name=f.innerCapture(regExpFormatted(/\1\s(.*)/,r.eventNamePrefix),1),v.startDateTime=f.innerCapture(regExpFormatted(/\1\s(.*)/,r.eventDateTimePrefix),1).innerDate(),v.locationName=f.innerCapture(regExpFormatted(/\1\s(.*)/,r.eventLocationNamePrefix),1),v.startDateTime!==a.getNullSpan()&&E.push(v),f=f.nextRegExp(regExpFormatted(/\1\s(.*)/,r.ticketNumberPrefix))}return E.forEach(function(e){ASSERT(e.name,e.startDateTime)&&l.push({"@context":"http://schema.org","@type":"http://schema.org/EventReservation",name:n,totalPrice:x,priceCurrency:h,reservedTicket:{"@type":"http://schema.org/Ticket",ticketNumber:m,ticketToken:s,ticketedSeat:{"@type":"http://schema.org/Seat",seatNumber:c,seatSection:g,seatRow:u}},reservationFor:{"@type":"http://schema.org/Event",eventStatus:"http://schema.org/Event"+d,name:e.name,url:e.url,startDate:e.startDateTime,endDate:i,location:{"@type":"http://schema.org/Place",name:e.locationName,telephone:p,address:o}}})}),l.length>0?l:CONTINUE}}).call();