// Copyright 2014 Apple Inc.  All Rights Reserved.
(function(){return function(t,e,a){var n=Scanner.fromMessage(t);n.setLocale(e);var r,o,s,c,i,g,l,p,h=n.getSpan(),u="Confirmed",v=h.nextTag("table5").allInnerTagsFiltered("td5");if(r=v[0].tagContents().innerCapture(/(.*) <http/,1),r===n.getNullSpan()&&(r=v[0].tagContents()),a.changeSubject.test(t.subject)?(i=v[2],g=v[3],s=v[4]):(i=v[1],g=v[2],s=v[3]),l=getFuzzyDate(n.getDetachedSpan(i+" "+g)),o=h.next(a.url_prefix).nextLink(),ASSERT(r,i)){var d={"@context":"http://schema.org","@type":"http://schema.org/EventReservation",reservationStatus:"http://schema.org/Reservation"+u,reservationFor:{name:r,url:o,"@type":"http://schema.org/SocialEvent",startDate:l,description:c,location:{"@type":"http://schema.org/Place",address:s}}};return valid(p)&&(d.reservationFor.endDate=p),[d]}return CONTINUE}}).call();