// OpenLayers 3. See http://openlayers.org/ // License: https://raw.githubusercontent.com/openlayers/ol3/master/LICENSE.md // Version: v3.8.0-213-g9baf0b5 (function (root, factory) { if (typeof exports === "object") { module.exports = factory(); } else if (typeof define === "function" && define.amd) { define([], factory); } else { root.ol = factory(); } }(this, function () { var OPENLAYERS = {}; var l,aa=aa||{},ba=this;function m(b){return void 0!==b}function v(b,c,d){b=b.split(".");d=d||ba;b[0]in d||!d.execScript||d.execScript("var "+b[0]);for(var e;b.length&&(e=b.shift());)!b.length&&m(c)?d[e]=c:d[e]?d=d[e]:d=d[e]={}}function ca(){}function da(b){b.Za=function(){return b.Gg?b.Gg:b.Gg=new b}} function ea(b){var c=typeof b;if("object"==c)if(b){if(b instanceof Array)return"array";if(b instanceof Object)return c;var d=Object.prototype.toString.call(b);if("[object Window]"==d)return"object";if("[object Array]"==d||"number"==typeof b.length&&"undefined"!=typeof b.splice&&"undefined"!=typeof b.propertyIsEnumerable&&!b.propertyIsEnumerable("splice"))return"array";if("[object Function]"==d||"undefined"!=typeof b.call&&"undefined"!=typeof b.propertyIsEnumerable&&!b.propertyIsEnumerable("call"))return"function"}else return"null"; else if("function"==c&&"undefined"==typeof b.call)return"object";return c}function fa(b){return null===b}function ga(b){return"array"==ea(b)}function ha(b){var c=ea(b);return"array"==c||"object"==c&&"number"==typeof b.length}function ia(b){return"string"==typeof b}function ja(b){return"number"==typeof b}function ka(b){return"function"==ea(b)}function la(b){var c=typeof b;return"object"==c&&null!=b||"function"==c}function ma(b){return b[na]||(b[na]=++oa)} var na="closure_uid_"+(1E9*Math.random()>>>0),oa=0;function pa(b,c,d){return b.call.apply(b.bind,arguments)}function qa(b,c,d){if(!b)throw Error();if(2")&&(b=b.replace(Na,">"));-1!=b.indexOf('"')&&(b=b.replace(Oa,"""));-1!=b.indexOf("'")&&(b=b.replace(Pa,"'"));-1!=b.indexOf("\x00")&&(b=b.replace(Ra,"�"));return b}var La=/&/g,Ma=//g,Oa=/"/g,Pa=/'/g,Ra=/\x00/g,Ka=/[\x00&<>"']/; function Sa(b){b=m(void 0)?b.toFixed(void 0):String(b);var c=b.indexOf(".");-1==c&&(c=b.length);c=Math.max(0,2-c);return Array(c+1).join("0")+b} function Ta(b,c){for(var d=0,e=Ha(String(b)).split("."),f=Ha(String(c)).split("."),g=Math.max(e.length,f.length),h=0;0==d&&hc?1:0};function Wa(b){this.length=b.length||b;for(var c=0;cd?null:ia(b)?b.charAt(d):b[d]}function sb(b,c,d){for(var e=b.length,f=ia(b)?b.split(""):b,g=0;g=arguments.length?lb.slice.call(b,c):lb.slice.call(b,c,d)}function Ab(b,c){b.sort(c||Bb)}function Cb(b){for(var c=Db,d=0;dc?1:bd*c?d+c:d}function Kb(b,c,d){return b+d*(c-b)}function Lb(b){return b*Math.PI/180};var Mb,Nb;function Ob(b,c){b[0]+=c[0];b[1]+=c[1];return b}function Pb(b,c){var d=b[0],e=b[1],f=c[0],g=c[1],h=f[0],f=f[1],k=g[0],g=g[1],n=k-h,p=g-f,d=0===n&&0===p?0:(n*(d-h)+p*(e-f))/(n*n+p*p||0);0>=d||(1<=d?(h=k,f=g):(h+=d*n,f+=d*p));return[h,f]}function Qb(b,c){var d=Jb(b+180,360)-180,e=Math.abs(Math.round(3600*d));return Math.floor(e/3600)+"\u00b0 "+Sa(Math.floor(e/60%60))+"\u2032 "+Sa(Math.floor(e%60))+"\u2033 "+c.charAt(0>d?1:0)} function Rb(b,c,d){return m(b)?c.replace("{x}",b[0].toFixed(d)).replace("{y}",b[1].toFixed(d)):""}function Sb(b,c){for(var d=!0,e=b.length-1;0<=e;--e)if(b[e]!=c[e]){d=!1;break}return d}function Tb(b,c){var d=Math.cos(c),e=Math.sin(c),f=b[1]*d+b[0]*e;b[0]=b[0]*d-b[1]*e;b[1]=f;return b}function Ub(b,c){var d=b[0]-c[0],e=b[1]-c[1];return d*d+e*e}function Vb(b,c){return Ub(b,Pb(b,c))}function Wb(b,c){return Rb(b,"{x}, {y}",c)};function Xb(b,c,d){m(d)||(d=[0,0]);d[0]=b[0]+2*c;d[1]=b[1]+2*c;return d}function Yb(b,c,d){m(d)||(d=[0,0]);d[0]=b[0]*c+.5|0;d[1]=b[1]*c+.5|0;return d}function Zb(b,c){if(ga(b))return b;m(c)?(c[0]=b,c[1]=b):c=[b,b];return c};function $b(b){for(var c=ac(),d=0,e=b.length;de&&(k=k|4);hf&&(k|=2);0===k&&(k=1);return k}function ac(){return[Infinity,Infinity,-Infinity,-Infinity]} function dc(b,c,d,e,f){return m(f)?(f[0]=b,f[1]=c,f[2]=d,f[3]=e,f):[b,c,d,e]}function lc(b,c){var d=b[0],e=b[1];return dc(d,e,d,e,c)}function mc(b,c,d,e,f){f=dc(Infinity,Infinity,-Infinity,-Infinity,f);return nc(f,b,c,d,e)}function oc(b,c){return b[0]==c[0]&&b[2]==c[2]&&b[1]==c[1]&&b[3]==c[3]}function pc(b,c){c[0]b[2]&&(b[2]=c[2]);c[1]b[3]&&(b[3]=c[3]);return b} function bc(b,c){c[0]b[2]&&(b[2]=c[0]);c[1]b[3]&&(b[3]=c[1])}function nc(b,c,d,e,f){for(;dg;++g)h=f[g],k=e[g],f[g]=b[0]+h*c-k*d,e[g]=b[1]+h*d+k*c;return cc(f,e,void 0)}function yc(b){return b[3]-b[1]}function zc(b,c,d){d=m(d)?d:ac();Ac(b,c)&&(d[0]=b[0]>c[0]?b[0]:c[0],d[1]=b[1]>c[1]?b[1]:c[1],d[2]=b[2]=c[0]&&b[1]<=c[3]&&b[3]>=c[1]}function Cc(b){return b[2]parseFloat(b))?String(c):b}(),ld={};function md(b){return ld[b]||(ld[b]=0<=Ta(kd,b))}var nd=ba.document,od=nd&&bd?jd()||("CSS1Compat"==nd.compatMode?parseInt(kd,10):5):void 0;var pd=!bd||9<=od,qd=!bd||9<=od,rd=bd&&!md("9");!ed||md("528");dd&&md("1.9b")||bd&&md("8")||ad&&md("9.5")||ed&&md("528");dd&&!md("8")||bd&&md("9");function sd(){0!=td&&(ud[ma(this)]=this);this.fa=this.fa;this.na=this.na}var td=0,ud={};sd.prototype.fa=!1;sd.prototype.jd=function(){if(!this.fa&&(this.fa=!0,this.Y(),0!=td)){var b=ma(this);delete ud[b]}};function vd(b,c){var d=sa(wd,c);b.fa?d.call(void 0):(b.na||(b.na=[]),b.na.push(m(void 0)?ra(d,void 0):d))}sd.prototype.Y=function(){if(this.na)for(;this.na.length;)this.na.shift()()};function wd(b){b&&"function"==typeof b.jd&&b.jd()};function xd(b,c){this.type=b;this.g=this.target=c;this.j=!1;this.Ih=!0}xd.prototype.b=function(){this.j=!0};xd.prototype.preventDefault=function(){this.Ih=!1};function yd(b){b.b()}function zd(b){b.preventDefault()};var Ad=bd?"focusout":"DOMFocusOut";function Bd(b){Bd[" "](b);return b}Bd[" "]=ca;function Cd(b,c){xd.call(this,b?b.type:"");this.relatedTarget=this.g=this.target=null;this.v=this.i=this.button=this.screenY=this.screenX=this.clientY=this.clientX=this.offsetY=this.offsetX=0;this.u=this.c=this.f=this.B=!1;this.state=null;this.l=!1;this.a=null;if(b){var d=this.type=b.type,e=b.changedTouches?b.changedTouches[0]:null;this.target=null===e?b.target||b.srcElement:e.target;this.g=c;var f=b.relatedTarget;if(f){if(dd){var g;a:{try{Bd(f.nodeName);g=!0;break a}catch(h){}g=!1}g||(f=null)}}else"mouseover"== d?f=b.fromElement:"mouseout"==d&&(f=b.toElement);this.relatedTarget=f;null===e?(this.offsetX=ed||void 0!==b.offsetX?b.offsetX:b.layerX,this.offsetY=ed||void 0!==b.offsetY?b.offsetY:b.layerY,this.clientX=void 0!==b.clientX?b.clientX:b.pageX,this.clientY=void 0!==b.clientY?b.clientY:b.pageY,this.screenX=b.screenX||0,this.screenY=b.screenY||0):(this.clientX=void 0!==e.clientX?e.clientX:e.pageX,this.clientY=void 0!==e.clientY?e.clientY:e.pageY,this.screenX=e.screenX||0,this.screenY=e.screenY||0);this.button= b.button;this.i=b.keyCode||0;this.v=b.charCode||("keypress"==d?b.keyCode:0);this.B=b.ctrlKey;this.f=b.altKey;this.c=b.shiftKey;this.u=b.metaKey;this.l=fd?b.metaKey:b.ctrlKey;this.state=b.state;this.a=b;b.defaultPrevented&&this.preventDefault()}}x(Cd,xd);var Dd=[1,4,2];function Ed(b){return(pd?0==b.a.button:"click"==b.type?!0:!!(b.a.button&Dd[0]))&&!(ed&&fd&&b.B)}Cd.prototype.b=function(){Cd.ba.b.call(this);this.a.stopPropagation?this.a.stopPropagation():this.a.cancelBubble=!0}; Cd.prototype.preventDefault=function(){Cd.ba.preventDefault.call(this);var b=this.a;if(b.preventDefault)b.preventDefault();else if(b.returnValue=!1,rd)try{if(b.ctrlKey||112<=b.keyCode&&123>=b.keyCode)b.keyCode=-1}catch(c){}};var Fd="closure_listenable_"+(1E6*Math.random()|0);function Gd(b){return!(!b||!b[Fd])}var Hd=0;function Id(b,c,d,e,f){this.listener=b;this.a=null;this.src=c;this.type=d;this.ad=!!e;this.fe=f;this.key=++Hd;this.Tc=this.Nd=!1}function Jd(b){b.Tc=!0;b.listener=null;b.a=null;b.src=null;b.fe=null};function Kd(b){this.src=b;this.a={};this.f=0}Kd.prototype.add=function(b,c,d,e,f){var g=b.toString();b=this.a[g];b||(b=this.a[g]=[],this.f++);var h=Ld(b,c,e,f);-1f.keyCode||void 0!=f.returnValue)){a:{var g=!1;if(0==f.keyCode)try{f.keyCode=-1;break a}catch(h){g=!0}if(g||void 0==f.returnValue)f.returnValue=!0}f=[];for(g=d.g;g;g=g.parentNode)f.push(g);for(var g=b.type,k=f.length-1;!d.j&&0<=k;k--){d.g=f[k];var n=ae(f[k],g,!0,d),e=e&&n}for(k=0;!d.j&&k>>0);function Sd(b){if(ka(b))return b;b[ce]||(b[ce]=function(c){return b.handleEvent(c)});return b[ce]};function de(){sd.call(this);this.ob=new Kd(this);this.Cc=this;this.Xa=null}x(de,sd);de.prototype[Fd]=!0;l=de.prototype;l.addEventListener=function(b,c,d,e){B(this,b,c,d,e)};l.removeEventListener=function(b,c,d,e){Zd(this,b,c,d,e)}; function D(b,c){var d,e=b.Xa;if(e)for(d=[];e;e=e.Xa)d.push(e);var e=b.Cc,f=c,g=f.type||f;if(ia(f))f=new xd(f,e);else if(f instanceof xd)f.target=f.target||e;else{var h=f,f=new xd(g,e);$c(f,h)}var h=!0,k;if(d)for(var n=d.length-1;!f.j&&0<=n;n--)k=f.g=d[n],h=ee(k,g,!0,f)&&h;f.j||(k=f.g=e,h=ee(k,g,!0,f)&&h,f.j||(h=ee(k,g,!1,f)&&h));if(d)for(n=0;!f.j&&nd)for(d=1;dg?1:.5,e=Math.floor(Math.log(c/e)/Math.log(b)+g),f=Math.max(e+f,0),m(d)&&(f=Math.min(f,d)),c/Math.pow(b,f)}};function We(b){if(m(b))return 0}function Xe(b,c){if(m(b))return b+c}function Ye(b){var c=2*Math.PI/b;return function(b,e){if(m(b))return b=Math.floor((b+e)/c+.5)*c}}function $e(){var b=Lb(5);return function(c,d){if(m(c))return Math.abs(c+d)<=b?0:c+d}};function af(b,c,d){this.center=b;this.resolution=c;this.rotation=d};function bf(b,c,d,e,f,g){var h=f[0],k=f[1],n=f[4],p=f[5],q=f[12];f=f[13];for(var r=m(g)?g:[],t=0;cb||0!==this.j&&b<=this.j)return this;var c=b.toString();if(this.i.hasOwnProperty(c))return this.i[c];var d=this.Kc(b);if(d.ha().lengthf&&(f=g);g=k;h=n}return f}function mf(b,c,d,e,f){var g,h;g=0;for(h=d.length;gk){for(;cu&&(p=q,u=A)}u>f&&(n[(p-c)/e]=1,t+eQ&&VaQ)&&(0>ta&&Sta)||(w[h++]=A,w[h++]=H,C=A,y=H);A=K;H=J}}w[h++]=A;w[h++]=H}}k.push(h);c=q}return h};function wf(b,c){cf.call(this);this.g=this.l=-1;m(b)&&this.ma(b,c)}x(wf,cf);l=wf.prototype;l.clone=function(){var b=new wf(null);xf(b,this.b,this.s.slice());return b};l.fb=function(b,c,d,e){if(eg!=q>g&&f<(p-k)*(g-n)/(q-n)+k&&(h=!h);k=p;n=q}return h}function Cf(b,c,d,e,f,g){if(0===d.length||!Bf(b,c,d[0],e,f,g))return!1;var h;c=1;for(h=d.length;cr&&(p=(p+q)/2,Cf(b,c,d,e,p,t)&&(z=p,r=w));p=q}isNaN(z)&&(z=f[g]);return m(h)?(h.push(z,t),h):[z,t]};function Ef(b,c,d,e,f,g){for(var h=[b[c],b[c+1]],k=[],n;c+e=f[0]&&g[2]<=f[2]||g[1]>=f[1]&&g[3]<=f[3]?!0:Ef(b,c,d,e,function(b,c){var d=!1,e=kc(f,b),g=kc(f,c);if(1===e||1===g)d=!0;else{var r=f[0],t=f[1],u=f[2],z=f[3],w=c[0],C=c[1],y=(C-b[1])/(w-b[0]);g&2&&!(e&2)&&(d=w-(C-z)/y,d=d>=r&&d<=u);d||!(g&4)||e&4||(d=C-(w-u)*y,d=d>=t&&d<=z);d||!(g&8)||e&8||(d=w-(C-t)/y,d=d>=r&&d<=u);d||!(g&16)||e&16||(d=C-(w-r)*y,d=d>=t&&d<=z)}return d}):!1} function Gf(b,c,d,e,f){var g=d[0];if(!(Ff(b,c,g,e,f)||Bf(b,c,g,e,f[0],f[1])||Bf(b,c,g,e,f[0],f[3])||Bf(b,c,g,e,f[2],f[1])||Bf(b,c,g,e,f[2],f[3])))return!1;if(1===d.length)return!0;c=1;for(g=d.length;cb||this.g.length<=b)return null;var c=new wf(null);xf(c,this.b,this.s.slice(0===b?0:this.g[b-1],this.g[b]));return c};l.Wd=function(){var b=this.b,c=this.s,d=this.g,e=[],f=0,g,h;g=0;for(h=d.length;gthis.j)}return m(b)?this.c+b:b}; l.df=function(b,c,d){b instanceof cf||(b=Of(b));var e=m(d)?d:{};d=m(e.padding)?e.padding:[0,0,0,0];var f=m(e.constrainResolution)?e.constrainResolution:!0,g=m(e.nearest)?e.nearest:!1,h;m(e.minResolution)?h=e.minResolution:m(e.maxZoom)?h=this.constrainResolution(this.a,e.maxZoom-this.c,0):h=0;var k=b.ha(),n=this.Ba(),e=Math.cos(-n),n=Math.sin(-n),p=Infinity,q=Infinity,r=-Infinity,t=-Infinity;b=b.ta();for(var u=0,z=k.length;ub?Yf(2*b):1-Yf(2*(b-.5))};function ag(b){var c=b.source,d=m(b.start)?b.start:ua(),e=c[0],f=c[1],g=m(b.duration)?b.duration:1E3,h=m(b.easing)?b.easing:Yf;return function(b,c){if(c.time>=1;return d.join("")}function hg(b){return fg(b[0],b[1],b[2])}function ig(b,c,d){var e=b[0],f=jg(c,b);d=kg(d);if(hc(d,f))return b;b=Bc(d);d=Math.ceil((d[0]-f[0])/b);f[0]+=b*d;return c.be(f,e)} function lg(b,c){var d=b[0],e=b[1],f=b[2];if(c.minZoom>d||d>c.maxZoom)return!1;var g=c.P(),d=null===g?null===c.f?null:c.f[d]:mg(c,g,d);return null===d?!0:ng(d,e,f)};function og(b,c,d,e){this.a=b;this.c=c;this.f=d;this.b=e}og.prototype.contains=function(b){return ng(this,b[1],b[2])};function ng(b,c,d){return b.a<=c&&c<=b.c&&b.f<=d&&d<=b.b}function pg(b,c){return b.a==c.a&&b.f==c.f&&b.c==c.c&&b.b==c.b}function qg(b){return b.c-b.a+1}function rg(b,c){return b.a<=c.c&&b.c>=c.a&&b.f<=c.b&&b.b>=c.f};function sg(b){this.f=b.html;this.a=m(b.tileRanges)?b.tileRanges:null}sg.prototype.b=function(){return this.f};function tg(b,c,d){xd.call(this,b,d);this.element=c}x(tg,xd);function ug(b){je.call(this);this.a=m(b)?b:[];vg(this)}x(ug,je);l=ug.prototype;l.clear=function(){for(;0");g=g.join("")}g=f.createElement(g);h&&(ia(h)?g.className=h:ga(h)?g.className=h.join(" "):Mg(g,h));2=this.left&&b.right<=this.right&&b.top>=this.top&&b.bottom<=this.bottom:b.x>=this.left&&b.x<=this.right&&b.y>=this.top&&b.y<=this.bottom:!1}; l.ceil=function(){this.top=Math.ceil(this.top);this.right=Math.ceil(this.right);this.bottom=Math.ceil(this.bottom);this.left=Math.ceil(this.left);return this};l.floor=function(){this.top=Math.floor(this.top);this.right=Math.floor(this.right);this.bottom=Math.floor(this.bottom);this.left=Math.floor(this.left);return this};l.round=function(){this.top=Math.round(this.top);this.right=Math.round(this.right);this.bottom=Math.round(this.bottom);this.left=Math.round(this.left);return this}; l.translate=function(b,c){b instanceof Gg?(this.left+=b.x,this.right+=b.x,this.top+=b.y,this.bottom+=b.y):(this.left+=b,this.right+=b,ja(c)&&(this.top+=c,this.bottom+=c));return this};l.scale=function(b,c){var d=ja(c)?c:b;this.left*=b;this.right*=b;this.top*=d;this.bottom*=d;return this};function hh(b,c,d,e){this.left=b;this.top=c;this.width=d;this.height=e}l=hh.prototype;l.clone=function(){return new hh(this.left,this.top,this.width,this.height)};l.contains=function(b){return b instanceof hh?this.left<=b.left&&this.left+this.width>=b.left+b.width&&this.top<=b.top&&this.top+this.height>=b.top+b.height:b.x>=this.left&&b.x<=this.left+this.width&&b.y>=this.top&&b.y<=this.top+this.height}; function ih(b,c){var d=c.xb.g};function Eh(b,c){de.call(this);this.a=b;this.state=c}x(Eh,de);function Fh(b){D(b,"change")}Eh.prototype.lb=function(){return ma(this).toString()};Eh.prototype.g=function(){return this.a};function Gh(b){je.call(this);this.j=te(b.projection);this.g=m(b.attributions)?b.attributions:null;this.T=b.logo;this.u=m(b.state)?b.state:"ready";this.D=m(b.wrapX)?b.wrapX:!1}x(Gh,je);l=Gh.prototype;l.te=ca;l.pa=function(){return this.g};l.oa=function(){return this.T};l.qa=function(){return this.j};l.ra=function(){return this.u};function Hh(b){return b.D}l.la=function(b){this.g=b;this.o()};function Ih(b,c){b.u=c;b.o()};function Jh(b){this.minZoom=m(b.minZoom)?b.minZoom:0;this.a=b.resolutions;this.maxZoom=this.a.length-1;this.b=m(b.origin)?b.origin:null;this.g=null;m(b.origins)&&(this.g=b.origins);var c=b.extent;m(c)&&null===this.b&&null===this.g&&(this.b=vc(c));this.i=null;m(b.tileSizes)&&(this.i=b.tileSizes);this.l=m(b.tileSize)?b.tileSize:null===this.i?256:null;this.v=m(c)?c:null;this.f=null;m(b.sizes)?this.f=pb(b.sizes,function(b){return new og(Math.min(0,b[0]),Math.max(b[0]-1,-1),Math.min(0,b[1]),Math.max(b[1]- 1,-1))},this):null!=c&&Kh(this,c);this.c=[0,0]}var Lh=[0,0,0];function Mh(b,c,d,e,f){f=Nh(b,c,f);for(c=c[0]-1;c>=b.minZoom;){if(d.call(null,c,mg(b,f,c,e)))return!0;--c}return!1}l=Jh.prototype;l.P=function(){return this.v};l.vg=function(){return this.maxZoom};l.wg=function(){return this.minZoom};l.Qc=function(b){return null===this.b?this.g[b]:this.b};l.Ca=function(b){return this.a[b]};l.oh=function(){return this.a};function Oh(b,c,d,e){return c[0]ta.c)if(rg(Q,new og(Jb(K.a,Va),Jb(K.c,Va),K.f,K.b))||qg(K)>Va&&rg(Q,ta)){r=!0;break a}}r=!1}}}else r=!1;r?(n in z&&delete z[n],u[n]=k):z[n]=k}c=[u,z];d=c[0];c=c[1];for(var S in this.l)S in d?(this.i[S]||(rh(this.l[S],!0),this.i[S]=!0),delete d[S]):S in c?(this.i[S]&&(rh(this.l[S],!1),delete this.i[S]),delete c[S]):(Wg(this.l[S]),delete this.l[S],delete this.i[S]);for(S in d)e= Sg("LI"),e.innerHTML=d[S].f,this.D.appendChild(e),this.l[S]=e,this.i[S]=!0;for(S in c)e=Sg("LI"),e.innerHTML=c[S].f,rh(e,!1),this.D.appendChild(e),this.l[S]=e;S=!Sc(this.i)||!Sc(b.logos);this.A!=S&&(rh(this.element,S),this.A=S);S&&Sc(this.i)?dh(this.element,"ol-logo-only"):eh(this.element,"ol-logo-only");var Ia;b=b.logos;S=this.S;for(Ia in S)Ia in b||(Wg(S[Ia]),delete S[Ia]);for(var gb in b)gb in S||(Ia=new Image,Ia.src=gb,d=b[gb],""===d?d=Ia:(d=Pg("A",{href:d}),d.appendChild(Ia)),this.u.appendChild(d), S[gb]=d);rh(this.u,!Sc(b))}}l=Zh.prototype;l.Cl=function(b){b.preventDefault();ai(this)};function ai(b){fh(b.element,"ol-collapsed");b.c?Xg(b.C,b.M):Xg(b.M,b.C);b.c=!b.c}l.Bl=function(){return this.j};l.El=function(b){this.j!==b&&(this.j=b,fh(this.element,"ol-uncollapsible"),!b&&this.c&&ai(this))};l.Dl=function(b){this.j&&this.c!==b&&ai(this)};l.Al=function(){return this.c};function bi(b){b=m(b)?b:{};var c=m(b.className)?b.className:"ol-rotate",d=m(b.label)?b.label:"\u21e7";this.c=null;ia(d)?this.c=Pg("SPAN","ol-compass",d):(this.c=d,dh(this.c,"ol-compass"));d=Pg("BUTTON",{"class":c+"-reset",type:"button",title:m(b.tipLabel)?b.tipLabel:"Reset rotation"},this.c);B(d,"click",bi.prototype.u,!1,this);c=Pg("DIV",c+" ol-unselectable ol-control",d);zh.call(this,{element:c,render:m(b.render)?b.render:ci,target:b.target});this.j=m(b.duration)?b.duration:250;this.i=m(b.autoHide)? b.autoHide:!0;this.l=void 0;this.i&&dh(this.element,"ol-hidden")}x(bi,zh);bi.prototype.u=function(b){b.preventDefault();b=this.a;var c=b.$();if(null!==c){for(var d=c.Ba();d<-Math.PI;)d+=2*Math.PI;for(;d>Math.PI;)d-=2*Math.PI;m(d)&&(02*this.b&&yi(this),!0):!1};function yi(b){if(b.b!=b.a.length){for(var c=0,d=0;c=b||96<=b&&106>=b||65<=b&&90>=b||(ed||cd)&&0==b)return!0;switch(b){case 32:case 63:case 64:case 107:case 109:case 110:case 111:case 186:case 59:case 189:case 187:case 61:case 188:case 190:case 191:case 192:case 222:case 219:case 220:case 221:return!0;default:return!1}}function Ei(b){if(dd)b=Fi(b);else if(fd&&ed)a:switch(b){case 93:b=91;break a}return b} function Fi(b){switch(b){case 61:return 187;case 59:return 186;case 173:return 189;case 224:return 91;case 0:return 224;default:return b}};function Gi(b,c){de.call(this);b&&Hi(this,b,c)}x(Gi,de);l=Gi.prototype;l.qd=null;l.he=null;l.rf=null;l.ie=null;l.$a=-1;l.Tb=-1;l.We=!1; var Ii={3:13,12:144,63232:38,63233:40,63234:37,63235:39,63236:112,63237:113,63238:114,63239:115,63240:116,63241:117,63242:118,63243:119,63244:120,63245:121,63246:122,63247:123,63248:44,63272:46,63273:36,63275:35,63276:33,63277:34,63289:144,63302:45},Ji={Up:38,Down:40,Left:37,Right:39,Enter:13,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,"U+007F":46,Home:36,End:35,PageUp:33,PageDown:34,Insert:45},Ki=bd||cd||ed&&md("525"),Li=fd&ⅆ Gi.prototype.a=function(b){if(ed||cd)if(17==this.$a&&!b.B||18==this.$a&&!b.f||fd&&91==this.$a&&!b.u)this.Tb=this.$a=-1;-1==this.$a&&(b.B&&17!=b.i?this.$a=17:b.f&&18!=b.i?this.$a=18:b.u&&91!=b.i&&(this.$a=91));Ki&&!Ci(b.i,this.$a,b.c,b.B,b.f)?this.handleEvent(b):(this.Tb=Ei(b.i),Li&&(this.We=b.f))};Gi.prototype.f=function(b){this.Tb=this.$a=-1;this.We=b.f}; Gi.prototype.handleEvent=function(b){var c=b.a,d,e,f=c.altKey;bd&&"keypress"==b.type?(d=this.Tb,e=13!=d&&27!=d?c.keyCode:0):(ed||cd)&&"keypress"==b.type?(d=this.Tb,e=0<=c.charCode&&63232>c.charCode&&Di(d)?c.charCode:0):ad&&!ed?(d=this.Tb,e=Di(d)?c.keyCode:0):(d=c.keyCode||this.Tb,e=c.charCode||0,Li&&(f=this.We),fd&&63==e&&224==d&&(d=191));var g=d=Ei(d),h=c.keyIdentifier;d?63232<=d&&d in Ii?g=Ii[d]:25==d&&b.c&&(g=9):h&&h in Ji&&(g=Ji[h]);this.$a=g;b=new Mi(g,e,0,c);b.f=f;D(this,b)}; function Hi(b,c,d){b.ie&&Ni(b);b.qd=c;b.he=B(b.qd,"keypress",b,d);b.rf=B(b.qd,"keydown",b.a,d,b);b.ie=B(b.qd,"keyup",b.f,d,b)}function Ni(b){b.he&&($d(b.he),$d(b.rf),$d(b.ie),b.he=null,b.rf=null,b.ie=null);b.qd=null;b.$a=-1;b.Tb=-1}Gi.prototype.Y=function(){Gi.ba.Y.call(this);Ni(this)};function Mi(b,c,d,e){Cd.call(this,e);this.type="key";this.i=b;this.v=c}x(Mi,Cd);function Oi(b,c){de.call(this);var d=this.a=b;(d=la(d)&&1==d.nodeType?this.a:this.a?this.a.body:null)&&kh(d,"direction");this.f=B(this.a,dd?"DOMMouseScroll":"mousewheel",this,c)}x(Oi,de); Oi.prototype.handleEvent=function(b){var c=0,d=0,e=0;b=b.a;if("mousewheel"==b.type){d=1;if(bd||ed&&(gd||md("532.0")))d=40;e=Pi(-b.wheelDelta,d);m(b.wheelDeltaX)?(c=Pi(-b.wheelDeltaX,d),d=Pi(-b.wheelDeltaY,d)):d=e}else e=b.detail,100e&&(e=-3),m(b.axis)&&b.axis===b.HORIZONTAL_AXIS?c=e:d=e;ja(this.b)&&Hb(c,-this.b,this.b);ja(this.c)&&(d=Hb(d,-this.c,this.c));c=new Qi(e,b,0,d);D(this,c)};function Pi(b,c){return ed&&(fd||hd)&&0!=b%c?b:b/c} Oi.prototype.Y=function(){Oi.ba.Y.call(this);$d(this.f);this.f=null};function Qi(b,c,d,e){Cd.call(this,c);this.type="mousewheel";this.detail=b;this.A=e}x(Qi,Cd);function Ri(b,c,d){xd.call(this,b);this.a=c;b=m(d)?d:{};this.buttons=Si(b);this.pressure=Ti(b,this.buttons);this.bubbles=Vc(b,"bubbles",!1);this.cancelable=Vc(b,"cancelable",!1);this.view=Vc(b,"view",null);this.detail=Vc(b,"detail",null);this.screenX=Vc(b,"screenX",0);this.screenY=Vc(b,"screenY",0);this.clientX=Vc(b,"clientX",0);this.clientY=Vc(b,"clientY",0);this.button=Vc(b,"button",0);this.relatedTarget=Vc(b,"relatedTarget",null);this.pointerId=Vc(b,"pointerId",0);this.width=Vc(b,"width",0);this.height= Vc(b,"height",0);this.pointerType=Vc(b,"pointerType","");this.isPrimary=Vc(b,"isPrimary",!1);c.preventDefault&&(this.preventDefault=function(){c.preventDefault()})}x(Ri,xd);function Si(b){if(b.buttons||Ui)b=b.buttons;else switch(b.which){case 1:b=1;break;case 2:b=4;break;case 3:b=2;break;default:b=0}return b}function Ti(b,c){var d=0;b.pressure?d=b.pressure:d=c?.5:0;return d}var Ui=!1;try{Ui=1===(new MouseEvent("click",{buttons:1})).buttons}catch(Vi){};function Wi(b,c){var d=Sg("CANVAS");m(b)&&(d.width=b);m(c)&&(d.height=c);return d.getContext("2d")} var Xi=function(){var b;return function(){if(!m(b))if(ba.getComputedStyle){var c=Sg("P"),d,e={webkitTransform:"-webkit-transform",OTransform:"-o-transform",msTransform:"-ms-transform",MozTransform:"-moz-transform",transform:"transform"};document.body.appendChild(c);for(var f in e)f in c.style&&(c.style[f]="translate(1px,1px)",d=ba.getComputedStyle(c).getPropertyValue(e[f]));Wg(c);b=d&&"none"!==d}else b=!1;return b}}(),Yi=function(){var b;return function(){if(!m(b))if(ba.getComputedStyle){var c=Sg("P"), d,e={webkitTransform:"-webkit-transform",OTransform:"-o-transform",msTransform:"-ms-transform",MozTransform:"-moz-transform",transform:"transform"};document.body.appendChild(c);for(var f in e)f in c.style&&(c.style[f]="translate3d(1px,1px,1px)",d=ba.getComputedStyle(c).getPropertyValue(e[f]));Wg(c);b=d&&"none"!==d}else b=!1;return b}}();function Zi(b,c){var d=b.style;d.WebkitTransform=c;d.MozTransform=c;d.a=c;d.msTransform=c;d.transform=c;bd&&!ne&&(b.style.transformOrigin="0 0")} function $i(b,c){var d;if(Yi()){if(m(6)){var e=Array(16);for(d=0;16>d;++d)e[d]=c[d].toFixed(6);d=e.join(",")}else d=c.join(",");Zi(b,"matrix3d("+d+")")}else if(Xi()){e=[c[0],c[1],c[4],c[5],c[12],c[13]];if(m(6)){var f=Array(6);for(d=0;6>d;++d)f[d]=e[d].toFixed(6);d=f.join(",")}else d=e.join(",");Zi(b,"matrix("+d+")")}else b.style.left=Math.round(c[12])+"px",b.style.top=Math.round(c[13])+"px"};var aj=["experimental-webgl","webgl","webkit-3d","moz-webgl"];function bj(b,c){var d,e,f=aj.length;for(e=0;e=Math.abs(e-k[0])&&25>=n)return!0}return!1}function tj(b){var c=uj(b,b.a),d=c.preventDefault;c.preventDefault=function(){b.preventDefault();d()};c.pointerId=1;c.isPrimary=!0;c.pointerType="mouse";return c}l=rj.prototype; l.Vk=function(b){if(!sj(this,b)){(1).toString()in this.f&&this.cancel(b);var c=tj(b);this.f[(1).toString()]=b;vj(this.a,wj,c,b)}};l.Wk=function(b){if(!sj(this,b)){var c=tj(b);vj(this.a,xj,c,b)}};l.Zk=function(b){if(!sj(this,b)){var c=this.f[(1).toString()];c&&c.button===b.button&&(c=tj(b),vj(this.a,yj,c,b),Uc(this.f,(1).toString()))}};l.Yk=function(b){if(!sj(this,b)){var c=tj(b);zj(this.a,c,b)}};l.Xk=function(b){if(!sj(this,b)){var c=tj(b);Aj(this.a,c,b)}}; l.cancel=function(b){var c=tj(b);this.a.cancel(c,b);Uc(this.f,(1).toString())};function Bj(b){qj.call(this,b,{MSPointerDown:this.dl,MSPointerMove:this.el,MSPointerUp:this.hl,MSPointerOut:this.fl,MSPointerOver:this.gl,MSPointerCancel:this.cl,MSGotPointerCapture:this.al,MSLostPointerCapture:this.bl});this.f=b.f;this.b=["","unavailable","touch","pen","mouse"]}x(Bj,qj);function Cj(b,c){var d=c;ja(c.a.pointerType)&&(d=uj(c,c.a),d.pointerType=b.b[c.a.pointerType]);return d}l=Bj.prototype;l.dl=function(b){this.f[b.a.pointerId]=b;var c=Cj(this,b);vj(this.a,wj,c,b)}; l.el=function(b){var c=Cj(this,b);vj(this.a,xj,c,b)};l.hl=function(b){var c=Cj(this,b);vj(this.a,yj,c,b);Uc(this.f,b.a.pointerId)};l.fl=function(b){var c=Cj(this,b);Aj(this.a,c,b)};l.gl=function(b){var c=Cj(this,b);zj(this.a,c,b)};l.cl=function(b){var c=Cj(this,b);this.a.cancel(c,b);Uc(this.f,b.a.pointerId)};l.bl=function(b){D(this.a,new Ri("lostpointercapture",b,b.a))};l.al=function(b){D(this.a,new Ri("gotpointercapture",b,b.a))};function Dj(b){qj.call(this,b,{pointerdown:this.On,pointermove:this.Pn,pointerup:this.Sn,pointerout:this.Qn,pointerover:this.Rn,pointercancel:this.Nn,gotpointercapture:this.gk,lostpointercapture:this.Uk})}x(Dj,qj);l=Dj.prototype;l.On=function(b){Ej(this.a,b)};l.Pn=function(b){Ej(this.a,b)};l.Sn=function(b){Ej(this.a,b)};l.Qn=function(b){Ej(this.a,b)};l.Rn=function(b){Ej(this.a,b)};l.Nn=function(b){Ej(this.a,b)};l.Uk=function(b){Ej(this.a,b)};l.gk=function(b){Ej(this.a,b)};function Fj(b,c){qj.call(this,b,{touchstart:this.Xo,touchmove:this.Wo,touchend:this.Vo,touchcancel:this.Uo});this.f=b.f;this.j=c;this.b=void 0;this.i=0;this.c=void 0}x(Fj,qj);l=Fj.prototype;l.Hh=function(){this.i=0;this.c=void 0}; function Gj(b,c,d){c=uj(c,d);c.pointerId=d.identifier+2;c.bubbles=!0;c.cancelable=!0;c.detail=b.i;c.button=0;c.buttons=1;c.width=d.webkitRadiusX||d.radiusX||0;c.height=d.webkitRadiusY||d.radiusY||0;c.pressure=d.webkitForce||d.force||.5;c.isPrimary=b.b===d.identifier;c.pointerType="touch";c.clientX=d.clientX;c.clientY=d.clientY;c.screenX=d.screenX;c.screenY=d.screenY;return c} function Hj(b,c,d){function e(){c.preventDefault()}var f=Array.prototype.slice.call(c.a.changedTouches),g=f.length,h,k;for(h=0;h=c.length){var f=[],g,h,k;for(g=0;g=b.minResolution&&cb.c&&(b.c=e.c),e.fb.b&&(b.b=e.b)):b[c][d]=e:(b[c]={},b[c][d]=e)}function yk(b,c,d){return[c*(Math.round(b[0]/c)+d[0]%2/2),c*(Math.round(b[1]/c)+d[1]%2/2)]} function zk(b,c,d,e,f,g,h,k,n,p){var q=ma(c).toString();q in b.wantedTiles||(b.wantedTiles[q]={});var r=b.wantedTiles[q];b=b.tileQueue;var t=d.minZoom,u,z,w,C,y,A;for(A=h;A>=t;--A)for(z=mg(d,g,A,z),w=d.Ca(A),C=z.a;C<=z.c;++C)for(y=z.f;y<=z.b;++y)h-A<=k?(u=c.Ib(A,C,y,e,f),0==u.state&&(r[hg(u.a)]=!0,u.lb()in b.b||Ak(b,[u,q,jg(d,u.a),w])),m(n)&&n.call(p,u)):c.Yf(A,C,y)};function Bk(b){this.u=b.opacity;this.D=b.rotateWithView;this.B=b.rotation;this.v=b.scale;this.C=b.snapToPixel}l=Bk.prototype;l.ve=function(){return this.u};l.Zd=function(){return this.D};l.we=function(){return this.B};l.xe=function(){return this.v};l.ae=function(){return this.C};l.ye=function(b){this.u=b};l.ze=function(b){this.B=b};l.Ae=function(b){this.v=b};function Ck(b){b=m(b)?b:{};this.g=m(b.anchor)?b.anchor:[.5,.5];this.c=null;this.f=m(b.anchorOrigin)?b.anchorOrigin:"top-left";this.j=m(b.anchorXUnits)?b.anchorXUnits:"fraction";this.l=m(b.anchorYUnits)?b.anchorYUnits:"fraction";var c=m(b.crossOrigin)?b.crossOrigin:null,d=m(b.img)?b.img:null,e=m(b.imgSize)?b.imgSize:null,f=b.src;m(f)&&0!==f.length||null===d||(f=d.src);var g=m(b.src)?0:2,h=Dk.Za(),k=h.get(f,c);null===k&&(k=new Ek(d,f,e,c,g),h.set(f,c,k));this.a=k;this.fa=m(b.offset)?b.offset:[0,0]; this.b=m(b.offsetOrigin)?b.offsetOrigin:"top-left";this.i=null;this.A=m(b.size)?b.size:null;Bk.call(this,{opacity:m(b.opacity)?b.opacity:1,rotation:m(b.rotation)?b.rotation:0,scale:m(b.scale)?b.scale:1,snapToPixel:m(b.snapToPixel)?b.snapToPixel:!0,rotateWithView:m(b.rotateWithView)?b.rotateWithView:!1})}x(Ck,Bk);l=Ck.prototype; l.Sb=function(){if(null!==this.c)return this.c;var b=this.g,c=this.rb();if("fraction"==this.j||"fraction"==this.l){if(null===c)return null;b=this.g.slice();"fraction"==this.j&&(b[0]*=c[0]);"fraction"==this.l&&(b[1]*=c[1])}if("top-left"!=this.f){if(null===c)return null;b===this.g&&(b=this.g.slice());if("top-right"==this.f||"bottom-right"==this.f)b[0]=-b[0]+c[0];if("bottom-left"==this.f||"bottom-right"==this.f)b[1]=-b[1]+c[1]}return this.c=b};l.W=function(b){return this.a.W(b)};l.Vd=function(){return this.a.f}; l.vd=function(){return this.a.b};l.ue=function(){var b=this.a;if(null===b.g)if(b.l){var c=b.f[0],d=b.f[1],e=Wi(c,d);e.fillRect(0,0,c,d);b.g=e.canvas}else b.g=b.a;return b.g};l.$b=function(){if(null!==this.i)return this.i;var b=this.fa;if("top-left"!=this.b){var c=this.rb(),d=this.a.f;if(null===c||null===d)return null;b=b.slice();if("top-right"==this.b||"bottom-right"==this.b)b[0]=d[0]-c[0]-b[0];if("bottom-left"==this.b||"bottom-right"==this.b)b[1]=d[1]-c[1]-b[1]}return this.i=b};l.$m=function(){return this.a.i}; l.rb=function(){return null===this.A?this.a.f:this.A};l.tf=function(b,c){return B(this.a,"change",b,!1,c)};l.load=function(){this.a.load()};l.Xf=function(b,c){Zd(this.a,"change",b,!1,c)};function Ek(b,c,d,e,f){de.call(this);this.g=null;this.a=null===b?new Image:b;null!==e&&(this.a.crossOrigin=e);this.c=null;this.b=f;this.f=d;this.i=c;this.l=!1}x(Ek,de);Ek.prototype.j=function(){this.b=3;nb(this.c,$d);this.c=null;D(this,"change")}; Ek.prototype.B=function(){this.b=2;this.f=[this.a.width,this.a.height];nb(this.c,$d);this.c=null;var b=Wi(1,1);b.drawImage(this.a,0,0);try{b.getImageData(0,0,1,1)}catch(c){this.l=!0}D(this,"change")};Ek.prototype.W=function(){return this.a};Ek.prototype.load=function(){if(0==this.b){this.b=1;this.c=[Yd(this.a,"error",this.j,!1,this),Yd(this.a,"load",this.B,!1,this)];try{this.a.src=this.i}catch(b){this.j()}}};function Dk(){this.a={};this.f=0}da(Dk);Dk.prototype.clear=function(){this.a={};this.f=0}; Dk.prototype.get=function(b,c){var d=c+":"+b;return d in this.a?this.a[d]:null};Dk.prototype.set=function(b,c,d){this.a[c+":"+b]=d;++this.f};function Fk(b,c){sd.call(this);this.i=c;this.c={};this.v={}}x(Fk,sd);function Gk(b){var c=b.viewState,d=b.coordinateToPixelMatrix;ok(d,b.size[0]/2,b.size[1]/2,1/c.resolution,-1/c.resolution,-c.rotation,-c.center[0],-c.center[1]);hb(d,b.pixelToCoordinateMatrix)}l=Fk.prototype;l.Y=function(){Jc(this.c,wd);Fk.ba.Y.call(this)}; function Hk(){var b=Dk.Za();if(32h[2])k=Math.ceil((h[0]-q)/p),k=[q+p*k,b[1]]}p=c.layerStatesArray;for(q=p.length-1;0<=q;--q){h=p[q];var r=h.layer;if(!h.qb||lk(h,n)&&f.call(g,r))if(h=Ik(this,r).Ua(Hh(r.da())?k:b,c,d,e))return h}}; l.bh=function(b,c,d,e,f,g){var h,k=c.viewState.resolution,n=c.layerStatesArray,p;for(p=n.length-1;0<=p;--p){h=n[p];var q=h.layer;if(lk(h,k)&&f.call(g,q)&&(h=Ik(this,q).tc(b,c,d,e)))return h}};l.dh=function(b,c,d,e){b=this.Bf(b,c,xa,this,d,e);return m(b)};function Ik(b,c){var d=ma(c).toString();if(d in b.c)return b.c[d];var e=b.bf(c);b.c[d]=e;b.v[d]=B(e,"change",b.tk,!1,b);return e}l.tk=function(){this.i.render()};l.He=ca; l.wo=function(b,c){for(var d in this.c)if(!(null!==c&&d in c.layerStates)){var e=d,f=this.c[e];delete this.c[e];$d(this.v[e]);delete this.v[e];wd(f)}};function Jk(b,c){for(var d in b.c)if(!(d in c.layerStates)){c.postRenderFunctions.push(ra(b.wo,b));break}}function Db(b,c){return b.zIndex-c.zIndex};function Kk(b,c){this.j=b;this.g=c;this.a=[];this.f=[];this.b={}}Kk.prototype.clear=function(){this.a.length=0;this.f.length=0;Tc(this.b)};function Lk(b){var c=b.a,d=b.f,e=c[0];1==c.length?(c.length=0,d.length=0):(c[0]=c.pop(),d[0]=d.pop(),Mk(b,0));c=b.g(e);delete b.b[c];return e}function Ak(b,c){var d=b.j(c);Infinity!=d&&(b.a.push(c),b.f.push(d),b.b[b.g(c)]=!0,Nk(b,0,b.a.length-1))}Kk.prototype.nc=function(){return this.a.length};Kk.prototype.Ia=function(){return 0===this.a.length}; function Mk(b,c){for(var d=b.a,e=b.f,f=d.length,g=d[c],h=e[c],k=c;c>1;){var n=2*c+1,p=2*c+2,n=pc;){var h=d-1>>1;if(b[h]>g)e[d]=e[h],b[d]=b[h],d=h;else break}e[d]=f;b[d]=g}function Ok(b){var c=b.j,d=b.a,e=b.f,f=0,g=d.length,h,k,n;for(k=0;k>1)-1;0<=c;c--)Mk(b,c)};function Pk(b,c){Kk.call(this,function(c){return b.apply(null,c)},function(b){return b[0].lb()});this.l=c;this.c=0}x(Pk,Kk);Pk.prototype.i=function(b){b=b.target;var c=b.state;if(2===c||3===c||4===c)Zd(b,"change",this.i,!1,this),--this.c,this.l()};function Qk(b,c,d){for(var e=0,f;b.cd.a.length)d=!1;else{var e=ua()-d.i,f=d.a.length-3;if(d.a[f+2]e;)g-=3;var e=d.a[f+2]-d.a[g+2],h=d.a[f]-d.a[g],f=d.a[f+1]-d.a[g+1];d.g=Math.atan2(f,h);d.f=Math.sqrt(h*h+f*f)/e;d=d.f>d.b}}d&&(d=this.a,d=(d.b-d.f)/d.c,f=this.a.g,g=c.Oa(),this.j=Sk(this.a,g),b.Ka(this.j),g=b.La(g),d=b.Da([g[0]-d*Math.cos(f),g[1]-d*Math.sin(f)]),d=c.Pd(d),c.bb(d));Wf(c,-1);b.render(); return!1}this.c=null;return!0}function kl(b){if(0f;++f)e[f]=c.charCodeAt(d++)|c.charCodeAt(d++)<<8|c.charCodeAt(d++)<<16|c.charCodeAt(d++)<<24;else for(f=0;16>f;++f)e[f]=c[d++]|c[d++]<<8|c[d++]<<16|c[d++]<<24;c=b.a[0];d=b.a[1];var f=b.a[2],g=b.a[3],h=0,h=c+(g^d&(f^g))+e[0]+3614090360&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[1]+3905402710&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+(d^g&(c^d))+e[2]+606105819&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^ c))+e[3]+3250441966&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(g^d&(f^g))+e[4]+4118548399&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[5]+1200080426&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+(d^g&(c^d))+e[6]+2821735955&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^c))+e[7]+4249261313&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(g^d&(f^g))+e[8]+1770035416&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[9]+2336552879&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+ (d^g&(c^d))+e[10]+4294925233&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^c))+e[11]+2304563134&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(g^d&(f^g))+e[12]+1804603682&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[13]+4254626195&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+(d^g&(c^d))+e[14]+2792965006&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^c))+e[15]+1236535329&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(f^g&(d^f))+e[1]+4129170786&4294967295;c=d+(h<<5&4294967295| h>>>27);h=g+(d^f&(c^d))+e[6]+3225465664&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[11]+643717713&4294967295;f=g+(h<<14&4294967295|h>>>18);h=d+(g^c&(f^g))+e[0]+3921069994&4294967295;d=f+(h<<20&4294967295|h>>>12);h=c+(f^g&(d^f))+e[5]+3593408605&4294967295;c=d+(h<<5&4294967295|h>>>27);h=g+(d^f&(c^d))+e[10]+38016083&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[15]+3634488961&4294967295;f=g+(h<<14&4294967295|h>>>18);h=d+(g^c&(f^g))+e[4]+3889429448&4294967295;d=f+(h<<20&4294967295| h>>>12);h=c+(f^g&(d^f))+e[9]+568446438&4294967295;c=d+(h<<5&4294967295|h>>>27);h=g+(d^f&(c^d))+e[14]+3275163606&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[3]+4107603335&4294967295;f=g+(h<<14&4294967295|h>>>18);h=d+(g^c&(f^g))+e[8]+1163531501&4294967295;d=f+(h<<20&4294967295|h>>>12);h=c+(f^g&(d^f))+e[13]+2850285829&4294967295;c=d+(h<<5&4294967295|h>>>27);h=g+(d^f&(c^d))+e[2]+4243563512&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[7]+1735328473&4294967295;f=g+(h<<14&4294967295| h>>>18);h=d+(g^c&(f^g))+e[12]+2368359562&4294967295;d=f+(h<<20&4294967295|h>>>12);h=c+(d^f^g)+e[5]+4294588738&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[8]+2272392833&4294967295;g=c+(h<<11&4294967295|h>>>21);h=f+(g^c^d)+e[11]+1839030562&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[14]+4259657740&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(d^f^g)+e[1]+2763975236&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[4]+1272893353&4294967295;g=c+(h<<11&4294967295|h>>>21);h=f+(g^ c^d)+e[7]+4139469664&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[10]+3200236656&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(d^f^g)+e[13]+681279174&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[0]+3936430074&4294967295;g=c+(h<<11&4294967295|h>>>21);h=f+(g^c^d)+e[3]+3572445317&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[6]+76029189&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(d^f^g)+e[9]+3654602809&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[12]+3873151461&4294967295; g=c+(h<<11&4294967295|h>>>21);h=f+(g^c^d)+e[15]+530742520&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[2]+3299628645&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(f^(d|~g))+e[0]+4096336452&4294967295;c=d+(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[7]+1126891415&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[14]+2878612391&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[5]+4237533241&4294967295;d=f+(h<<21&4294967295|h>>>11);h=c+(f^(d|~g))+e[12]+1700485571&4294967295;c=d+ (h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[3]+2399980690&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[10]+4293915773&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[1]+2240044497&4294967295;d=f+(h<<21&4294967295|h>>>11);h=c+(f^(d|~g))+e[8]+1873313359&4294967295;c=d+(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[15]+4264355552&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[6]+2734768916&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[13]+1309151649&4294967295; d=f+(h<<21&4294967295|h>>>11);h=c+(f^(d|~g))+e[4]+4149444226&4294967295;c=d+(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[11]+3174756917&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[2]+718787259&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[9]+3951481745&4294967295;b.a[0]=b.a[0]+c&4294967295;b.a[1]=b.a[1]+(f+(h<<21&4294967295|h>>>11))&4294967295;b.a[2]=b.a[2]+f&4294967295;b.a[3]=b.a[3]+g&4294967295} function Dl(b,c){var d;m(d)||(d=c.length);for(var e=d-b.f,f=b.g,g=b.b,h=0;hc.b?c.f:2*c.f)-c.b);b[0]=128;for(var d=1;dd;++d)for(var f=0;32>f;f+=8)b[e++]=c.a[d]>>>f&255;if(8192>= b.length)c=String.fromCharCode.apply(null,b);else for(c="",d=0;dthis.D&&(this.a=!0));this.j=d;b=b.map;d=oh(b.a);e=il(this.i);e[0]-=d.x;e[1]-=d.y;this.c=b.Da(e);this.a&&(d=b.$(),e=d.Ba(),b.render(),Vk(b,d,e+c,this.c))}function $l(b){if(2>this.i.length){b=b.map;var c=b.$();Wf(c,-1);if(this.a){var d=c.Ba(),e=this.c,f=this.u,d=c.constrainRotation(d,0);Vk(b,c,d,e,f)}return!1}return!0} function Yl(b){return 2<=this.i.length?(b=b.map,this.c=null,this.j=void 0,this.a=!1,this.l=0,this.A||Wf(b.$(),1),b.render(),!0):!1}Xl.prototype.zc=wa;function am(b){gl.call(this,{handleDownEvent:bm,handleDragEvent:cm,handleUpEvent:dm});b=m(b)?b:{};this.c=null;this.l=m(b.duration)?b.duration:400;this.a=void 0;this.j=1}x(am,gl);function cm(b){var c=1,d=this.i[0],e=this.i[1],f=d.clientX-e.clientX,d=d.clientY-e.clientY,f=Math.sqrt(f*f+d*d);m(this.a)&&(c=this.a/f);this.a=f;1!=c&&(this.j=c);b=b.map;var f=b.$(),d=f.ya(),e=oh(b.a),g=il(this.i);g[0]-=e.x;g[1]-=e.y;this.c=b.Da(g);b.render();Xk(b,f,d*c,this.c)} function dm(b){if(2>this.i.length){b=b.map;var c=b.$();Wf(c,-1);var d=c.ya(),e=this.c,f=this.l,d=c.constrainResolution(d,0,this.j-1);Xk(b,c,d,e,f);return!1}return!0}function bm(b){return 2<=this.i.length?(b=b.map,this.c=null,this.a=void 0,this.j=1,this.A||Wf(b.$(),1),b.render(),!0):!1}am.prototype.zc=wa;function em(b){b=m(b)?b:{};var c=new ug,d=new Rk(-.005,.05,100);(m(b.altShiftDragRotate)?b.altShiftDragRotate:1)&&c.push(new nl);(m(b.doubleClickZoom)?b.doubleClickZoom:1)&&c.push(new Yk({delta:b.zoomDelta,duration:b.zoomDuration}));(m(b.dragPan)?b.dragPan:1)&&c.push(new jl({kinetic:d}));(m(b.pinchRotate)?b.pinchRotate:1)&&c.push(new Xl);(m(b.pinchZoom)?b.pinchZoom:1)&&c.push(new am({duration:b.zoomDuration}));if(m(b.keyboard)?b.keyboard:1)c.push(new Rl),c.push(new Tl({delta:b.zoomDelta,duration:b.zoomDuration})); (m(b.mouseWheelZoom)?b.mouseWheelZoom:1)&&c.push(new Vl({duration:b.zoomDuration}));(m(b.shiftDragZoom)?b.shiftDragZoom:1)&&c.push(new Ql);return c};function I(b){var c=m(b)?b:{};b=Xc(c);delete b.layers;c=c.layers;F.call(this,b);this.b=[];this.a={};B(this,le("layers"),this.vk,!1,this);null!=c?ga(c)&&(c=new ug(c.slice())):c=new ug;this.Zg(c)}x(I,F);l=I.prototype;l.de=function(){this.jb()&&this.o()}; l.vk=function(){nb(this.b,$d);this.b.length=0;var b=this.Nc();this.b.push(B(b,"add",this.uk,!1,this),B(b,"remove",this.wk,!1,this));Jc(this.a,function(b){nb(b,$d)});Tc(this.a);var b=b.a,c,d,e;c=0;for(d=b.length;cthis.g&&(this.g=this.b.lineWidth,this.c=null)}; function Rm(b,c,d){Hm.call(this,b,c,d);this.b={og:void 0,hd:void 0,cd:void 0,dd:null,ed:void 0,fd:void 0,gd:void 0,fillStyle:void 0,strokeStyle:void 0,lineCap:void 0,lineDash:null,lineJoin:void 0,lineWidth:void 0,miterLimit:void 0};this.i=!1}x(Rm,Hm); function Sm(b,c,d,e,f){var g=b.b,h=[1];b.f.push(h);b.a.push(h);var k,h=0;for(k=e.length;hthis.g&&(this.g=d.lineWidth,this.c=null))}; function Tm(b){var c=b.b,d=c.fillStyle,e=c.strokeStyle,f=c.lineCap,g=c.lineDash,h=c.lineJoin,k=c.lineWidth,n=c.miterLimit;m(d)&&c.og!=d&&(b.f.push([9,d]),c.og=c.fillStyle);!m(e)||c.hd==e&&c.cd==f&&c.dd==g&&c.ed==h&&c.fd==k&&c.gd==n||(b.f.push([10,e,k,f,h,n,g]),c.hd=e,c.cd=f,c.dd=g,c.ed=h,c.fd=k,c.gd=n)}function Um(b,c,d){Hm.call(this,b,c,d);this.fa=this.C=this.D=null;this.l="";this.A=this.u=this.v=this.B=0;this.j=this.i=this.b=null}x(Um,Hm); Um.prototype.xb=function(b,c,d,e,f,g){if(""!==this.l&&null!==this.j&&(null!==this.b||null!==this.i)){if(null!==this.b){f=this.b;var h=this.D;if(null===h||h.fillStyle!=f.fillStyle){var k=[9,f.fillStyle];this.f.push(k);this.a.push(k);null===h?this.D={fillStyle:f.fillStyle}:h.fillStyle=f.fillStyle}}null!==this.i&&(f=this.i,h=this.C,null===h||h.lineCap!=f.lineCap||h.lineDash!=f.lineDash||h.lineJoin!=f.lineJoin||h.lineWidth!=f.lineWidth||h.miterLimit!=f.miterLimit||h.strokeStyle!=f.strokeStyle)&&(k=[10, f.strokeStyle,f.lineWidth,f.lineCap,f.lineJoin,f.miterLimit,f.lineDash,!1],this.f.push(k),this.a.push(k),null===h?this.C={lineCap:f.lineCap,lineDash:f.lineDash,lineJoin:f.lineJoin,lineWidth:f.lineWidth,miterLimit:f.miterLimit,strokeStyle:f.strokeStyle}:(h.lineCap=f.lineCap,h.lineDash=f.lineDash,h.lineJoin=f.lineJoin,h.lineWidth=f.lineWidth,h.miterLimit=f.miterLimit,h.strokeStyle=f.strokeStyle));f=this.j;h=this.fa;if(null===h||h.font!=f.font||h.textAlign!=f.textAlign||h.textBaseline!=f.textBaseline)k= [11,f.font,f.textAlign,f.textBaseline],this.f.push(k),this.a.push(k),null===h?this.fa={font:f.font,textAlign:f.textAlign,textBaseline:f.textBaseline}:(h.font=f.font,h.textAlign=f.textAlign,h.textBaseline=f.textBaseline);Jm(this,g);f=this.coordinates.length;b=Im(this,b,c,d,e,!1);b=[5,f,b,this.l,this.B,this.v,this.u,this.A,null!==this.b,null!==this.i];this.f.push(b);this.a.push(b);Mm(this,g)}}; Um.prototype.Qa=function(b){if(null===b)this.l="";else{var c=b.a;null===c?this.b=null:(c=c.a,c=Bg(null===c?Fl:c),null===this.b?this.b={fillStyle:c}:this.b.fillStyle=c);var d=b.i;if(null===d)this.i=null;else{var c=d.a,e=d.c,f=d.b,g=d.g,h=d.f,d=d.i,e=m(e)?e:"round",f=null!=f?f.slice():Gl,g=m(g)?g:"round",h=m(h)?h:1,d=m(d)?d:10,c=Bg(null===c?Hl:c);if(null===this.i)this.i={lineCap:e,lineDash:f,lineJoin:g,lineWidth:h,miterLimit:d,strokeStyle:c};else{var k=this.i;k.lineCap=e;k.lineDash=f;k.lineJoin=g;k.lineWidth= h;k.miterLimit=d;k.strokeStyle=c}}var n=b.c,c=b.B,e=b.v,f=b.g,h=b.f,d=b.b,g=b.j,k=b.l;b=m(n)?n:"10px sans-serif";g=m(g)?g:"center";k=m(k)?k:"middle";null===this.j?this.j={font:b,textAlign:g,textBaseline:k}:(n=this.j,n.font=b,n.textAlign=g,n.textBaseline=k);this.l=m(d)?d:"";this.B=m(c)?c:0;this.v=m(e)?e:0;this.u=m(f)?f:0;this.A=m(h)?h:1}};function Vm(b,c,d,e,f){this.v=b;this.g=c;this.B=d;this.i=e;this.f={};this.j=Wi(1,1);this.l=$a();this.u=m(f)?f:!1} function Wm(b){for(var c in b.f){var d=b.f[c],e;for(e in d)d[e].re()}}Vm.prototype.c=function(b,c,d,e,f){var g=this.l;ok(g,.5,.5,1/c,-1/c,-d,-b[0],-b[1]);var h=this.j;h.clearRect(0,0,1,1);var k;m(this.i)&&(k=ac(),bc(k,b),ec(k,c*this.i,k));return Xm(this,h,g,d,e,function(b){if(0=c[0]||b[1]<=c[1]&&b[3]>=c[1]?!0:rc(b,this.af,this)):!1}; l.Ll=function(b){var c=this.a,d=this.s[c]-this.s[0],e=b.slice();e[c]=e[0]+d;for(d=1;db||0!==this.j&&b>1,q=h(d,g[p]),0t?(d=(d-g[-t-2])/(g[-t-1]-g[-t-2]),c+=(-t-2)*e,g=Kb(b[c],b[c+e],d),h=Kb(b[c+1],b[c+e+1],d)):(g=b[c+t*e],h=b[c+t*e+1])}return null!=f? (f[0]=g,f[1]=h,f):[g,h]}function fn(b,c,d,e,f,g){if(d==c)return null;if(f>1,fb||this.g.length<=b)return null;var c=new P(null);hn(c,this.b,this.s.slice(0===b?0:this.g[b-1],this.g[b]));return c};l.od=function(){var b=this.s,c=this.g,d=this.b,e=[],f=0,g,h;g=0;for(h=c.length;gb||c<=b)return null;c=new yf(null);zf(c,this.b,this.s.slice(b*this.a,(b+1)*this.a));return c};l.qe=function(){var b=this.s,c=this.b,d=this.a,e=[],f,g;f=0;for(g=b.length;fb||this.g.length<=b)return null;var c;0===b?c=0:(c=this.g[b-1],c=c[c.length-1]);b=this.g[b].slice();var d=b[b.length-1];if(0!==c){var e,f;e=0;for(f=b.length;ed?b[1]="?":d==c.length-1&&(b[1]=void 0)}return b.join("")} function wo(b,c,d){if(ga(c))for(var e=0;e=b[0]&&c[3]>=b[1]}function r(b,c,d,e,f){for(var g=[c,d],h;g.length;)d=g.pop(),c=g.pop(),d-c<=e||(h=c+Math.ceil((d-c)/e/2)*e,t(b,c,d,h,f),g.push(c,h,h,d))}function t(b,c,d,e,f){for(var g,h,k,n,p;d>c;){600h-g/2?-1:1),k=Math.max(c,Math.floor(e-h*n/g+p)),h=Math.min(d,Math.floor(e+(g-h)*n/g+p)),t(b,k,h,e,f));g=b[e];h=c;n=d;u(b,c,e);for(0f(b[h],g);)h++;for(;0this.Ve)this.Vi(e,c),c--;else break;this.Ji(d,e,c)},Vi:function(b,c){var e=b[c],f=e.children.length,g=this.hg;this.Ki(e,g,f);f={children:e.children.splice(this.Li(e,g,f)),height:e.height};e.Ma&&(f.Ma=!0);d(e,this.Wa);d(f,this.Wa);c?b[c-1].children.push(f):this.jg(e, f)},jg:function(b,c){this.data={children:[b,c],height:b.height+1};d(this.data,this.Wa)},Li:function(b,c,d){var f,g,h,n,p,q,r;p=q=Infinity;for(f=c;f<=d-c;f++){g=e(b,0,f,this.Wa);h=e(b,f,d,this.Wa);var t=g,u=h;n=Math.max(t[0],u[0]);var Ia=Math.max(t[1],u[1]),gb=Math.min(t[2],u[2]),t=Math.min(t[3],u[3]);n=Math.max(0,gb-n)*Math.max(0,t-Ia);g=k(g)+k(h);n=c;q--)r=b.children[q],f(k,b.Ma?g(r):r.bbox),p+=n(k);return p},Ji:function(b,c,d){for(;0<=d;d--)f(c[d].bbox,b)},Ni:function(b){for(var c=b.length-1,e;0<=c;c--)0===b[c].children.length?0C||this.b[1]>y)?(A.width=C,A.height=y,this.b=[C,y],this.B=!Fm(this.b),this.c=null):(C=this.b[0],y=this.b[1],(A=p!=this.A)||(A=this.c,A=!(A.a<=w.a&&w.c<=A.c&&A.f<=w.f&&w.b<=A.b)),A&&(this.c=null)));var K,J;null===this.c?(C/=q[0],y/=q[1],K=w.a-Math.floor((C-qg(w))/2),J=w.f-Math.floor((y-(w.b-w.f+1))/2),this.A=p,this.C=q[0],this.D=q[1],this.c=new og(K,K+C-1,J,J+y-1),this.l=Array(C*y),y=this.c):(y=this.c,C=qg(y));A={};A[p]={};var Q=[],ta= this.bd(h,A),Va=g.b(),S=ac(),Ia=new og(0,0,0,0),gb,Qa,Ib;for(J=w.a;J<=w.c;++J)for(Ib=w.f;Ib<=w.b;++Ib)Qa=h.Ib(p,J,Ib,d,f),K=Qa.state,2==K||4==K||3==K&&!Va?A[p][hg(Qa.a)]=Qa:(gb=Mh(k,Qa.a,ta,Ia,S),gb||(Q.push(Qa),gb=Oh(k,Qa.a,Ia,S),null===gb||ta(p+1,gb)));ta=0;for(gb=Q.length;tan[2];)++p,q=k*p,q=Dm(this,b,q),r.b(t,f,q,h,g),c-=k;q=Dm(this,b,0)}t!=d&&(Cm(this,"render",t,b,q),d.drawImage(t.canvas,0,0));t.globalAlpha=u}Cm(this,"postcompose",d,b,q)};aq.prototype.Ua=function(b,c,d,e){if(null!==this.b){var f=c.viewState.resolution,g=c.viewState.rotation,h=this.a,k=c.layerStates[ma(h)],n={};return this.b.c(b,f,g,k.qb?c.skippedFeatureUids:{},function(b){var c=ma(b).toString();if(!(c in n))return n[c]=!0,d.call(e,b,h)})}};aq.prototype.u=function(){sk(this)}; aq.prototype.ud=function(b){function c(b){var c;m(b.Ta())?c=b.Ta().call(b,p):m(d.a)&&(c=(0,d.a)(b,p));if(null!=c){if(null!=c){var e,f,g=!1;e=0;for(f=c.length;eQ&&Vg(this.target,w.target,0)}else{if(!b.viewHints[0]&&!b.viewHints[1]){H=mg(w.c,t,w.b[0],y);Q=[];A=J=void 0;for(A in w.f)J=w.f[A],H.contains(J.a)|| Q.push(J);Va=H=void 0;H=0;for(Va=Q.length;H=k;){n=b.b[p];u=b.v[p];C=ma(u).toString();if(C=!m(r[C]))C=null!=u.V();if(C&&(!m(z)||Ac(z,u.V().P()))&&(w.clear(w.COLOR_BUFFER_BIT|w.DEPTH_BUFFER_BIT),w.drawElements(4,q-n,f,n*c),q=t(u))){b=q;break a}q=n;p--}b=void 0}else w.clear(w.COLOR_BUFFER_BIT|w.DEPTH_BUFFER_BIT),Uq(b,w,c,r,b.j,b.i),b=(b=t(null))?b:void 0;H=b}else Uq(b,w,c,r,b.eb,b.A);w.disableVertexAttribArray(y.c);w.disableVertexAttribArray(y.a);w.disableVertexAttribArray(y.g); w.disableVertexAttribArray(y.f);w.disableVertexAttribArray(y.b);return H} function Uq(b,c,d,e,f,g){var h=d.b?5125:5123;d=d.b?4:2;if(Sc(e)){var k;b=0;e=f.length;for(k=0;bc[0]|| c[0]>f[0]||0>c[1]||c[1]>f[1])&&(null===this.j&&(this.j=Wi(1,1)),this.j.clearRect(0,0,1,1),this.j.drawImage(this.c.W(),c[0],c[1],1,1,0,0,1,1),0e?c[0]=e-d:0>f&&(c[0]=Math.abs(f)+ d),0>g?c[1]=g-d:0>h&&(c[1]=Math.abs(h)+d),0===c[0]&&0===c[1])||(d=b.$().Oa(),e=b.La(d),c=[e[0]+c[0],e[1]+c[1]],null!==this.g&&(this.g.source=d,b.Ka(ag(this.g))),b.$().bb(b.Da(c)))}}};l.Fk=function(){Br(this)};l.Mh=function(b){this.set("element",b)};l.setMap=function(b){this.set("map",b)};l.Rh=function(b){this.set("offset",b)};l.yf=function(b){this.set("position",b)}; function Cr(b,c){var d=Kg(b),e=new Gg(0,0),f;f=d?Kg(d):document;f=!bd||9<=od||$g(Ig(f))?f.documentElement:f.body;b!=f&&(f=nh(b),d=ah(Ig(d)),e.x=f.left+d.x,e.y=f.top+d.y);return[e.x,e.y,e.x+c[0],e.y+c[1]]}l.Sh=function(b){this.set("positioning",b)};function Dr(b,c){b.a.visible!==c&&(rh(b.b,c),b.a.visible=c)} function Br(b){var c=b.oe(),d=b.Rg();if(m(c)&&null!==c.b&&m(d)){var d=c.La(d),e=c.Na(),c=b.b.style,f=b.xg(),g=b.yg(),h=f[0],f=f[1];if("bottom-right"==g||"center-right"==g||"top-right"==g)""!==b.a.ke&&(b.a.ke=c.left=""),h=Math.round(e[0]-d[0]-h)+"px",b.a.Ie!=h&&(b.a.Ie=c.right=h);else{""!==b.a.Ie&&(b.a.Ie=c.right="");if("bottom-center"==g||"center-center"==g||"top-center"==g)h-=ph(b.b).width/2;h=Math.round(d[0]+h)+"px";b.a.ke!=h&&(b.a.ke=c.left=h)}if("bottom-left"==g||"bottom-center"==g||"bottom-right"== g)""!==b.a.Je&&(b.a.Je=c.top=""),d=Math.round(e[1]-d[1]-f)+"px",b.a.Md!=d&&(b.a.Md=c.bottom=d);else{""!==b.a.Md&&(b.a.Md=c.bottom="");if("center-left"==g||"center-center"==g||"center-right"==g)f-=ph(b.b).height/2;d=Math.round(d[1]+f)+"px";b.a.Je!=d&&(b.a.Je=c.top=d)}Dr(b,!0)}else Dr(b,!1)};function Er(b){b=m(b)?b:{};this.i=m(b.collapsed)?b.collapsed:!0;this.j=m(b.collapsible)?b.collapsible:!0;this.j||(this.i=!1);var c=m(b.className)?b.className:"ol-overviewmap",d=m(b.tipLabel)?b.tipLabel:"Overview map",e=m(b.collapseLabel)?b.collapseLabel:"\u00ab";this.u=ia(e)?Pg("SPAN",{},e):e;e=m(b.label)?b.label:"\u00bb";this.A=ia(e)?Pg("SPAN",{},e):e;d=Pg("BUTTON",{type:"button",title:d},this.j&&!this.i?this.u:this.A);B(d,"click",this.Il,!1,this);var e=Pg("DIV","ol-overviewmap-map"),f=this.c=new X({controls:new ug, interactions:new ug,target:e});m(b.layers)&&b.layers.forEach(function(b){f.kg(b)},this);var g=Pg("DIV","ol-overviewmap-box");this.l=new Ar({position:[0,0],positioning:"bottom-left",element:g});this.c.lg(this.l);c=Pg("DIV",c+" ol-unselectable ol-control"+(this.i&&this.j?" ol-collapsed":"")+(this.j?"":" ol-uncollapsible"),e,d);zh.call(this,{element:c,render:m(b.render)?b.render:Fr,target:b.target})}x(Er,zh);l=Er.prototype; l.setMap=function(b){var c=this.a;b!==c&&(c&&(c=c.$())&&Zd(c,le("rotation"),this.ee,!1,this),Er.ba.setMap.call(this,b),b&&(this.v.push(B(b,"propertychange",this.yk,!1,this)),0===this.c.Qg().Ub()&&this.c.Ph(b.oc()),b=b.$()))&&(B(b,le("rotation"),this.ee,!1,this),Vf(b)&&(this.c.Uc(),Gr(this)))};l.yk=function(b){"view"===b.key&&((b=b.oldValue)&&Zd(b,le("rotation"),this.ee,!1,this),b=this.a.$(),B(b,le("rotation"),this.ee,!1,this))};l.ee=function(){this.c.$().pe(this.a.$().Ba())}; function Fr(){var b=this.a,c=this.c;if(null!==b.b&&null!==c.b){var d=b.Na(),b=b.$().Zc(d),e=c.Na(),d=c.$().Zc(e),f=c.La(vc(b)),c=c.La(tc(b)),c=new Hg(Math.abs(f[0]-c[0]),Math.abs(f[1]-c[1])),f=e[0],e=e[1];c.width<.1*f||c.height<.1*e||c.width>.75*f||c.height>.75*e?Gr(this):jc(d,b)||(b=this.c,d=this.a.$(),b.$().bb(d.Oa()))}Hr(this)}function Gr(b){var c=b.a;b=b.c;var d=c.Na(),c=c.$().Zc(d),d=b.Na();b=b.$();var e=Math.log(7.5)/Math.LN2;Dc(c,1/(.1*Math.pow(2,e/2)));b.df(c,d)} function Hr(b){var c=b.a,d=b.c;if(null!==c.b&&null!==d.b){var e=c.Na(),f=c.$(),g=d.$();d.Na();var c=f.Ba(),h=b.l,d=b.l.ne(),f=f.Zc(e),e=g.ya(),g=sc(f),f=uc(f),k;b=b.a.$().Oa();m(b)&&(k=[g[0]-b[0],g[1]-b[1]],Tb(k,c),Ob(k,b));h.yf(k);null!=d&&(k=new Hg(Math.abs((g[0]-f[0])/e),Math.abs((f[1]-g[1])/e)),c=$g(Ig(Kg(d))),!bd||md("10")||c&&md("8")?(d=d.style,dd?d.MozBoxSizing="border-box":ed?d.WebkitBoxSizing="border-box":d.boxSizing="border-box",d.width=Math.max(k.width,0)+"px",d.height=Math.max(k.height, 0)+"px"):(b=d.style,c?(c=uh(d,"padding"),d=xh(d),b.pixelWidth=k.width-d.left-c.left-c.right-d.right,b.pixelHeight=k.height-d.top-c.top-c.bottom-d.bottom):(b.pixelWidth=k.width,b.pixelHeight=k.height)))}}l.Il=function(b){b.preventDefault();Ir(this)};function Ir(b){fh(b.element,"ol-collapsed");b.i?Xg(b.u,b.A):Xg(b.A,b.u);b.i=!b.i;var c=b.c;b.i||null!==c.b||(c.Uc(),Gr(b),Yd(c,"postrender",function(){Hr(this)},!1,b))}l.Hl=function(){return this.j}; l.Kl=function(b){this.j!==b&&(this.j=b,fh(this.element,"ol-uncollapsible"),!b&&this.i&&Ir(this))};l.Jl=function(b){this.j&&this.i!==b&&Ir(this)};l.Gl=function(){return this.i};function Jr(b){b=m(b)?b:{};var c=m(b.className)?b.className:"ol-scale-line";this.l=Pg("DIV",c+"-inner");this.j=Pg("DIV",c+" ol-unselectable",this.l);this.A=null;this.u=m(b.minWidth)?b.minWidth:64;this.c=!1;this.M=void 0;this.D="";this.i=null;zh.call(this,{element:this.j,render:m(b.render)?b.render:Kr,target:b.target});B(this,le("units"),this.Z,!1,this);this.S(b.units||"metric")}x(Jr,zh);var Lr=[1,2,5];Jr.prototype.C=function(){return this.get("units")}; function Kr(b){b=b.frameState;null===b?this.A=null:this.A=b.viewState;Mr(this)}Jr.prototype.Z=function(){Mr(this)};Jr.prototype.S=function(b){this.set("units",b)}; function Mr(b){var c=b.A;if(null===c)b.c&&(rh(b.j,!1),b.c=!1);else{var d=c.center,e=c.projection,c=e.getPointResolution(c.resolution,d),f=e.f,g=b.C();"degrees"!=f||"metric"!=g&&"imperial"!=g&&"us"!=g&&"nautical"!=g?"degrees"!=f&&"degrees"==g?(null===b.i&&(b.i=xe(e,te("EPSG:4326"))),d=Math.cos(Lb(b.i(d)[1])),e=pe.radius,e/=qe[f],c*=180/(Math.PI*d*e)):b.i=null:(b.i=null,d=Math.cos(Lb(d[1])),c*=Math.PI*d*pe.radius/180);d=b.u*c;f="";"degrees"==g?d<1/60?(f="\u2033",c*=3600):1>d?(f="\u2032",c*=60):f="\u00b0": "imperial"==g?.9144>d?(f="in",c/=.0254):1609.344>d?(f="ft",c/=.3048):(f="mi",c/=1609.344):"nautical"==g?(c/=1852,f="nm"):"metric"==g?1>d?(f="mm",c*=1E3):1E3>d?f="m":(f="km",c/=1E3):"us"==g&&(.9144>d?(f="in",c*=39.37):1609.344>d?(f="ft",c/=.30480061):(f="mi",c/=1609.3472));for(d=3*Math.floor(Math.log(b.u*c)/Math.log(10));;){e=Lr[d%3]*Math.pow(10,Math.floor(d/3));g=Math.round(e/c);if(isNaN(g)){rh(b.j,!1);b.c=!1;return}if(g>=b.u)break;++d}c=e+" "+f;b.D!=c&&(b.l.innerHTML=c,b.D=c);b.M!=g&&(b.l.style.width= g+"px",b.M=g);b.c||(rh(b.j,!0),b.c=!0)}};function Nr(b){sd.call(this);this.f=b;this.a={}}x(Nr,sd);var Or=[];Nr.prototype.ab=function(b,c,d,e){ga(c)||(c&&(Or[0]=c.toString()),c=Or);for(var f=0;fd.height?(this.j=1,d=new hh(0,0,e,0)):(this.j=Yr,d=new hh(0,0,0,c));this.c.a=d||new hh(NaN,NaN,NaN,NaN);this.A=!0}b=b.frameState.viewState.resolution;b!==this.i&&(this.i=b,b=1-Tf(this.a.$())(b),d=this.c,c=Yg(this.element),1==this.j?lh(c,d.a.left+d.a.width*b):lh(c, d.a.left,d.a.top+d.a.height*b))}}l.hk=function(b){var c=this.a,d=c.$(),e=d.ya();c.Ka(cg({resolution:e,duration:this.u,easing:Xf}));b=$r(this,b.offsetX-this.l[0]/2,b.offsetY-this.l[1]/2);b=as(this,b);d.Nb(d.constrainResolution(b))};l.kk=function(){Wf(this.a.$(),1)};l.ik=function(b){b=$r(this,b.left,b.top);this.i=as(this,b);this.a.$().Nb(this.i)};l.jk=function(){var b=this.a,c=b.$();Wf(c,-1);b.Ka(cg({resolution:this.i,duration:this.u,easing:Xf}));b=c.constrainResolution(this.i);c.Nb(b)}; function $r(b,c,d){var e=b.c.a;return Hb(1===b.j?(c-e.left)/e.width:(d-e.top)/e.height,0,1)}function as(b,c){return Sf(b.a.$())(1-c)};function bs(b){b=m(b)?b:{};this.c=m(b.extent)?b.extent:null;var c=m(b.className)?b.className:"ol-zoom-extent",d=Pg("BUTTON",{type:"button",title:m(b.tipLabel)?b.tipLabel:"Fit to extent"},m(b.label)?b.label:"E");B(d,"click",this.i,!1,this);c=Pg("DIV",c+" ol-unselectable ol-control",d);zh.call(this,{element:c,target:b.target})}x(bs,zh);bs.prototype.i=function(b){b.preventDefault();var c=this.a;b=c.$();var d=null===this.c?b.g.P():this.c,c=c.Na();b.df(d,c)};function cs(b){je.call(this);b=m(b)?b:{};this.a=null;B(this,le("tracking"),this.kl,!1,this);this.vf(m(b.tracking)?b.tracking:!1)}x(cs,je);l=cs.prototype;l.Y=function(){this.vf(!1);cs.ba.Y.call(this)}; l.Hn=function(b){b=b.a;if(null!=b.alpha){var c=Lb(b.alpha);this.set("alpha",c);"boolean"==typeof b.absolute&&b.absolute?this.set("heading",c):null!=b.webkitCompassHeading&&null!=b.webkitCompassAccuracy&&-1!=b.webkitCompassAccuracy&&this.set("heading",Lb(b.webkitCompassHeading))}null!=b.beta&&this.set("beta",Lb(b.beta));null!=b.gamma&&this.set("gamma",Lb(b.gamma));this.o()};l.rj=function(){return this.get("alpha")};l.uj=function(){return this.get("beta")};l.Bj=function(){return this.get("gamma")}; l.jl=function(){return this.get("heading")};l.Mg=function(){return this.get("tracking")};l.kl=function(){if(gj){var b=this.Mg();b&&null===this.a?this.a=B(ba,"deviceorientation",this.Hn,!1,this):b||null===this.a||($d(this.a),this.a=null)}};l.vf=function(b){this.set("tracking",b)};function ds(){this.defaultDataProjection=null}function es(b,c,d){var e;m(d)&&(e={dataProjection:m(d.dataProjection)?d.dataProjection:b.Ga(c),featureProjection:d.featureProjection});return fs(b,e)}function fs(b,c){var d;m(c)&&(d={featureProjection:c.featureProjection,dataProjection:null!=c.dataProjection?c.dataProjection:b.defaultDataProjection,rightHanded:c.rightHanded});return d} function gs(b,c,d){var e=m(d)?te(d.featureProjection):null;d=m(d)?te(d.dataProjection):null;return null===e||null===d||Ke(e,d)?b:b instanceof Pe?(c?b.clone():b).transform(c?e:d,c?d:e):Oe(c?b.slice():b,c?e:d,c?d:e)};function hs(){this.defaultDataProjection=null}x(hs,ds);function is(b){return la(b)?b:ia(b)?(b=jo(b),m(b)?b:null):null}l=hs.prototype;l.U=function(){return"json"};l.Mb=function(b,c){return this.Rc(is(b),es(this,b,c))};l.xa=function(b,c){return this.Kf(is(b),es(this,b,c))};l.Sc=function(b,c){return this.vh(is(b),es(this,b,c))};l.Ga=function(b){return this.Ch(is(b))};l.Dd=function(b,c){return ko(this.Vc(b,c))};l.Ob=function(b,c){return ko(this.Me(b,c))};l.Wc=function(b,c){return ko(this.Oe(b,c))};function js(b){b=m(b)?b:{};this.defaultDataProjection=null;this.a=b.geometryName}x(js,hs); function ks(b,c){if(null===b)return null;var d;if(ja(b.x)&&ja(b.y))d="Point";else if(null!=b.points)d="MultiPoint";else if(null!=b.paths)d=1===b.paths.length?"LineString":"MultiLineString";else if(null!=b.rings){var e=b.rings,f=ls(b),g=[];d=[];var h,k;h=0;for(k=e.length;hc)throw Error("Bad port number "+c);b.l=c}else b.l=null}function Lt(b,c,d){c instanceof Nt?(b.b=c,Tt(b.b,b.i)):(d||(c=Ot(c,Ut)),b.b=new Nt(c,0,b.i))}function Vt(b){return b instanceof It?b.clone():new It(b,void 0)} function Wt(b,c){b instanceof It||(b=Vt(b));c instanceof It||(c=Vt(c));var d=b,e=c,f=d.clone(),g=!!e.c;g?Jt(f,e.c):g=!!e.j;g?f.j=e.j:g=!!e.f;g?f.f=e.f:g=null!=e.l;var h=e.a;if(g)Kt(f,e.l);else if(g=!!e.a)if("/"!=h.charAt(0)&&(d.f&&!d.a?h="/"+h:(d=f.a.lastIndexOf("/"),-1!=d&&(h=f.a.substr(0,d+1)+h))),d=h,".."==d||"."==d)h="";else if(-1!=d.indexOf("./")||-1!=d.indexOf("/.")){for(var h=0==d.lastIndexOf("/",0),d=d.split("/"),k=[],n=0;n>4&15).toString(16)+(b&15).toString(16)} var Pt=/[#\/\?@]/g,Rt=/[\#\?:]/g,Qt=/[\#\?]/g,Ut=/[\#\?@]/g,St=/#/g;function Nt(b,c,d){this.f=this.a=null;this.b=b||null;this.c=!!d}function Yt(b){b.a||(b.a=new xi,b.f=0,b.b&&uo(b.b,function(c,d){b.add(decodeURIComponent(c.replace(/\+/g," ")),d)}))}l=Nt.prototype;l.nc=function(){Yt(this);return this.f};l.add=function(b,c){Yt(this);this.b=null;b=Zt(this,b);var d=this.a.get(b);d||this.a.set(b,d=[]);d.push(c);this.f++;return this}; l.remove=function(b){Yt(this);b=Zt(this,b);return zi(this.a.f,b)?(this.b=null,this.f-=this.a.get(b).length,this.a.remove(b)):!1};l.clear=function(){this.a=this.b=null;this.f=0};l.Ia=function(){Yt(this);return 0==this.f};function $t(b,c){Yt(b);c=Zt(b,c);return zi(b.a.f,c)}l.N=function(){Yt(this);for(var b=this.a.pc(),c=this.a.N(),d=[],e=0;ee;++e){var f=parseInt(d[e],10).toString(16);d[e]=1==f.length?"0"+f:f}Hs(b,d.join(""))} function fv(b,c,d){Bp({node:b},gv,hv,[c],d)}function iv(b,c,d){var e={node:b};null!=c.ja&&b.setAttribute("id",c.ja);b=c.O();var f=c.Ta();m(f)&&(f=f.call(c,0),null!==f&&0g)if(h)if(56320> g){e.push(239,191,189);h=g;continue}else g=h-55296<<10|g-56320|65536,h=null;else{56319g?e.push(g):2048>g?e.push(g>>6|192,g&63|128):65536>g?e.push(g>>12|224,g>>6&63|128,g&63|128):e.push(g>>18|240,g>>12&63|128,g>>6&63|128,g&63|128)}return e}c.ia=g;var k=b("ieee754"),n,p,q;n={Eh:function(b){return(this[b]|this[b+1]<<8|this[b+2]<<16)+16777216*this[b+3]},Zf:function(b,c){this[c]=b;this[c+1]=b>>>8;this[c+2]=b>>>16;this[c+ 3]=b>>>24},wh:function(b){return(this[b]|this[b+1]<<8|this[b+2]<<16)+(this[b+3]<<24)},Of:function(b){return k.read(this,b,!0,23,4)},If:function(b){return k.read(this,b,!0,52,8)},di:function(b,c){return k.write(this,b,c,!0,23,4)},ai:function(b,c){return k.write(this,b,c,!0,52,8)},toString:function(b,c,e){var f=b="";c=c||0;for(e=Math.min(this.length,e||this.length);c=g?(b+=decodeURIComponent(f)+String.fromCharCode(g),f=""):f+="%"+g.toString(16)}return b+=decodeURIComponent(f)}, write:function(b,c){for(var e=b===p?q:h(b),f=0;f>3,c,this);this.aa===g&&this.So(f)}return c},co:function(){var b=this.ub.Of(this.aa);this.aa+=4;return b},Zn:function(){var b=this.ub.If(this.aa);this.aa+=8;return b},va:function(){var b=this.ub,c,e,f,g,h;c=b[this.aa++];if(128>c)return c;c=c&127;f=b[this.aa++];if(128>f)return c|f<<7;f=(f&127)<<7;g=b[this.aa++];if(128>g)return c|f|g<<14;g=(g&127)<<14;h=b[this.aa++];if(128>h)return c|f|g|h<<21;e=b[this.aa++]; c=(c|f|g|(h&127)<<21)+268435456*(e&127);if(128>e)return c;e=b[this.aa++];c+=34359738368*(e&127);if(128>e)return c;e=b[this.aa++];c+=4398046511104*(e&127);if(128>e)return c;e=b[this.aa++];c+=562949953421312*(e&127);if(128>e)return c;e=b[this.aa++];c+=72057594037927936*(e&127);if(128>e)return c;e=b[this.aa++];c+=0x7fffffffffffffff*(e&127);if(128>e)return c;throw Error("Expected varint not more than 10 bytes");},po:function(){var b=this.aa,c=this.va();if(cf?g<<7*f:g*Math.pow(2,7*f));return-c-1},zd:function(){var b=this.va();return 1===b%2?(b+1)/-2:b/2},Xn:function(){return Boolean(this.va())},Rf:function(){var b=this.va()+this.aa,c=this.ub.toString("utf8",this.aa,b);this.aa=b;return c},So:function(b){b=b&7;if(b===h.c)for(;127>1,z=-7;g=e?g-1:0;var w=e?-1:1,C=b[c+g];g+=w;e=C&(1<<-z)-1;C>>=-z;for(z+=r;0>=-z;for(z+=f;0>1,C=23===g?Math.pow(2,-24)-Math.pow(2,-77):0;r=f?0:r-1;var y=f?1:-1,A=0>c||0===c&&0>1/c?1:0;c=Math.abs(c);isNaN(c)||Infinity===c?(c=isNaN(c)?1:0,f=z):(f=Math.floor(Math.log(c)/Math.LN2),1>c*(t=Math.pow(2,-f))&&(f--,t*=2),c=1<=f+w?c+C/t:c+C*Math.pow(2,1-w),2<=c*t&&(f++,t/=2),f+w>=z?(c=0,f=z):1<=f+w?(c=(c*t-1)*Math.pow(2,g),f+=w):(c=c*Math.pow(2,w-1)*Math.pow(2,g),f=0));for(;8<=g;b[e+r]=c&255,r+=y,c/=256,g-=8);f=f<>3),f--,1===e||2===e)g+=b.zd(),h+=b.zd(),1===e&&(w&&z.push(w),w=[]),w.push(new k(g,h));else if(7===e)w&&w.push(w[0].clone());else throw Error("unknown command "+e);w&&z.push(w);return z};g.prototype.bbox=function(){var b=this.jc;b.aa=this.Se;for(var c=b.va()+b.aa,e=1,f=0,g=0,h=0,k=Infinity,w=-Infinity,C=Infinity,y=-Infinity;b.aa>3),f--,1===e||2===e)g+=b.zd(),h+=b.zd(),gw&&(w=g),hy&& (y=h);else if(7!==e)throw Error("unknown command "+e);return[k,C,w,y]}},{"point-geometry":5}],4:[function(b,c){function g(b,c){this.version=1;this.name=null;this.extent=4096;this.length=0;this.jc=b;this.Id=[];this.Kd=[];this.Hd=[];b.Mf(h,this,c);this.length=this.Hd.length}function h(b,c,e){15===b?c.version=e.va():1===b?c.name=e.Rf():5===b?c.extent=e.va():2===b?c.Hd.push(e.aa):3===b?c.Id.push(e.Rf()):4===b&&c.Kd.push(k(e))}function k(b){for(var c=null,e=b.va()+b.aa;b.aa>3,c=1===c?b.Rf(): 2===c?b.co():3===c?b.Zn():4===c?b.po():5===c?b.va():6===c?b.zd():7===c?b.Xn():null;return c}var n=b("./vectortilefeature.js");c.ia=g;g.prototype.feature=function(b){if(0>b||b>=this.Hd.length)throw Error("feature index out of bounds");this.jc.aa=this.Hd[b];b=this.jc.va()+this.jc.aa;return new n(this.jc,b,this.extent,this.Id,this.Kd)}},{"./vectortilefeature.js":3}],5:[function(b,c){function g(b,c){this.x=b;this.y=c}c.ia=g;g.prototype={clone:function(){return new g(this.x,this.y)},add:function(b){return this.clone().Ii(b)}, rotate:function(b){return this.clone().Ti(b)},round:function(){return this.clone().Ui()},angle:function(){return Math.atan2(this.y,this.x)},Ii:function(b){this.x+=b.x;this.y+=b.y;return this},Ti:function(b){var c=Math.cos(b);b=Math.sin(b);var e=b*this.x+c*this.y;this.x=c*this.x-b*this.y;this.y=e;return this},Ui:function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this}};g.a=function(b){return b instanceof g?b:Array.isArray(b)?new g(b[0],b[1]):b}},{}]},{},[1])(1)});Ip=c.ia})();function Qv(b){this.defaultDataProjection=null;b=m(b)?b:{};this.defaultDataProjection=new re({code:"EPSG:3857",units:"tile-pixels"});this.c=m(b.flyweight)?b.flyweight:!1;this.b=m(b.geometryName)?b.geometryName:"geometry";this.a=m(b.layerName)?b.layerName:"layer";this.f=m(b.layers)?b.layers:null}x(Qv,ds);Qv.prototype.U=function(){return"arraybuffer"}; Qv.prototype.xa=function(b,c){var d=this.f,e=new Hp(b),e=new Ip.Gi(e),f=[],g=this.c,h,k,n;for(n in e.layers)if(null===d||tb(d,n)){h=e.layers[n];for(var p=0;pf?~(f<<1):f<<1;d="";e=0;for(f=b.length;e>=5;h=g+63;k+=String.fromCharCode(h);d+=k}return d} function tw(b,c){var d=m(c)?c:1E5,e=[],f=0,g=0,h,k;h=0;for(k=b.length;hn?(e.push(f),g=f=0):g+=5}f=0;for(g=e.length;f>1):h>>1;f=0;for(g=e.length;f=b||"."==b&&!d} function Vw(b){var c=b.f.charAt(++b.a),d={position:b.a,value:c};if("("==c)d.type=2;else if(","==c)d.type=5;else if(")"==c)d.type=3;else if(Xw(c)||"-"==c){d.type=4;var e,c=b.a,f=!1,g=!1;do{if("."==e)f=!0;else if("e"==e||"E"==e)g=!0;e=b.f.charAt(++b.a)}while(Xw(e,f)||!g&&("e"==e||"E"==e)||g&&("-"==e||"+"==e));b=parseFloat(b.f.substring(c,b.a--));d.value=b}else if("a"<=c&&"z">=c||"A"<=c&&"Z">=c){d.type=1;c=b.a;do e=b.f.charAt(++b.a);while("a"<=e&&"z">=e||"A"<=e&&"Z">=e);b=b.f.substring(c,b.a--).toUpperCase(); d.value=b}else{if(" "==c||"\t"==c||"\r"==c||"\n"==c)return Vw(b);if(""===c)d.type=6;else throw Error("Unexpected character: "+c);}return d}function Tw(b){this.f=b}l=Tw.prototype;l.match=function(b){if(b=this.a.type==b)this.a=Vw(this.f);return b}; function Ww(b){var c=b.a;if(b.match(1)){var d=c.value;if("GEOMETRYCOLLECTION"==d){a:{if(b.match(2)){c=[];do c.push(Ww(b));while(b.match(5));if(b.match(3)){b=c;break a}}else if(Yw(b)){b=[];break a}throw Error(Zw(b));}return new an(b)}var e=$w[d],c=ax[d];if(!m(e)||!m(c))throw Error("Invalid geometry type: "+d);b=e.call(b);return new c(b)}throw Error(Zw(b));}l.Ff=function(){if(this.match(2)){var b=bx(this);if(this.match(3))return b}else if(Yw(this))return null;throw Error(Zw(this));}; l.Ef=function(){if(this.match(2)){var b=cx(this);if(this.match(3))return b}else if(Yw(this))return[];throw Error(Zw(this));};l.Gf=function(){if(this.match(2)){var b=dx(this);if(this.match(3))return b}else if(Yw(this))return[];throw Error(Zw(this));};l.Ln=function(){if(this.match(2)){var b;if(2==this.a.type)for(b=[this.Ff()];this.match(5);)b.push(this.Ff());else b=cx(this);if(this.match(3))return b}else if(Yw(this))return[];throw Error(Zw(this));}; l.Kn=function(){if(this.match(2)){var b=dx(this);if(this.match(3))return b}else if(Yw(this))return[];throw Error(Zw(this));};l.Mn=function(){if(this.match(2)){for(var b=[this.Gf()];this.match(5);)b.push(this.Gf());if(this.match(3))return b}else if(Yw(this))return[];throw Error(Zw(this));};function bx(b){for(var c=[],d=0;2>d;++d){var e=b.a;if(b.match(4))c.push(e.value);else break}if(2==c.length)return c;throw Error(Zw(b));}function cx(b){for(var c=[bx(b)];b.match(5);)c.push(bx(b));return c} function dx(b){for(var c=[b.Ef()];b.match(5);)c.push(b.Ef());return c}function Yw(b){var c=1==b.a.type&&"EMPTY"==b.a.value;c&&(b.a=Vw(b.f));return c}function Zw(b){return"Unexpected `"+b.a.value+"` at position "+b.a.position+" in `"+b.f.f+"`"}var ax={POINT:yf,LINESTRING:P,POLYGON:E,MULTIPOINT:ln,MULTILINESTRING:jn,MULTIPOLYGON:mn},$w={POINT:Tw.prototype.Ff,LINESTRING:Tw.prototype.Ef,POLYGON:Tw.prototype.Gf,MULTIPOINT:Tw.prototype.Ln,MULTILINESTRING:Tw.prototype.Kn,MULTIPOLYGON:Tw.prototype.Mn};function ex(){this.version=void 0}x(ex,Yv);ex.prototype.f=function(b){for(b=b.firstChild;null!==b;b=b.nextSibling)if(1==b.nodeType)return this.a(b);return null};ex.prototype.a=function(b){this.version=Ha(b.getAttribute("version"));b=V({version:this.version},fx,b,[]);return m(b)?b:null};function gx(b,c){return V({},hx,b,c)}function ix(b,c){return V({},jx,b,c)}function kx(b,c){var d=gx(b,c);if(m(d)){var e=[Fs(b.getAttribute("width")),Fs(b.getAttribute("height"))];d.size=e;return d}} function lx(b,c){return V([],mx,b,c)} var nx=[null,"http://www.opengis.net/wms"],fx=U(nx,{Service:R(function(b,c){return V({},ox,b,c)}),Capability:R(function(b,c){return V({},px,b,c)})}),px=U(nx,{Request:R(function(b,c){return V({},qx,b,c)}),Exception:R(function(b,c){return V([],rx,b,c)}),Layer:R(function(b,c){return V({},sx,b,c)})}),ox=U(nx,{Name:R(Y),Title:R(Y),Abstract:R(Y),KeywordList:R(lx),OnlineResource:R(Xv),ContactInformation:R(function(b,c){return V({},tx,b,c)}),Fees:R(Y),AccessConstraints:R(Y),LayerLimit:R(Es),MaxWidth:R(Es), MaxHeight:R(Es)}),tx=U(nx,{ContactPersonPrimary:R(function(b,c){return V({},ux,b,c)}),ContactPosition:R(Y),ContactAddress:R(function(b,c){return V({},vx,b,c)}),ContactVoiceTelephone:R(Y),ContactFacsimileTelephone:R(Y),ContactElectronicMailAddress:R(Y)}),ux=U(nx,{ContactPerson:R(Y),ContactOrganization:R(Y)}),vx=U(nx,{AddressType:R(Y),Address:R(Y),City:R(Y),StateOrProvince:R(Y),PostCode:R(Y),Country:R(Y)}),rx=U(nx,{Format:sp(Y)}),sx=U(nx,{Name:R(Y),Title:R(Y),Abstract:R(Y),KeywordList:R(lx),CRS:up(Y), EX_GeographicBoundingBox:R(function(b,c){var d=V({},wx,b,c);if(m(d)){var e=d.westBoundLongitude,f=d.southBoundLatitude,g=d.eastBoundLongitude,d=d.northBoundLatitude;return m(e)&&m(f)&&m(g)&&m(d)?[e,f,g,d]:void 0}}),BoundingBox:up(function(b){var c=[Ds(b.getAttribute("minx")),Ds(b.getAttribute("miny")),Ds(b.getAttribute("maxx")),Ds(b.getAttribute("maxy"))],d=[Ds(b.getAttribute("resx")),Ds(b.getAttribute("resy"))];return{crs:b.getAttribute("CRS"),extent:c,res:d}}),Dimension:up(function(b){return{name:b.getAttribute("name"), units:b.getAttribute("units"),unitSymbol:b.getAttribute("unitSymbol"),"default":b.getAttribute("default"),multipleValues:As(b.getAttribute("multipleValues")),nearestValue:As(b.getAttribute("nearestValue")),current:As(b.getAttribute("current")),values:Y(b)}}),Attribution:R(function(b,c){return V({},xx,b,c)}),AuthorityURL:up(function(b,c){var d=gx(b,c);if(m(d))return d.name=b.getAttribute("name"),d}),Identifier:up(Y),MetadataURL:up(function(b,c){var d=gx(b,c);if(m(d))return d.type=b.getAttribute("type"), d}),DataURL:up(gx),FeatureListURL:up(gx),Style:up(function(b,c){return V({},yx,b,c)}),MinScaleDenominator:R(Cs),MaxScaleDenominator:R(Cs),Layer:up(function(b,c){var d=c[c.length-1],e=V({},sx,b,c);if(m(e)){var f=As(b.getAttribute("queryable"));m(f)||(f=d.queryable);e.queryable=m(f)?f:!1;f=Fs(b.getAttribute("cascaded"));m(f)||(f=d.cascaded);e.cascaded=f;f=As(b.getAttribute("opaque"));m(f)||(f=d.opaque);e.opaque=m(f)?f:!1;f=As(b.getAttribute("noSubsets"));m(f)||(f=d.noSubsets);e.noSubsets=m(f)?f:!1; f=Ds(b.getAttribute("fixedWidth"));m(f)||(f=d.fixedWidth);e.fixedWidth=f;f=Ds(b.getAttribute("fixedHeight"));m(f)||(f=d.fixedHeight);e.fixedHeight=f;nb(["Style","CRS","AuthorityURL"],function(b){var c=d[b];if(m(c)){var f=Wc(e,b),f=f.concat(c);e[b]=f}});nb("EX_GeographicBoundingBox BoundingBox Dimension Attribution MinScaleDenominator MaxScaleDenominator".split(" "),function(b){m(e[b])||(e[b]=d[b])});return e}})}),xx=U(nx,{Title:R(Y),OnlineResource:R(Xv),LogoURL:R(kx)}),wx=U(nx,{westBoundLongitude:R(Cs), eastBoundLongitude:R(Cs),southBoundLatitude:R(Cs),northBoundLatitude:R(Cs)}),qx=U(nx,{GetCapabilities:R(ix),GetMap:R(ix),GetFeatureInfo:R(ix)}),jx=U(nx,{Format:up(Y),DCPType:up(function(b,c){return V({},zx,b,c)})}),zx=U(nx,{HTTP:R(function(b,c){return V({},Ax,b,c)})}),Ax=U(nx,{Get:R(gx),Post:R(gx)}),yx=U(nx,{Name:R(Y),Title:R(Y),Abstract:R(Y),LegendURL:up(kx),StyleSheetURL:R(gx),StyleURL:R(gx)}),hx=U(nx,{Format:R(Y),OnlineResource:R(Xv)}),mx=U(nx,{Keyword:sp(Y)});function Bx(){this.b="http://mapserver.gis.umn.edu/mapserver";this.a=new Ks;this.defaultDataProjection=null}x(Bx,vs); function Cx(b,c,d){c.namespaceURI=b.b;var e=ap(c),f=[];if(0===c.childNodes.length)return f;"msGMLOutput"==e&&nb(c.childNodes,function(b){if(1===b.nodeType){var c=d[0],e=b.localName,n=RegExp,p;p="_layer".replace(/([-()\[\]{}+?*.$\^|,:#=c.l&&c.cancel())}this.A?this.A.call(this.u,this):this.B=!0;this.a||(b=new fy,gy(this),hy(this,!1,b))}};ey.prototype.v=function(b,c){this.j=!1;hy(this,b,c)};function hy(b,c,d){b.a=!0;b.b=d;b.c=!c;iy(b)} function gy(b){if(b.a){if(!b.B)throw new jy;b.B=!1}}ey.prototype.$c=function(b){gy(this);hy(this,!0,b)};function ky(b,c,d,e){b.g.push([c,d,e]);b.a&&iy(b)}ey.prototype.then=function(b,c,d){var e,f,g=new Pn(function(b,c){e=b;f=c});ky(this,e,function(b){b instanceof fy?g.cancel():f(b)});return g.then(b,c,d)};Cn(ey);function ly(b){return qb(b.g,function(b){return ka(b[1])})} function iy(b){if(b.i&&b.a&&ly(b)){var c=b.i,d=my[c];d&&(ba.clearTimeout(d.ja),delete my[c]);b.i=0}b.f&&(b.f.l--,delete b.f);for(var c=b.b,e=d=!1;b.g.length&&!b.j;){var f=b.g.shift(),g=f[0],h=f[1],f=f[2];if(g=b.c?h:g)try{var k=g.call(f||b.u,c);m(k)&&(b.c=b.c&&(k==c||k instanceof Error),b.b=c=k);if(Dn(c)||"function"===typeof ba.Promise&&c instanceof ba.Promise)e=!0,b.j=!0}catch(n){c=n,b.c=!0,ly(b)||(d=!0)}}b.b=c;e&&(k=ra(b.v,b,!0),e=ra(b.v,b,!1),c instanceof ey?(ky(c,k,e),c.D=!0):c.then(k,e));d&&(c= new ny(c),my[c.ja]=c,b.i=c.ja)}function jy(){Da.call(this)}x(jy,Da);jy.prototype.message="Deferred has already fired";jy.prototype.name="AlreadyCalledError";function fy(){Da.call(this)}x(fy,Da);fy.prototype.message="Deferred was canceled";fy.prototype.name="CanceledError";function ny(b){this.ja=ba.setTimeout(ra(this.f,this),0);this.a=b}ny.prototype.f=function(){delete my[this.ja];throw this.a;};var my={};function oy(b,c){m(b.name)?(this.name=b.name,this.code=py[b.name]):(this.code=b.code,this.name=qy(b.code));Da.call(this,Ga("%s %s",this.name,c))}x(oy,Da);function qy(b){var c=Rc(py,function(c){return b==c});if(!m(c))throw Error("Invalid code: "+b);return c}var py={AbortError:3,EncodingError:5,InvalidModificationError:9,InvalidStateError:7,NotFoundError:1,NotReadableError:4,NoModificationAllowedError:6,PathExistsError:12,QuotaExceededError:10,SecurityError:2,SyntaxError:8,TypeMismatchError:11};function ry(b,c){xd.call(this,b.type,c)}x(ry,xd);function sy(){de.call(this);this.mb=new FileReader;this.mb.onloadstart=ra(this.a,this);this.mb.onprogress=ra(this.a,this);this.mb.onload=ra(this.a,this);this.mb.onabort=ra(this.a,this);this.mb.onerror=ra(this.a,this);this.mb.onloadend=ra(this.a,this)}x(sy,de);sy.prototype.getError=function(){return this.mb.error&&new oy(this.mb.error,"reading file")};sy.prototype.a=function(b){D(this,new ry(b,this))};sy.prototype.Y=function(){sy.ba.Y.call(this);delete this.mb}; function ty(b){var c=new ey;b.ab("loadend",sa(function(b,c){var f=c.mb.result,g=c.getError();null==f||g?(gy(b),hy(b,!1,g)):b.$c(f);c.jd()},c,b));return c};function uy(b){b=m(b)?b:{};Uk.call(this,{handleEvent:xa});this.i=m(b.formatConstructors)?b.formatConstructors:[];this.u=m(b.projection)?te(b.projection):null;this.c=null;this.a=void 0}x(uy,Uk);uy.prototype.Y=function(){m(this.a)&&$d(this.a);uy.ba.Y.call(this)};uy.prototype.j=function(b){b=b.a.dataTransfer.files;var c,d,e;c=0;for(d=b.length;cb.Ya:b.c===Iy&&(e=b.a[0].length>b.Ya,f=[b.a[0][0],b.a[0][b.a[0].length-2]]);if(e)for(var e=c.map,g=0,h=f.length;gb.Ja,b.D(g,e);else if(b.c===Iy){g=b.a[0];g.push(d.slice());if(f=g.length>b.Ja)b.l=g[0];b.D(b.a,e)}Ry(b);f&&b.ld()}l.to=function(){var b=this.j.V(),c,d;this.c===Ky?(c=this.a,c.splice(-2,1),this.D(c,b)):this.c===Iy&&(c=this.a[0],c.splice(-2,1),d=this.u.V(),d.ma(c),this.D(this.a,b));0===c.length&&(this.l=null);Ry(this)}; l.ld=function(){var b=Sy(this),c=this.a,d=b.V();this.c===Ky?(c.pop(),this.D(c,d)):this.c===Iy&&(c[0].pop(),c[0].push(c[0][0]),this.D(c,d));"MultiPoint"===this.S?b.za(new ln([c])):"MultiLineString"===this.S?b.za(new jn([c])):"MultiPolygon"===this.S&&b.za(new mn([c]));D(this,new Cy("drawend",b));null===this.eb||this.eb.push(b);null===this.tb||this.tb.Oc(b)};function Sy(b){b.l=null;var c=b.j;null!==c&&(b.j=null,b.C=null,b.u=null,b.ga.da().clear(!0));return c} l.Tl=function(b){var c=b.V();this.j=b;this.a=c.X();b=this.a[this.a.length-1];this.l=b.slice();this.a.push(b.slice());Ry(this);D(this,new Cy("drawstart",this.j))};l.zc=wa;function Ry(b){var c=[];null===b.j||c.push(b.j);null===b.u||c.push(b.u);null===b.C||c.push(b.C);b=b.ga.da();b.clear(!0);b.kc(c)}l.Zh=function(){var b=this.v,c=this.b();null!==b&&c||Sy(this);this.ga.setMap(c?b:null)}; function Hy(b){var c;"Point"===b||"MultiPoint"===b?c=Jy:"LineString"===b||"MultiLineString"===b?c=Ky:"Polygon"===b||"MultiPolygon"===b?c=Iy:"Circle"===b&&(c=Py);return c}var Jy="Point",Ky="LineString",Iy="Polygon",Py="Circle";function Ty(b,c,d){xd.call(this,b);this.features=c;this.mapBrowserPointerEvent=d}x(Ty,xd); function Uy(b){gl.call(this,{handleDownEvent:Vy,handleDragEvent:Wy,handleEvent:Xy,handleUpEvent:Yy});this.wa=m(b.deleteCondition)?b.deleteCondition:Ca(cl,bl);this.ga=this.c=null;this.S=[0,0];this.M=!1;this.a=new Kp;this.D=m(b.pixelTolerance)?b.pixelTolerance:10;this.l=this.ca=!1;this.j=null;this.C=new N({source:new W({useSpatialIndex:!1,wrapX:m(b.wrapX)?b.wrapX:!1}),style:m(b.style)?b.style:Zy(),updateWhileAnimating:!0,updateWhileInteracting:!0});this.T={Point:this.$l,LineString:this.Vg,LinearRing:this.Vg, Polygon:this.am,MultiPoint:this.Yl,MultiLineString:this.Xl,MultiPolygon:this.Zl,GeometryCollection:this.Wl};this.u=b.features;this.u.forEach(this.Af,this);B(this.u,"add",this.Ul,!1,this);B(this.u,"remove",this.Vl,!1,this)}x(Uy,gl);l=Uy.prototype;l.Af=function(b){var c=b.V();m(this.T[c.U()])&&this.T[c.U()].call(this,b,c);c=this.v;null===c||$y(this,this.S,c);B(b,"change",this.Ug,!1,this)};function az(b,c){bz(b,c);null!==b.c&&0===b.u.Ub()&&(b.C.da().uc(b.c),b.c=null);Zd(c,"change",b.Ug,!1,b)} function bz(b,c){var d=b.a,e=[];d.forEach(function(b){c===b.feature&&e.push(b)});for(var f=e.length-1;0<=f;--f)d.remove(e[f])}l.setMap=function(b){this.C.setMap(b);Uy.ba.setMap.call(this,b)};l.Ul=function(b){this.Af(b.element)};l.Ug=function(b){this.l||(b=b.target,az(this,b),this.Af(b))};l.Vl=function(b){az(this,b.element)};l.$l=function(b,c){var d=c.X(),d={feature:b,geometry:c,ka:[d,d]};this.a.ua(c.P(),d)}; l.Yl=function(b,c){var d=c.X(),e,f,g;f=0;for(g=d.length;fd?h[1]:h[0]);cz(b,k);d={};d[ma(h)]=!0;c=1;for(n=g.length;cd&&(b.index+=f)})}function Zy(){var b=Pl();return function(){return b.Point}};function fz(b,c,d,e){xd.call(this,b);this.selected=c;this.deselected=d;this.mapBrowserEvent=e}x(fz,xd); function gz(b){Uk.call(this,{handleEvent:hz});b=m(b)?b:{};this.u=m(b.condition)?b.condition:bl;this.j=m(b.addCondition)?b.addCondition:wa;this.M=m(b.removeCondition)?b.removeCondition:wa;this.T=m(b.toggleCondition)?b.toggleCondition:dl;this.l=m(b.multi)?b.multi:!1;this.c=m(b.filter)?b.filter:xa;var c;if(m(b.layers))if(ka(b.layers))c=b.layers;else{var d=b.layers;c=function(b){return tb(d,b)}}else c=xa;this.i=c;this.a=new N({source:new W({useSpatialIndex:!1,wrapX:b.wrapX}),style:m(b.style)?b.style: iz(),updateWhileAnimating:!0,updateWhileInteracting:!0});b=this.a.da().b;B(b,"add",this.A,!1,this);B(b,"remove",this.C,!1,this)}x(gz,Uk);gz.prototype.D=function(){return this.a.da().b}; function hz(b){if(!this.u(b))return!0;var c=this.j(b),d=this.M(b),e=this.T(b),f=!c&&!d&&!e,g=b.map,h=this.a.da().b,k=[],n=[],p=!1;if(f)g.md(b.pixel,function(b,c){if(this.c(b,c))return n.push(b),!this.l},this,this.i),0f?h[1]:h[0],d=c.La(n),d=[Math.round(d[0]),Math.round(d[1])]);c=n;g&&(b.coordinate=c.slice(0,2),b.pixel=d);return hl.call(this,b)} function lz(){var b=Nc(this.u);b.length&&(nb(b,this.Yh,this),this.u={});return!1}function mz(b,c){return Vb(this.M,b.ka)-Vb(this.M,c.ka)};function nz(b){gl.call(this,{handleDownEvent:oz,handleDragEvent:pz,handleMoveEvent:qz,handleUpEvent:rz});this.l=void 0;this.a=null;this.c=m(b.features)?b.features:null;this.j=null}x(nz,gl);function oz(b){this.j=sz(this,b.pixel,b.map);return null===this.a&&null!==this.j?(this.a=b.coordinate,qz.call(this,b),!0):!1}function rz(b){return null!==this.a?(this.a=null,qz.call(this,b),!0):!1} function pz(b){if(null!==this.a){b=b.coordinate;var c=b[0]-this.a[0],d=b[1]-this.a[1];if(null!==this.c)this.c.forEach(function(b){var e=b.V();e.translate(c,d);b.za(e)});else if(null===this.j){var e=this.j.V();e.translate(c,d);this.j.za(e)}this.a=b}} function qz(b){var c=b.map.Lc();if(b=b.map.md(b.pixel,function(b){return b})){var d=!1;null!==this.c&&tb(this.c.a,b)&&(d=!0);this.l=c.style.cursor;c.style.cursor=null===this.a?d?"-webkit-grab":"pointer":"-webkit-grabbing";c.style.cursor=null===this.a?"grabbing":d?"grab":"pointer"}else c.style.cursor=m(this.l)?this.l:"",this.l=void 0}function sz(b,c,d){var e=null;c=d.md(c,function(b){return b});null!==b.c&&tb(b.c.a,c)&&(e=c);return e};function Z(b){b=m(b)?b:{};var c=Xc(b);delete c.gradient;delete c.radius;delete c.blur;delete c.shadow;delete c.weight;N.call(this,c);this.g=null;this.Z=m(b.shadow)?b.shadow:250;this.S=void 0;this.T=null;B(this,le("gradient"),this.pk,!1,this);this.Oh(m(b.gradient)?b.gradient:tz);this.Kh(m(b.blur)?b.blur:15);this.ah(m(b.radius)?b.radius:8);B(this,[le("blur"),le("radius")],this.Eg,!1,this);this.Eg();var d=m(b.weight)?b.weight:"weight",e;ia(d)?e=function(b){return b.get(d)}:e=d;this.c(ra(function(b){b= e(b);b=m(b)?Hb(b,0,1):1;var c=255*b|0,d=this.T[c];m(d)||(d=[new Kl({image:new Ck({opacity:b,src:this.S})})],this.T[c]=d);return d},this));this.set("renderOrder",null);B(this,"render",this.Hk,!1,this)}x(Z,N);var tz=["#00f","#0ff","#0f0","#ff0","#f00"];l=Z.prototype;l.qg=function(){return this.get("blur")};l.tg=function(){return this.get("gradient")};l.$g=function(){return this.get("radius")}; l.pk=function(){for(var b=this.tg(),c=Wi(1,256),d=c.createLinearGradient(0,0,1,256),e=1/(b.length-1),f=0,g=b.length;fTerms of Use'}); Jz.prototype.l=function(b){if(200!=b.statusCode||"OK"!=b.statusDescription||"ValidCredentials"!=b.authenticationResultCode||1!=b.resourceSets.length||1!=b.resourceSets[0].resources.length)Ih(this,"error");else{var c=b.brandLogoUri;-1==c.indexOf("https")&&(c=c.replace("http","https"));var d=b.resourceSets[0].resources[0],e=-1==this.c?d.zoomMax:this.c;b=kg(this.j);var f=Sh({extent:b,minZoom:d.zoomMin,maxZoom:e,tileSize:d.imageWidth==d.imageHeight?d.imageWidth:[d.imageWidth,d.imageHeight]});this.tileGrid= f;var g=this.i;this.tileUrlFunction=eq(pb(d.imageUrlSubdomains,function(b){var c=[0,0,0],e=d.imageUrl.replace("{subdomain}",b).replace("{culture}",g);return function(b){if(null!==b)return dg(b[0],b[1],-b[2]-1,c),e.replace("{quadkey}",gg(c))}}));if(d.imageryProviders){var h=xe(te("EPSG:4326"),this.j);b=pb(d.imageryProviders,function(b){var c=b.attribution,d={};nb(b.coverageAreas,function(b){var c=b.zoomMin,g=Math.min(b.zoomMax,e);b=b.bbox;b=Ec([b[1],b[0],b[3],b[2]],h);var k,n;for(k=c;k<=g;++k)n=k.toString(), c=mg(f,b,k),n in d?d[n].push(c):d[n]=[c]});return new sg({html:c,tileRanges:d})});b.push(Kz);this.la(b)}this.T=c;Ih(this,"ready")}};function Lz(b){W.call(this,{attributions:b.attributions,extent:b.extent,logo:b.logo,projection:b.projection});this.M=void 0;this.ca=m(b.distance)?b.distance:20;this.C=[];this.A=b.source;this.A.G("change",Lz.prototype.wa,this)}x(Lz,W);Lz.prototype.ga=function(){return this.A};Lz.prototype.rc=function(b,c,d){this.A.rc(b,c,d);c!==this.M&&(this.clear(),this.M=c,Mz(this),this.kc(this.C))};Lz.prototype.wa=function(){this.clear();Mz(this);this.kc(this.C);this.o()}; function Mz(b){if(m(b.M)){b.C.length=0;for(var c=ac(),d=b.ca*b.M,e=b.A.Pc(),f={},g=0,h=e.length;gk*h?g*f/(k*p):h*f/(n*p);d=wc(d);e={OPERATION:this.ga?"GETDYNAMICMAPOVERLAYIMAGE":"GETMAPIMAGE",VERSION:"2.0.0",LOCALE:"en",CLIENTAGENT:"ol.source.ImageMapGuide source",CLIP:"1",SETDISPLAYDPI:this.i,SETDISPLAYWIDTH:Math.round(e[0]),SETDISPLAYHEIGHT:Math.round(e[1]),SETVIEWSCALE:f,SETVIEWCENTERX:d[0],SETVIEWCENTERY:d[1]};$c(e,c);return vo(xo([b],e))};l.sm=function(b){this.b=null;this.a=b;this.o()};function Pz(b){var c=m(b.attributions)?b.attributions:null,d=b.imageExtent,e,f;m(b.imageSize)&&(e=yc(d)/b.imageSize[1],f=[e]);var g=m(b.crossOrigin)?b.crossOrigin:null,h=m(b.imageLoadFunction)?b.imageLoadFunction:zn;tn.call(this,{attributions:c,logo:b.logo,projection:te(b.projection),resolutions:f});this.a=new Zx(d,e,1,c,b.url,g,h);B(this.a,"change",this.l,!1,this)}x(Pz,tn);Pz.prototype.W=function(b){return Ac(b,this.a.P())?this.a:null};function Qz(b){b=m(b)?b:{};tn.call(this,{attributions:b.attributions,logo:b.logo,projection:b.projection,resolutions:b.resolutions});this.ca=m(b.crossOrigin)?b.crossOrigin:null;this.c=b.url;this.A=m(b.imageLoadFunction)?b.imageLoadFunction:zn;this.b=b.params;this.i=!0;Rz(this);this.Z=b.serverType;this.ga=m(b.hidpi)?b.hidpi:!0;this.a=null;this.C=[0,0];this.S=0;this.M=m(b.ratio)?b.ratio:1.5}x(Qz,tn);var Sz=[101,101];l=Qz.prototype; l.zm=function(b,c,d,e){if(m(this.c)){var f=xc(b,c,0,Sz),g={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetFeatureInfo",FORMAT:"image/png",TRANSPARENT:!0,QUERY_LAYERS:this.b.LAYERS};$c(g,this.b,e);e=Math.floor((f[3]-b[1])/c);g[this.i?"I":"X"]=Math.floor((b[0]-f[0])/c);g[this.i?"J":"Y"]=e;return Tz(this,f,Sz,1,te(d),g)}};l.Bm=function(){return this.b}; l.W=function(b,c,d,e){if(!m(this.c))return null;c=un(this,c);1==d||this.ga&&m(this.Z)||(d=1);b=b.slice();var f=(b[0]+b[2])/2,g=(b[1]+b[3])/2;if(1!=this.M){var h=this.M*Bc(b)/2,k=this.M*yc(b)/2;b[0]=f-h;b[1]=g-k;b[2]=f+h;b[3]=g+k}var n=c/d,h=Math.ceil(Bc(b)/n),k=Math.ceil(yc(b)/n);b[0]=f-n*h/2;b[2]=f+n*h/2;b[1]=g-n*k/2;b[3]=g+n*k/2;f=this.a;if(null!==f&&this.S==this.f&&f.resolution==c&&f.c==d&&jc(f.P(),b))return f;f={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetMap",FORMAT:"image/png",TRANSPARENT:!0}; $c(f,this.b);this.C[0]=h;this.C[1]=k;e=Tz(this,b,this.C,d,e,f);this.a=new Zx(b,c,d,this.g,e,this.ca,this.A);this.S=this.f;B(this.a,"change",this.l,!1,this);return this.a};l.Am=function(){return this.A}; function Tz(b,c,d,e,f,g){g[b.i?"CRS":"SRS"]=f.a;"STYLES"in b.b||(g.STYLES=new String(""));if(1!=e)switch(b.Z){case "geoserver":e=90*e+.5|0;g.FORMAT_OPTIONS=m(g.FORMAT_OPTIONS)?g.FORMAT_OPTIONS+(";dpi:"+e):"dpi:"+e;break;case "mapserver":g.MAP_RESOLUTION=90*e;break;case "carmentaserver":case "qgis":g.DPI=90*e}g.WIDTH=d[0];g.HEIGHT=d[1];d=f.c;var h;b.i&&"ne"==d.substr(0,2)?h=[c[1],c[0],c[3],c[2]]:h=c;g.BBOX=h.join(",");return vo(xo([b.c],g))}l.Cm=function(){return this.c}; l.Dm=function(b){this.a=null;this.A=b;this.o()};l.Em=function(b){b!=this.c&&(this.c=b,this.a=null,this.o())};l.Fm=function(b){$c(this.b,b);Rz(this);this.a=null;this.o()};function Rz(b){b.i=0<=Ta(Vc(b.b,"VERSION","1.3.0"),"1.3")};function Uz(b){var c=m(b.projection)?b.projection:"EPSG:3857",d=m(b.tileGrid)?b.tileGrid:Sh({extent:kg(c),maxZoom:b.maxZoom,tileSize:b.tileSize});this.l=null;Hz.call(this,{attributions:b.attributions,crossOrigin:b.crossOrigin,logo:b.logo,projection:c,tileGrid:d,tileLoadFunction:b.tileLoadFunction,tilePixelRatio:b.tilePixelRatio,tileUrlFunction:fq,wrapX:m(b.wrapX)?b.wrapX:!0});m(b.tileUrlFunction)?this.Fa(b.tileUrlFunction):m(b.urls)?(b=b.urls,this.Fa(dq(b)),this.l=b):m(b.url)&&this.c(b.url)} x(Uz,Hz);Uz.prototype.i=function(){return this.l};Uz.prototype.c=function(b){this.Fa(dq(gq(b)));this.l=[b]};function Vz(b){b=m(b)?b:{};var c;m(b.attributions)?c=b.attributions:c=[Wz];Uz.call(this,{attributions:c,crossOrigin:m(b.crossOrigin)?b.crossOrigin:"anonymous",opaque:!0,maxZoom:m(b.maxZoom)?b.maxZoom:19,tileLoadFunction:b.tileLoadFunction,url:m(b.url)?b.url:"https://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png",wrapX:b.wrapX})}x(Vz,Uz);var Wz=new sg({html:'© OpenStreetMap contributors.'});function Xz(b){b=m(b)?b:{};var c=Yz[b.layer];this.v=b.layer;Uz.call(this,{attributions:c.attributions,crossOrigin:"anonymous",logo:"https://developer.mapquest.com/content/osm/mq_logo.png",maxZoom:c.maxZoom,opaque:!0,tileLoadFunction:b.tileLoadFunction,url:m(b.url)?b.url:"https://otile{1-4}-s.mqcdn.com/tiles/1.0.0/"+this.v+"/{z}/{x}/{y}.jpg"})}x(Xz,Uz); var Zz=new sg({html:'Tiles Courtesy of MapQuest'}),Yz={osm:{maxZoom:19,attributions:[Zz,Wz]},sat:{maxZoom:18,attributions:[Zz,new sg({html:"Portions Courtesy NASA/JPL-Caltech and U.S. Depart. of Agriculture, Farm Service Agency"})]},hyb:{maxZoom:18,attributions:[Zz,Wz]}};Xz.prototype.A=function(){return this.v};(function(){var b={},c={ia:b};(function(d){if("object"===typeof b&&"undefined"!==typeof c)c.ia=d();else{var e;"undefined"!==typeof window?e=window:"undefined"!==typeof global?e=global:"undefined"!==typeof self?e=self:e=this;e.xp=d()}})(function(){return function e(b,c,h){function k(p,r){if(!c[p]){if(!b[p]){var t="function"==typeof require&&require;if(!r&&t)return t(p,!0);if(n)return n(p,!0);t=Error("Cannot find module '"+p+"'");throw t.code="MODULE_NOT_FOUND",t;}t=c[p]={ia:{}};b[p][0].call(t.ia,function(c){var e= b[p][1][c];return k(e?e:c)},t,t.ia,e,b,c,h)}return c[p].ia}for(var n="function"==typeof require&&require,p=0;pthis.Ri;)this.Yc.shift().$c(null,null)};n.prototype.fg=function(){if(0===this.Jd&&0Stamen Design, under CC BY 3.0.'}),Wz];function kA(b){b=m(b)?b:{};var c=m(b.params)?b.params:{};Hz.call(this,{attributions:b.attributions,crossOrigin:b.crossOrigin,logo:b.logo,projection:b.projection,tileGrid:b.tileGrid,tileLoadFunction:b.tileLoadFunction,tileUrlFunction:ra(this.Jm,this),wrapX:m(b.wrapX)?b.wrapX:!0});var d=b.urls;!m(d)&&m(b.url)&&(d=gq(b.url));this.i=null!=d?d:[];this.c=c;this.l=ac()}x(kA,Hz);l=kA.prototype;l.Gm=function(){return this.c};l.Jb=function(b,c,d){b=kA.ba.Jb.call(this,b,c,d);return 1==c?b:Yb(b,c,this.b)}; l.Hm=function(){return this.i};l.Im=function(b){b=m(b)?gq(b):null;this.gh(b)};l.gh=function(b){this.i=null!=b?b:[];this.o()}; l.Jm=function(b,c,d){var e=this.tileGrid;null===e&&(e=Wh(this,d));if(!(e.a.length<=b[0])){var f=Nh(e,b,this.l),g=Zb(e.Ha(b[0]),this.b);1!=c&&(g=Yb(g,c,this.b));e={F:"image",FORMAT:"PNG32",TRANSPARENT:!0};$c(e,this.c);var h=this.i;0==h.length?b=void 0:(d=d.a.split(":").pop(),e.SIZE=g[0]+","+g[1],e.BBOX=f.join(","),e.BBOXSR=d,e.IMAGESR=d,e.DPI=Math.round(90*c),b=1==h.length?h[0]:h[Jb((b[1]<g||e>g;)f.push([Math.ceil(d/g),Math.ceil(e/g)]),g+=g;break;case "truncated":for(;d>g||e>g;)f.push([Math.ceil(d/g),Math.ceil(e/g)]),d>>=1,e>>=1}f.push([1,1]);f.reverse();for(var g=[1],h=[0],e=1,d=f.length;ethis.b||d+this.a>this.b)return null;e=IA(this,!1,b,c,d,e,g);if(null===e)return null;b=IA(this,!0,b,c,d,m(f)?f:ya,g);return{offsetX:e.offsetX,offsetY:e.offsetY,image:e.image,Fg:b.image}}; function IA(b,c,d,e,f,g,h){var k=c?b.i:b.g,n,p,q;p=0;for(q=k.length;p=c+this.a&&g.height>=d+this.a)return k={offsetX:g.x+this.a,offsetY:g.y+this.a,image:this.b},this.c[b]=k,e.call(f,this.g,g.x+this.a,g.y+this.a),b=h,c=c+this.a,d=d+this.a,f=e=void 0,g.width-c>g.height-d?(e={x:g.x+c,y:g.y,width:g.width-c,height:g.height},f={x:g.x,y:g.y+d,width:c,height:g.height-d},JA(this,b,e,f)):(e={x:g.x+c,y:g.y,width:g.width-c,height:d},f={x:g.x,y:g.y+d,width:g.width,height:g.height- d},JA(this,b,e,f)),k;return null};function JA(b,c,d,e){c=[c,1];0f&&(f=0);g=d.TileMatrixSetLink[f].TileMatrixSet; var h=d.Format[0];m(c.format)&&(h=c.format);f=sb(d.Style,function(b){return m(c.style)?b.Title==c.style:b.isDefault});0>f&&(f=0);f=d.Style[f].Identifier;var k={};m(d.Dimension)&&nb(d.Dimension,function(b){var c=b.Identifier,d=b["default"];m(d)||(d=b.values[0]);k[c]=d});var n=rb(b.Contents.TileMatrixSet,function(b){return b.Identifier==g}),p;p=m(c.projection)?te(c.projection):te(n.SupportedCRS.replace(/urn:ogc:def:crs:(\w+):(.*:)?(\w+)$/,"$1:$3"));var q=d.WGS84BoundingBox,r,t;m(q)&&(t=te("EPSG:4326").P(), t=q[0]==t[0]&&q[2]==t[2],r=Oe(q,"EPSG:4326",p),q=p.P(),null===q||jc(q,r)||(r=void 0));var n=BA(n,r),u=[];r=c.requestEncoding;r=m(r)?r:"";if(b.hasOwnProperty("OperationsMetadata")&&b.OperationsMetadata.hasOwnProperty("GetTile")&&0!=r.lastIndexOf("REST",0))for(var d=b.OperationsMetadata.GetTile.DCP.HTTP.Get,q=0,z=d.length;q