// Copyright 2014 Apple Inc.  All Rights Reserved.
(function(){return function(e,t,r){var n=Scanner.fromMessage(e);n.setLocale(t);var a,o,s,i,d,p,g,x,h,u;p=n.getSpan().innerCapture(regExpFormatted(/\1\s(\D+\d+)/,r.reservationIdPrefix),1),a=n.getSpan().nextText(r.underPersonNamePrefix).parentTag("td5").tagContents().innerCapture(regExpFormatted(/\1\s(.*)/,r.underPersonNamePrefix),1),[,g,x]=n.getSpan().innerCapture(regExpFormatted(/\1\s(.*?)\s\2\s(.*?)\s/,r.checkInDatePrefix,r.checkOutDatePrefix)),g=n.getDetachedSpan(""+g).innerDate(),x=n.getDetachedSpan(""+x).innerDate(),o=n.getSpan().nextText(r.hotelNamePrefix).parentTag("td5").tagContents().innerCapture(regExpFormatted(/\1\s(.*)/,r.hotelNamePrefix),1),s=n.getSpan().nextText(r.hotelPhonePrefix).parentTag("td5").tagContents().innerCapture(regExpFormatted(/\1\s(.*)/,r.hotelPhonePrefix),1),i=n.getSpan().nextText(r.hotelAddress.addressPrefix).parentTag("td5").tagContents().innerCapture(regExpFormatted(/\1\s(.*)/,r.hotelAddress.addressPrefix),1);var l=(""+n.getSpan().nextText(r.hotelAddress.townPrefix).parentTag("td5").tagContents().innerCapture(regExpFormatted(/\1\s(.*)/,r.hotelAddress.townPrefix),1)).trim();return l!=""+n.getNullSpan()&&(i=n.getDetachedSpan(""+i+", "+l)),d=n.getSpan().nextText(r.hotelGeoCoordinates.prefix).parentTag("td5").tagContents().innerCapture(regExpFormatted(/\1\s([\+\-]?\d+\.\d+)\s\2\s([\+\-]?\d+\.\d+)\./,r.hotelGeoCoordinates.latitudePrefix,r.hotelGeoCoordinates.longitudePrefix)),[,u,h]=n.getSpan().innerCapture(regExpFormatted(/\1\s?([\d,.]+)\s?(\D)/,r.pricePrefix)),ASSERT(a,i,g)?[{"@context":"http://schema.org","@type":"http://schema.org/LodgingReservation",underName:{"@type":"http://schema.org/Person",name:a},totalPrice:h,priceCurrency:u,checkinTime:g,checkoutTime:x,reservationStatus:"http://schema.org/ReservationConfirmed",reservationId:p,reservationFor:{"@type":"http://schema.org/LodgingBusiness",name:o,telephone:s,address:i,geo:null!==d&&"number"==typeof d.length&&3===d.length?{"@type":"http://schema.org/GeoCoordinates",latitude:d[1],longitude:d[2]}:null}}]:CONTINUE}}).call();