text: (function(){'use strict';var aa=Object,ba=Math,ca=window,da=parseInt,ea=document,e=Array,fa=Error,ga=JSON,ha=String;function ia(a,b){return a.table=b}function ja(a,b){return a.name=b}function ka(a,b){return a.dump=b}function la(a,b){return a.clone=b}function ma(a,b){return a.exec=b}function na(a,b){return a.getName=b}function oa(a,b){return a.close=b}function pa(a,b){return a.value=b}function qa(a,b){return a.update=b}function ra(a,b){return a.delete=b}function sa(a,b){return a.onsuccess=b}
  function ta(a,b){return a.clear=b}function ua(a,b){return a.values=b}function va(a,b){return a.remove=b}function wa(a,b){return a.child=b}function xa(a,b){return a.next=b}function ya(a,b){return a.onerror=b}function g(a,b){return a.toString=b}function za(a,b){return a.bind=b}function Aa(a,b){return a.subscribe=b}function Ba(a,b){return a.forEach=b}function Ca(a,b){return a.getPriority=b}
  var Da="openCursor",Ea="filter",Fa="once",Ga="objectStoreNames",Ha="split",k="table",Ia="reduce",m="join",Ja="reject",Ka="timing",La="item",n="slice",Ma="target",q="name",r="call",t="prototype",Na="clone",Oa="exec",u="getName",Pa="close",Qa="concat",v="value",Ta="setImmediate",Ua="every",Va="update",Wa="global",Xa="propertyIsEnumerable",Ya="delete",Za="sort",$a="indexOf",ab="some",bb="count",cb="orderByChild",w="clear",db="values",eb="replace",fb="reverse",gb="continue",hb="removeChild",ib="remove",
  jb="child",x="push",z="then",kb="keys",lb="transaction",mb="index",nb="context",A="splice",ob="autoIncrement",pb="next",qb="shift",rb="hasOwnProperty",sb="contains",tb="version",ub="objectStore",vb="offset",wb="apply",xb="stringify",B="entries",C="length",yb="info",D="toString",zb="compare",E="bind",Ab="getParent",Bb="rows",F="forEach",Cb="getPriority",Db="getTime",Eb="resolve",Fb="result",G="size";function Gb(){return function(){}}function Hb(a){return function(b){this[a]=b}}
  function H(a){return function(){return this[a]}}function Ib(a){return function(){return a}}var I,Jb=this;function Kb(a){return void 0!==a}function Lb(){}
  function Mb(a){var b=typeof a;if("object"==b)if(a){if(a instanceof e)return"array";if(a instanceof aa)return b;var c=aa[t][D][r](a);if("[object Window]"==c)return"object";if("[object Array]"==c||"number"==typeof a[C]&&"undefined"!=typeof a[A]&&"undefined"!=typeof a[Xa]&&!a[Xa]("splice"))return"array";if("[object Function]"==c||"undefined"!=typeof a[r]&&"undefined"!=typeof a[Xa]&&!a[Xa]("call"))return"function"}else return"null";else if("function"==b&&"undefined"==typeof a[r])return"object";return b}
  function Nb(a){return null===a}function Ob(a){return null!=a}function Pb(a){var b=Mb(a);return"array"==b||"object"==b&&"number"==typeof a[C]}function Qb(a){return"string"==typeof a}function Rb(a){return"function"==Mb(a)}function Sb(a){return a[Ub]||(a[Ub]=++Vb)}var Ub="closure_uid_"+(1E9*ba.random()>>>0),Vb=0;function Wb(a,b,c){return a[r][wb](a[E],arguments)}
  function Xb(a,b,c){if(!a)throw fa();if(2<arguments[C]){var d=e[t][n][r](arguments,2);return function(){var c=e[t][n][r](arguments);e[t].unshift[wb](c,d);return a[wb](b,c)}}return function(){return a[wb](b,arguments)}}function Yb(a,b,c){Yb=Function[t][E]&&-1!=Function[t][E][D]()[$a]("native code")?Wb:Xb;return Yb[wb](null,arguments)}function Zb(a,b){var c=e[t][n][r](arguments,1);return function(){var b=c[n]();b[x][wb](b,arguments);return a[wb](this,b)}}
  function J(a,b){var c=a[Ha]("."),d=Jb;c[0]in d||!d.execScript||d.execScript("var "+c[0]);for(var f;c[C]&&(f=c[qb]());)!c[C]&&Kb(b)?d[f]=b:d=d[f]?d[f]:d[f]={}}function K(a,b){function c(){}c.prototype=b[t];a.Db=b[t];a.prototype=new c;a[t].constructor=a;a.ug=function(a,c,h){for(var l=e(arguments[C]-2),p=2;p<arguments[C];p++)l[p-2]=arguments[p];return b[t][c][wb](a,l)}};function $b(a){if(fa.captureStackTrace)fa.captureStackTrace(this,$b);else{var b=fa().stack;b&&(this.stack=b)}a&&(this.message=ha(a))}K($b,fa);ja($b[t],"CustomError");function ac(a,b,c){this.Vf=c;this.Bf=a;this.lg=b;this.od=0;this.jd=null}ac[t].get=function(){var a;0<this.od?(this.od--,a=this.jd,this.jd=a[pb],xa(a,null)):a=this.Bf();return a};ac[t].put=function(a){this.lg(a);this.od<this.Vf&&(this.od++,xa(a,this.jd),this.jd=a)};var bc=e[t],cc=bc[$a]?function(a,b,c){return bc[$a][r](a,b,c)}:function(a,b,c){c=null==c?0:0>c?ba.max(0,a[C]+c):c;if(Qb(a))return Qb(b)&&1==b[C]?a[$a](b,c):-1;for(;c<a[C];c++)if(c in a&&a[c]===b)return c;return-1},dc=bc[F]?function(a,b,c){bc[F][r](a,b,c)}:function(a,b,c){for(var d=a[C],f=Qb(a)?a[Ha](""):a,h=0;h<d;h++)h in f&&b[r](c,f[h],h,a)},ec=bc.map?function(a,b,c){return bc.map[r](a,b,c)}:function(a,b,c){for(var d=a[C],f=e(d),h=Qb(a)?a[Ha](""):a,l=0;l<d;l++)l in h&&(f[l]=b[r](c,h[l],l,a));return f},
  fc=bc[Ia]?function(a,b,c,d){d&&(b=Yb(b,d));return bc[Ia][r](a,b,c)}:function(a,b,c,d){var f=c;dc(a,function(c,l){f=b[r](d,f,c,l,a)});return f},gc=bc[ab]?function(a,b,c){return bc[ab][r](a,b,c)}:function(a,b,c){for(var d=a[C],f=Qb(a)?a[Ha](""):a,h=0;h<d;h++)if(h in f&&b[r](c,f[h],h,a))return!0;return!1};function hc(a,b,c){return 2>=arguments[C]?bc[n][r](a,b):bc[n][r](a,b,c)}function ic(a){for(var b=[],c=0;c<a;c++)b[c]=0;return b}
  function jc(a){for(var b=[],c=0;c<arguments[C];c++){var d=arguments[c];if("array"==Mb(d))for(var f=0;f<d[C];f+=8192)for(var h=jc[wb](null,hc(d,f,f+8192)),l=0;l<h[C];l++)b[x](h[l]);else b[x](d)}return b};function kc(a){var b=[],c=0,d;for(d in a)b[c++]=a[d];return b};var lc;a:{var mc=Jb.navigator;if(mc){var nc=mc.userAgent;if(nc){lc=nc;break a}}lc=""};function oc(a){Jb.setTimeout(function(){throw a;},0)}var pc;
  function qc(){var a=Jb.MessageChannel;"undefined"===typeof a&&"undefined"!==typeof ca&&ca.postMessage&&ca.addEventListener&&-1==lc[$a]("Presto")&&(a=function(){var a=ea.createElement("IFRAME");a.style.display="none";a.src="";ea.documentElement.appendChild(a);var b=a.contentWindow,a=b.document;a.open();a.write("");a[Pa]();var c="callImmediate"+ba.random(),d="file:"==b.location.protocol?"*":b.location.protocol+"//"+b.location.host,a=Yb(function(a){if(("*"==d||a.origin==d)&&a.data==c)this.port1.onmessage()},
  this);b.addEventListener("message",a,!1);this.port1={};this.port2={postMessage:function(){b.postMessage(c,d)}}});if("undefined"!==typeof a&&-1==lc[$a]("Trident")&&-1==lc[$a]("MSIE")){var b=new a,c={},d=c;b.port1.onmessage=function(){if(Kb(c[pb])){c=c[pb];var a=c.ue;c.ue=null;a()}};return function(a){xa(d,{ue:a});d=d[pb];b.port2.postMessage(0)}}return"undefined"!==typeof ea&&"onreadystatechange"in ea.createElement("SCRIPT")?function(a){var b=ea.createElement("SCRIPT");b.onreadystatechange=function(){b.onreadystatechange=
  null;b.parentNode[hb](b);b=null;a();a=null};ea.documentElement.appendChild(b)}:function(a){Jb.setTimeout(a,0)}};function rc(){this.wd=this.gc=null}var tc=new ac(function(){return new sc},function(a){a.reset()},100);rc[t].add=function(a,b){var c=tc.get();c.set(a,b);this.wd?xa(this.wd,c):this.gc=c;this.wd=c};va(rc[t],function(){var a=null;this.gc&&(a=this.gc,this.gc=this.gc[pb],this.gc||(this.wd=null),xa(a,null));return a});function sc(){this.scope=this.Jd=null;xa(this,null)}sc[t].set=function(a,b){this.Jd=a;this.scope=b;xa(this,null)};sc[t].reset=function(){this.scope=this.Jd=null;xa(this,null)};function uc(a,b){vc||wc();xc||(vc(),xc=!0);yc.add(a,b)}var vc;function wc(){if(Jb.Promise&&Jb.Promise[Eb]){var a=Jb.Promise[Eb](void 0);vc=function(){a[z](zc)}}else vc=function(){var a=zc;if(!Rb(Jb[Ta])||Jb.Window&&Jb.Window[t]&&Jb.Window[t][Ta]==Jb[Ta])pc||(pc=qc()),pc(a);else Jb[Ta](a)}}var xc=!1,yc=new rc;function zc(){for(var a=null;a=yc[ib]();){try{a.Jd[r](a.scope)}catch(b){oc(b)}tc.put(a)}xc=!1};function L(a,b){this.Qa=0;this.af=void 0;this.Wc=this.Zb=this.C=null;this.hd=this.Id=!1;if(a!=Lb)try{var c=this;a[r](b,function(a){Ac(c,2,a)},function(a){Ac(c,3,a)})}catch(d){Ac(this,3,d)}}function Bc(){wa(this,null);this.context=this.ec=this.Fc=null;xa(this,null);this.zd=!1}Bc[t].reset=function(){wa(this,null);this.context=this.ec=this.Fc=null;this.zd=!1};var Cc=new ac(function(){return new Bc},function(a){a.reset()},100);function Dc(a,b,c){var d=Cc.get();d.Fc=a;d.ec=b;d.context=c;return d}
  function Ec(a){if(a instanceof L)return a;var b=new L(Lb);Ac(b,2,a);return b}function Fc(a){return new L(function(b,c){c(a)})}function Gc(a,b,c){Hc(a,b,c,null)||uc(Zb(b,a))}function Ic(a){return new L(function(b,c){var d=a[C],f=[];if(d)for(var h=function(a,c){d--;f[a]=c;0==d&&b(f)},l=function(a){c(a)},p=0,y;p<a[C];p++)y=a[p],Gc(y,Zb(h,p),l);else b(f)})}function Jc(){var a,b,c=new L(function(c,f){a=c;b=f});return new Kc(c,a,b)}L[t].then=function(a,b,c){return Lc(this,Rb(a)?a:null,Rb(b)?b:null,c)};
  L[t].then=L[t][z];L[t].$goog_Thenable=!0;function Mc(a,b,c){Lc(a,null,b,c)}function Nc(a,b){a.Zb||2!=a.Qa&&3!=a.Qa||Oc(a);a.Wc?xa(a.Wc,b):a.Zb=b;a.Wc=b}function Lc(a,b,c,d){var f=Dc(null,null,null);wa(f,new L(function(a,l){f.Fc=b?function(c){try{var f=b[r](d,c);a(f)}catch(O){l(O)}}:a;f.ec=c?function(b){try{var f=c[r](d,b);!Kb(f)&&b instanceof Pc?l(b):a(f)}catch(O){l(O)}}:l}));f[jb].C=a;Nc(a,f);return f[jb]}L[t].qg=function(a){this.Qa=0;Ac(this,2,a)};L[t].rg=function(a){this.Qa=0;Ac(this,3,a)};
  function Ac(a,b,c){0==a.Qa&&(a==c&&(b=3,c=new TypeError("Promise cannot resolve to itself")),a.Qa=1,Hc(c,a.qg,a.rg,a)||(a.af=c,a.Qa=b,a.C=null,Oc(a),3!=b||c instanceof Pc||Qc(a,c)))}function Hc(a,b,c,d){if(a instanceof L)return Nc(a,Dc(b||Lb,c||null,d)),!0;var f;if(a)try{f=!!a.$goog_Thenable}catch(h){f=!1}else f=!1;if(f)return a[z](b,c,d),!0;f=typeof a;if("object"==f&&null!=a||"function"==f)try{var l=a[z];if(Rb(l))return Rc(a,l,b,c,d),!0}catch(p){return c[r](d,p),!0}return!1}
  function Rc(a,b,c,d,f){function h(a){p||(p=!0,d[r](f,a))}function l(a){p||(p=!0,c[r](f,a))}var p=!1;try{b[r](a,l,h)}catch(y){h(y)}}function Oc(a){a.Id||(a.Id=!0,uc(a.Gf,a))}function Sc(a){var b=null;a.Zb&&(b=a.Zb,a.Zb=b[pb],xa(b,null));a.Zb||(a.Wc=null);return b}
  L[t].Gf=function(){for(var a=null;a=Sc(this);){var b=this.Qa,c=this.af;if(3==b&&a.ec&&!a.zd)for(var d=void 0,d=this;d&&d.hd;d=d.C)d.hd=!1;if(a[jb])a[jb].C=null,Tc(a,b,c);else try{a.zd?a.Fc[r](a[nb]):Tc(a,b,c)}catch(f){Uc[r](null,f)}Cc.put(a)}this.Id=!1};function Tc(a,b,c){2==b?a.Fc[r](a[nb],c):a.ec&&a.ec[r](a[nb],c)}function Qc(a,b){a.hd=!0;uc(function(){a.hd&&Uc[r](null,b)})}var Uc=oc;function Pc(a){$b[r](this,a)}K(Pc,$b);ja(Pc[t],"cancel");
  function Kc(a,b,c){this.ga=a;this.resolve=b;this.reject=c};/*
  
   Copyright 2014 The Lovefield Project Authors. All Rights Reserved.
  
   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at
  
       http://www.apache.org/licenses/LICENSE-2.0
  
   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.
  */
  function Vc(a,b){this.ka=a;this.o=b||this.ze()}var Wc=0;I=Vc[t];I.id=H("ka");I.ze=function(){return{}};I.jf=H("o");I.Fa=function(){return{id:this.ka,value:this.jf()}};I.Mb=function(a){return"#"==a.substr(-1)?this.ka:null};function Xc(a){return new Vc(a.id,a[v])}function Yc(a){return new Vc(Wc++,a||{})}function Zc(a){if(null==a)return null;a=new Uint8Array(a);for(var b="",c=0;c<a[C];++c)var d=a[c][D](16),b=b+(2>d[C]?"0"+d:d);return b};function $c(a){this.type=a}function ad(a){Vc[r](this,-1,a)}K(ad,Vc);function bd(a,b,c,d){c=c||function(a,b){return a==b};d=d||function(b){return a[b]};for(var f=a[C],h=b[C],l=[],p=0;p<f+1;p++)l[p]=[],l[p][0]=0;for(var y=0;y<h+1;y++)l[0][y]=0;for(p=1;p<=f;p++)for(y=1;y<=h;y++)c(a[p-1],b[y-1])?l[p][y]=l[p-1][y-1]+1:l[p][y]=ba.max(l[p-1][y],l[p][y-1]);for(var O=[],p=f,y=h;0<p&&0<y;)c(a[p-1],b[y-1])?(O.unshift(d(p-1,y-1)),p--,y--):l[p-1][y]>l[p][y-1]?p--:y--;return O}function cd(a){return fc(arguments,function(a,c){return a+c},0)}
  function dd(a){return cd[wb](null,arguments)/arguments[C]}function ed(a){var b=arguments[C];if(2>b)return 0;var c=dd[wb](null,arguments);return cd[wb](null,ec(arguments,function(a){return ba.pow(a-c,2)}))/(b-1)}function fd(a){return ba.sqrt(ed[wb](null,arguments))};var gd="StopIteration"in Jb?Jb.StopIteration:{message:"StopIteration",stack:""};function hd(){}xa(hd[t],function(){throw gd;});hd[t].hc=function(){return this};function id(a){if(a instanceof hd)return a;if("function"==typeof a.hc)return a.hc(!1);if(Pb(a)){var b=0,c=new hd;xa(c,function(){for(;;){if(b>=a[C])throw gd;if(b in a)return a[b++];b++}});return c}throw fa("Not implemented");}
  function jd(a,b){if(Pb(a))try{dc(a,b,void 0)}catch(c){if(c!==gd)throw c;}else{a=id(a);try{for(;;)b[r](void 0,a[pb](),void 0,a)}catch(d){if(d!==gd)throw d;}}}function kd(a){if(gc(arguments,function(a){return!a[C]})||!arguments[C])return new hd;var b=new hd,c=arguments,d=ic(c[C]);xa(b,function(){if(d){for(var a=ec(d,function(a,b){return c[b][a]}),b=d[C]-1;0<=b;b--){if(d[b]<c[b][C]-1){d[b]++;break}if(0==b){d=null;break}d[b]=0}return a}throw gd;});return b};function ld(a,b){this.l={};this.b=[];this.Ka=this.wb=0;var c=arguments[C];if(1<c){if(c%2)throw fa("Uneven number of arguments");for(var d=0;d<c;d+=2)this.set(arguments[d],arguments[d+1])}else a&&this.addAll(a)}I=ld[t];I.tc=H("wb");I.ta=function(){md(this);for(var a=[],b=0;b<this.b[C];b++)a[x](this.l[this.b[b]]);return a};function nd(a){md(a);return a.b[Qa]()}I.Ha=function(a){return od(this.l,a)};I.ld=function(){return 0==this.wb};ta(I,function(){this.l={};this.Ka=this.wb=this.b.length=0});
  va(I,function(a){return od(this.l,a)?(delete this.l[a],this.wb--,this.Ka++,this.b[C]>2*this.wb&&md(this),!0):!1});function md(a){if(a.wb!=a.b[C]){for(var b=0,c=0;b<a.b[C];){var d=a.b[b];od(a.l,d)&&(a.b[c++]=d);b++}a.b.length=c}if(a.wb!=a.b[C]){for(var f={},c=b=0;b<a.b[C];)d=a.b[b],od(f,d)||(a.b[c++]=d,f[d]=1),b++;a.b.length=c}}I.get=function(a,b){return od(this.l,a)?this.l[a]:b};I.set=function(a,b){od(this.l,a)||(this.wb++,this.b[x](a),this.Ka++);this.l[a]=b};
  I.addAll=function(a){var b;if(a instanceof ld)b=nd(a),a=a.ta();else{b=[];var c=0,d;for(d in a)b[c++]=d;a=kc(a)}for(c=0;c<b[C];c++)this.set(b[c],a[c])};Ba(I,function(a,b){for(var c=nd(this),d=0;d<c[C];d++){var f=c[d],h=this.get(f);a[r](b,h,f,this)}});la(I,function(){return new ld(this)});I.hc=function(a){md(this);var b=0,c=this.Ka,d=this,f=new hd;xa(f,function(){if(c!=d.Ka)throw fa("The map has changed since the iterator was created");if(b>=d.b[C])throw gd;var f=d.b[b++];return a?f:d.l[f]});return f};
  function od(a,b){return aa[t][rb][r](a,b)};/*
  
   Copyright 2015 The Lovefield Project Authors. All Rights Reserved.
  
   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at
  
       http://www.apache.org/licenses/LICENSE-2.0
  
   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.
  */
  function pd(){this.l=new ld;aa.defineProperty(this,"size",{get:function(){return this.l.tc()}})}ta(pd[t],function(){this.l[w]()});ta(pd[t],pd[t][w]);ra(pd[t],function(a){return this.l[ib](a)});pd[t]["delete"]=pd[t][Ya];Ba(pd[t],function(a,b){return this.l[F](a,b)});Ba(pd[t],pd[t][F]);pd[t].get=function(a){return this.l.get(a)};pd[t].get=pd[t].get;pd[t].has=function(a){return this.l.Ha(a)};pd[t].has=pd[t].has;pd[t].set=function(a,b){return this.l.set(a,b)};pd[t].set=pd[t].set;
  function M(){return ca.Map&&ca.Map[t][db]&&ca.Map[t][F]?new ca.Map:new pd}function qd(a){if(a instanceof pd)return nd(a.l);var b=0,c=e(a[G]);a[F](function(a,f){c[b++]=f});return c}function rd(a){if(a instanceof pd)return a.l.ta();var b=0,c=e(a[G]);a[F](function(a){c[b++]=a});return c};var sd={};J("lf.TransactionType",sd);sd.READ_ONLY=0;sd.READ_WRITE=1;function td(a,b){this.Na=a;this.kf=b;this.Z=Jc()}td[t].ja=function(){try{ud(this.Na)}catch(a){return Fc(a)}return(0==this.kf?this.kc():vd(this))[z](function(a){this.Na.ja();return a}[E](this))};function vd(a){wd(a);xd(a);return a.kc()}function wd(a){a.Na.mb[F](function(a,c){var d=this.Na.ba().get(c),d=this.I(d[u](),d.$b[E](d)),f=rd(a.za).map(function(a){return a.id()});0<f[C]&&Mc(d[ib](f),this.Ld,this);f=rd(a.ma).map(function(a){return a[1]})[Qa](rd(a.ya));Mc(d.put(f),this.Ld,this)},a)}
  function xd(a){yd(a.Na)[F](function(a){var c=this.I(a[u](),Xc),d;c.get([-1])[z](function(a){d=a;return c[ib]([])})[z](function(){c.put(d);c.put(a.Fa())},this.Ld[E](this))},a)}td[t].Ld=function(a){this.Z[Ja](a)};function zd(a){this.mg=a}g(zd[t],H("mg"));var Ad=new zd("backstore"),Bd=new zd("cache"),Cd=new zd("indexstore"),Dd=new zd("engine"),Ed=new zd("runner"),Fd=new zd("observerregistry"),Gd=new zd("schema");function Hd(a){if("function"==typeof a.ta)return a.ta();if(Qb(a))return a[Ha]("");if(Pb(a)){for(var b=[],c=a[C],d=0;d<c;d++)b[x](a[d]);return b}return kc(a)};function Id(a){this.l=new ld;a&&this.addAll(a)}function Jd(a){var b=typeof a;return"object"==b&&a||"function"==b?"o"+Sb(a):b.substr(0,1)+a}I=Id[t];I.tc=function(){return this.l.tc()};I.add=function(a){this.l.set(Jd(a),a)};I.addAll=function(a){a=Hd(a);for(var b=a[C],c=0;c<b;c++)this.add(a[c])};va(I,function(a){return this.l[ib](Jd(a))});ta(I,function(){this.l[w]()});I.ld=function(){return this.l.ld()};I.contains=function(a){return this.l.Ha(Jd(a))};I.ta=function(){return this.l.ta()};la(I,function(){return new Id(this)});
  I.hc=function(){return this.l.hc(!1)};function Kd(a){this.Tb=new Id(a);aa.defineProperty(this,"size",{get:function(){return this.Tb.tc()}})}Kd[t].add=function(a){this.Tb.add(a)};Kd[t].add=Kd[t].add;ta(Kd[t],function(){this.Tb[w]()});ta(Kd[t],Kd[t][w]);ra(Kd[t],function(a){return this.Tb[ib](a)});Kd[t]["delete"]=Kd[t][Ya];Ba(Kd[t],function(a,b){this.Tb.ta()[F](a,b)});Kd[t].has=function(a){return this.Tb[sb](a)};Kd[t].has=Kd[t].has;function N(a){return ca.Set&&ca.Set[t][db]&&ca.Set[t][F]?Kb(a)?new ca.Set(a):new ca.Set:new Kd(a)}
  function Ld(a){if(a instanceof Kd)return a.Tb.ta();var b=0,c=e(a[G]);a[F](function(a){c[b++]=a});return c}function Md(a,b){if(b[G]>a[G])return!1;var c=!0;b[F](function(b){c=c&&a.has(b)});return c};function Nd(a,b){this.ka=a;this.o=b||{}}function Od(a){var b=N();a[F](function(a){b.add(a>>9)});return Ld(b)}Nd[t].Y=H("ka");function Pd(a,b){b[F](function(a){this.o[a.id()]=a.Fa()},a)}function Qd(a,b){b[F](function(a){delete this.o[a]},a)}Nd[t].Fa=function(){return{id:this.ka,value:ga[xb](this.o)}};function Rd(a){return new Nd(a.id,ga.parse(a[v]))};function Sd(a,b,c){this.X=a;this.Ib=b;this.bf=c}I=Sd[t];I.get=function(a){if(0==a[C])return this.sc();var b=this.Ib;return Td(this,a)[z](function(c){return a.map(function(a){var f=c.get(a>>9);return b(f.o[a])})})};function Td(a,b){var c=M(),d=Jc(),f=Od(b).map(function(a){return new L(function(b,d){var f;try{f=this.X.get(a)}catch(O){d(O);return}ya(f,d);sa(f,function(a){a=Rd(a[Ma][Fb]);c.set(a.Y(),a);b()})},this)},a);Ic(f)[z](function(){d[Eb](c)});return d.ga}
  I.sc=function(){return new L(function(a,b){var c=[],d;try{d=this.X[Da]()}catch(f){b(f);return}ya(d,b);sa(d,function(){var b=d[Fb];if(b){var f;f=Rd(b[v]).o;for(var p in f)c[x](this.Ib(f[p]));b[gb]()}else a(c)}[E](this))},this)};I.Pb=function(a){return new L(function(b,c){var d;try{d=a()}catch(f){c(f);return}sa(d,b);ya(d,c)},this)};
  I.put=function(a){if(0==a[C])return Ec();var b=M();a[F](function(a){var d;d=a.id()>>9;var f=b.get(d)||null;null===f&&(f=this.bf(this.X[q],d));Pd(f,[a]);b.set(d,f)},this);a=rd(b).map(function(a){return this.Pb(function(){return this.X.put(a.Fa())}[E](this))},this);return Ic(a)};
  va(I,function(a){if(0==a[C])return this.Pb(function(){return this.X[w]()}[E](this));var b=M();a[F](function(a){var d=a>>9,f=b.get(d)||null;null===f&&(f=this.bf(this.X[q],d));Qd(f,[a]);b.set(d,f)},this);a=rd(b).map(function(a){return this.Pb(function(){return 0==aa[kb](a.o)[C]?this.X[Ya](a.Y()):this.X.put(a.Fa())}[E](this))},this);return Ic(a)});function Ud(a,b,c){a=a.m(Bd);var d=[c<<9,(c+1<<9)-1];b=a.bb(b,d[0],d[1]);c=new Nd(c);Pd(c,b);return c}function Vd(a,b){return new Nd(b)};function Wd(){};function Xd(a){this.ha=a.m(Bd);this.F=a.m(Cd);this.s=a.m(Gd)}qa(Xd[t],function(a){a[F](function(a){Yd(this,a);Zd(this,a)},this)});function Zd(a,b){var c=b[u]();b.za[F](function(a,b){this.ha[ib](c,b)},a);b.ya[F](function(a){this.ha.set(c,a)},a);b.ma[F](function(a){this.ha.set(c,a[1])},a)}function Yd(a,b){var c=a.s[k](b[u]());$d(b)[F](function(a){ae(this,c,a)},a)}
  function ae(a,b,c){var d=[];(a.F.Lc.get(b[u]())||[])[F](function(a){try{be(a,c),d[x](a)}catch(b){throw d[F](function(a){be(a,[c[1],c[0]])},this),b;}},a)}function be(a,b){var c=null===b[1]?void 0:b[1].Mb(a[u]()),d=null===b[0]?void 0:b[0].Mb(a[u]());if(!Kb(d)&&Kb(c))a.add(c,b[1].id());else if(Kb(d)&&Kb(c)){if(null===c||null===d){if(c==d)return}else if(0==a.lc()[zb](d,c))return;a.add(c,b[1].id());a[ib](d,b[0].id())}else Kb(d)&&!Kb(c)&&a[ib](d,b[0].id())};var ce={};J("lf.ConstraintAction",ce);ce.RESTRICT=0;ce.CASCADE=1;var de={};J("lf.ConstraintTiming",de);de.IMMEDIATE=0;de.DEFERRABLE=1;var ee={};J("lf.Order",ee);ee.DESC=0;ee.ASC=1;var fe={};J("lf.Type",fe);fe.ARRAY_BUFFER=0;fe.BOOLEAN=1;fe.DATE_TIME=2;fe.INTEGER=3;fe.NUMBER=4;fe.STRING=5;fe.OBJECT=6;var ge={0:null,1:!1,2:aa.freeze(new Date(0)),3:0,4:0,5:"",6:null};J("lf.type.DEFAULT_VALUES",ge);function P(a,b){this.code=a;this.message="http://sn.im/2a0j3wn?c="+a;if(1<arguments[C])for(var c=1;c<=ba.min(4,arguments[C]-1);++c)this.message+="&p"+(c-1)+"="+encodeURIComponent(ha(arguments[c][D]()[n](0,64)))}K(P,fa);function he(a){this.F=a.m(Cd);this.s=a.m(Gd);this.ad=null}function ie(a,b,c){var d=b.zb().$f;c[F](function(a){d[F](function(b){if(null==a.o[b[u]()])throw new P(202,b.j());},this)},a)}function je(a,b,c,d){b.zb().Kd()[F](function(a){a[Ka]==d&&ke(this,a,c)},a)}function ke(a,b,c){var d=le(a,b);c[F](function(a){if(me(a[0],a[1],b[q])&&(a=a[1].o[b.Fb],null!==a&&!d.Ha(a)))throw new P(203,b[q]);},a)}
  function le(a,b){null===a.ad&&(a.ad=M());var c=a.ad.get(b[q])||null;null===c&&(c=a.s[k](b.tb)[b.Gc].sa(),c=a.F.get(c.j()),a.ad.set(b[q],c));return c}function me(a,b,c){return(null===a?null!==b:null===b)||a.Mb(c)!=b.Mb(c)}function ne(a,b,c,d){b=oe(a.s[yb](),b[u]());null!=b&&b[F](function(a){if(a[Ka]==d){var b=this.F.get(a[q]),l=le(this,a);c[F](function(c){if(me(c[0],c[1],l[u]())&&b.Ha(c[0].o[a.Gc]))throw new P(203,a[q]);},this)}},a)}
  function pe(a,b,c,d){0!=c[C]&&(c=c.map(function(a){return[null,a]}),je(a,b,c,d))}function qe(a,b,c,d){0!=c[C]&&(je(a,b,c,d),ne(a,b,c,d))}function re(a,b,c,d){0!=c[C]&&(c=c.map(function(a){return[a,null]}),ne(a,b,c,d))};function se(a){this.ya=M();this.ma=M();this.za=M();this.u=a}I=se[t];na(I,H("u"));I.add=function(a){if(this.za.has(a.id())){var b=[this.za.get(a.id()),a];this.ma.set(a.id(),b);this.za[Ya](a.id())}else this.ya.set(a.id(),a)};I.modify=function(a){var b=a[1],c=a[0].id();this.ya.has(c)?this.ya.set(c,b):(this.ma.has(c)&&(a=[this.ma.get(a[0].id())[0],b]),this.ma.set(c,a))};
  ra(I,function(a){if(this.ya.has(a.id()))this.ya[Ya](a.id());else if(this.ma.has(a.id())){var b=this.ma.get(a.id())[0];this.ma[Ya](a.id());this.za.set(a.id(),b)}else this.za.set(a.id(),a)});function $d(a){var b=[];a.ya[F](function(a){b[x]([null,a])});a.ma[F](function(a){b[x](a)});a.za[F](function(a){b[x]([a,null])});return b}g(I,function(){return"["+qd(this.ya)[D]()+"], ["+qd(this.ma)[D]()+"], ["+qd(this.za)[D]()+"]"});
  function te(a){var b=new se(a.u);a.ya[F](function(a){b[Ya](a)});a.za[F](function(a){b.add(a)});a.ma[F](function(a){b.modify([a[1],a[0]])});return b}I.ld=function(){return 0==this.ya[G]&&0==this.za[G]&&0==this.ma[G]};function ue(a,b){this.pa=M();b[F](function(a){this.pa.set(a[u](),a)},this);this.ha=a.m(Bd);this.F=a.m(Cd);this.La=new he(a);this.kd=new Xd(a);this.mb=M()}function yd(a){var b=[];qd(a.mb).map(function(a){return this.pa.get(a)},a)[F](function(a){a.Bb()&&(a.Aa()[F](function(a){b[x](this.F.get(a.j()))},this),b[x](this.F.get(a[u]()+".#")))},a);return b}I=ue[t];I.ba=H("pa");function ve(a){var b=[];a.pa[F](function(a){a.Bb()&&(a.Aa()[F](function(a){b[x](a.j())}),b[x](a[u]()+".#"))});return b}
  I.rb=function(a,b){we(this,a);ie(this.La,a,b);pe(this.La,a,b,0);for(var c=0;c<b[C];c++)xe(this,a,[null,b[c]])};function xe(a,b,c){var d=b[u](),f=a.mb.get(d)||new se(d);a.mb.set(d,f);try{ae(a.kd,b,c)}catch(h){throw h;}b=c[0];var l=c[1];null===b&&null!==l?(a.ha.set(d,l),f.add(l)):null!==b&&null!==l?(a.ha.set(d,l),f.modify(c)):null!==b&&null===l&&(a.ha[ib](d,b.id()),f[Ya](b))}
  qa(I,function(a,b){we(this,a);ie(this.La,a,b);for(var c=0;c<b[C];c++){var d=b[c],d=[this.ha.get(d.id()),d];qe(this.La,a,[d],0);xe(this,a,d)}});I.Nd=function(a,b){we(this,a);ie(this.La,a,b);for(var c=0;c<b[C];c++){var d=b[c],f=null,h,l=a.zb().ed();if(null===l)h=null;else{h=this.La;var l=l.j(),p=d.Mb(l);h=h.F.get(l).get(p);h=0==h[C]?null:h[0]}null!=h?(f=this.ha.get(h),d.ka=h,qe(this.La,a,[[f,d]],0)):pe(this.La,a,[d],0);xe(this,a,[f,d])}};
  va(I,function(a,b){we(this,a);re(this.La,a,b,0);for(var c=0;c<b[C];c++)xe(this,a,[b[c],null])});function ud(a){a.mb[F](function(a){var c=this.pa.get(a[u]());pe(this.La,c,rd(a.ya),1);re(this.La,c,rd(a.za),1);qe(this.La,c,rd(a.ma),1)},a)}I.ja=Gb();I.Cb=function(){var a=rd(this.mb).map(function(a){return te(a)});this.kd[Va](a)};function we(a,b){if(!a.pa.has(b[u]()))throw new P(106,b[u]());};function ye(a,b,c,d){this.c=a;this.w=b;this.$=null===this.c?!1:c;this.ia=null===this.w?!1:d}g(ye[t],function(){return(this.$?"(":"[")+(null===this.c?"unbound":this.c)+", "+(null===this.w?"unbound":this.w)+(this.ia?")":"]")});function ze(a){if(null===a.c&&null===a.w)return[];var b=null,c=null;null===a.c||(b=new ye(null,a.c,!1,!a.$));null===a.w||(c=new ye(a.w,null,!a.ia,!1));return[b,c][Ea](function(a){return null!==a})}ye[t].reverse=function(){return new ye(this.w,this.c,this.ia,this.$)};
  function Ae(a,b){var c=Be(a.c,b.c,!0,a.$,b.$);if(0==c)return!0;var d=-1==c?a:b,c=1==c?a:b;return null===d.w||d.w>c.c||d.w==c.c&&!d.ia&&!c.$}function Ce(){return new ye(null,null,!1,!1)}function De(a){return null===a.c&&null===a.w}function Ee(a){return null!=a.c&&a.c==a.w&&!a.$&&!a.ia}ye[t].contains=function(a){var b=null===this.w||a<this.w||a==this.w&&!this.ia;return(null===this.c||a>this.c||a==this.c&&!this.$)&&b};
  function Be(a,b,c,d,f){function h(a){return c?a:1==a?-1:1}d=d||!1;f=f||!1;return null===a?null===b?(d?!f:f)?d?h(1):h(-1):0:h(-1):null===b?h(1):a<b?-1:a==b?(d?!f:f)?d?h(1):h(-1):0:1}function Fe(a,b){var c=Be(a.c,b.c,!0,a.$,b.$);0==c&&(c=Be(a.w,b.w,!1,a.ia,b.ia));return c};function Ge(a,b){this.entries=a;this.J=N(b);this.Va=null}function Q(a){return Ld(a.J)}function He(a){return a[B].map(function(a){return a.ra.o})}function Ie(a){return a[B].map(function(a){return a.ra.id()})}function Je(a,b){return a.Va.get(b.j())}var Ke=null;function Le(){null===Ke&&(Ke=new Ge([],[]));return Ke}
  function Me(a){if(0==a[C])return Le();for(var b=a[Ia](function(a,b){return a+b[B][C]},0),c=e(b),d=0,b=a.map(function(a){var b=M();a[B][F](function(a){c[d++]=a;b.set(a.id,a)});return b}),f=M(),h=0;h<c[C];h++)b[Ua](function(a){return a.has(c[h].id)})&&f.set(c[h].id,c[h]);return new Ge(rd(f),Ld(a[0].J))}function Ne(a){if(0==a[C])return Le();var b=M();a[F](function(a){a[B][F](function(a){b.set(a.id,a)})});return new Ge(rd(b),Ld(a[0].J))}
  function Oe(a,b){var c=1<b[C],d=a.map(function(a){return new Pe(a,c)});return new Ge(d,b)}function Pe(a,b){this.ra=a;this.id=Qe++;this.Qd=b}var Qe=0;function Re(a,b){var c=b.Wa();return null!==c&&a.ra.o[rb](c)?a.ra.o[c]:a.Qd?a.ra.o[Se(b.I())][b[u]()]:a.ra.o[b[u]()]}function Te(a,b,c){var d=b.Wa();if(null!=d)a.ra.o[d]=c;else if(a.Qd){var d=Se(b.I()),f=a.ra.o[d];null==f&&(f={},a.ra.o[d]=f);f[b[u]()]=c}else a.ra.o[b[u]()]=c}
  function Ue(a,b,c,d){function f(a,b){if(a.Qd){var c=a.ra.o,d;for(d in c)h[d]=c[d]}else h[b[0]]=a.ra.o}var h={};f(a,b);f(c,d);a=new Vc(-1,h);return new Pe(a,!0)};J("lf.bind",function(a){return new Ve(a)});function Ve(a){this.ca=a}J("lf.Binder",Ve);Ve[t].sa=H("ca");function We(){this.Le=Xe();var a=Ye();this.cc=M();this.cc.set(1,Ze());this.cc.set(2,$e());this.cc.set(4,a);this.cc.set(3,a);this.cc.set(5,af())}We.cd=function(){return We.He?We.He:We.He=new We};function bf(a,b,c){return(a.cc.get(b)||null).get(c)||null}function Xe(){function a(a){return a}var b=M();b.set(1,function(a){return null===a?null:a?1:0});b.set(2,function(a){return null===a?null:a[Db]()});b.set(3,a);b.set(4,a);b.set(5,a);return b}
  function Ze(){var a=M();a.set("eq",function(a,c){return a==c});a.set("neq",function(a,c){return a!=c});return a}
  function Ye(){var a=Ze();a.set("between",function(a,c){return null===a||null===c[0]||null===c[1]?!1:a>=c[0]&&a<=c[1]});a.set("gte",function(a,c){return null===a||null===c?!1:a>=c});a.set("gt",function(a,c){return null===a||null===c?!1:a>c});a.set("in",function(a,c){return-1!=c[$a](a)});a.set("lte",function(a,c){return null===a||null===c?!1:a<=c});a.set("lt",function(a,c){return null===a||null===c?!1:a<c});return a}
  function af(){var a=Ye();a.set("match",function(a,c){return null===a||null===c?!1:(new RegExp(c)).test(a)});return a}
  function $e(){var a=M();a.set("between",function(a,c){return null===a||null===c[0]||null===c[1]?!1:a[Db]()>=c[0][Db]()&&a[Db]()<=c[1][Db]()});a.set("eq",function(a,c){return(null===a?-1:a[Db]())==(null===c?-1:c[Db]())});a.set("gte",function(a,c){return null===a||null===c?!1:a[Db]()>=c[Db]()});a.set("gt",function(a,c){return null===a||null===c?!1:a[Db]()>c[Db]()});a.set("in",function(a,c){return c[ab](function(c){return c[Db]()==a[Db]()})});a.set("lte",function(a,c){return null===a||null===c?!1:a[Db]()<=
  c[Db]()});a.set("lt",function(a,c){return null===a||null===c?!1:a[Db]()<c[Db]()});a.set("neq",function(a,c){return(null===a?-1:a[Db]())!=(null===c?-1:c[Db]())});return a};function cf(){this.g=this.C=null}var df=[];cf[t].getParent=H("C");cf[t].cb=function(){for(var a=this;!Nb(a[Ab]());)a=a[Ab]();return a};function ef(a){for(var b=0;!Nb(a[Ab]());)b++,a=a[Ab]();return b}function R(a){return a.g||df}function ff(a,b){return R(a)[b]||null}function gf(a,b,c){b.C=a;null===a.g?a.g=[b]:a.g[A](c,0,b)}function hf(a,b){b.C=a;null===a.g?a.g=[b]:a.g[x](b)}function jf(a,b){var c=a.g&&a.g[b];return c?(c.C=null,a.g[A](b,1),0==a.g[C]&&(a.g=null),c):null}
  cf[t].removeChild=function(a){return jf(this,R(this)[$a](a))};function kf(a,b,c){ff(a,c).C=null;b.C=a;a.g[c]=b}function mf(a,b,c){!1!==b[r](c,a)&&R(a)[F](function(a){mf(a,b,c)})};function nf(){cf[r](this);this.ka=of++}K(nf,cf);var of=0;nf[t].Y=H("ka");function pf(a,b,c){nf[r](this);this.K=a;pa(this,b);this.L=c;this.$c=bf(We.cd(),this.K.S(),this.L);this.Xa=!1;this.Yb=b}K(pf,nf);I=pf[t];I.Gb=function(){var a=new pf(this.K,this[v],this.L);a.Yb=this.Yb;a.ud(this.Xa);var b=this.Y();a.ka=b;return a};I.ab=function(a){return null!=a?(a[x](this.K),a):[this.K]};I.ud=Hb("Xa");function qf(a){var b=!1;a[v]instanceof Ve||(b="array"==Mb(a[v])?!a[v][ab](function(a){return a instanceof Ve}):!0);if(!b)throw new P(501);}
  I.eval=function(a){qf(this);if("in"==this.L)return rf(this,a);var b=a[B][Ea](function(a){return this.$c(Re(a,this.K),this[v])!=this.Xa},this);return new Ge(b,Q(a))};za(I,function(a){if(this.Yb instanceof Ve){var b=this.Yb.sa();if(a[C]<=b)throw new P(510);pa(this,a[b])}else"array"==Mb(this.Yb)&&pa(this,this.Yb.map(function(b){if(b instanceof Ve){var d=b.sa();if(a[C]<=d)throw new P(510);return a[b.sa()]}return b}))});
  function rf(a,b){var c=N(a[v]),d=function(a){return null===a?!1:c.has(a)!=this.Xa}[E](a),f=b[B][Ea](function(a){return d(Re(a,this.K))},a);return new Ge(f,Q(b))}g(I,function(){return"value_pred("+this.K.j()+" "+this.L+(this.Xa?"(complement)":"")+" "+this[v]+")"});function sf(a){this.da=a;this.Xc=this.wa=null}function tf(a,b){null===a.wa&&null!=a.B&&(a.wa=uf(a.B));return a.wa.get(b)||null}function uf(a){var b=M();mf(a,function(a){b.set(a.Y(),a)});return b}function vf(a,b){b.B&&(a.B=b.B.Gb());a.Xc=b}za(sf[t],function(){return this});function wf(a,b){var c=a.B;null!=c&&mf(c,function(a){a instanceof pf&&a[E](b)})};function xf(a){sf[r](this,a)}K(xf,sf);function yf(a){var b="";a[F](function(c,d){b+=c.K.j()+" ";b+=1==c.gb?"ASC":"DESC";d<a[C]-1&&(b+=", ")});return b}xf[t].ba=function(){return N(this.c)};la(xf[t],function(){var a=new xf(this.da);vf(a,this);this.f&&(a.f=this.f[n]());this.c&&(a.c=this.c[n]());a.W=this.W;a.N=this.N;this.M&&(a.M=this.M[n]());this.ea&&(a.ea=this.ea[n]());this.Nb&&(a.Nb=this.Nb);this.Vb&&(a.Vb=this.Vb);a.sb=this.sb;return a});
  za(xf[t],function(a){xf.Db[E][r](this,a);null!=this.Nb&&(this.W=a[this.Nb.sa()]);null!=this.Vb&&(this.N=a[this.Vb.sa()]);wf(this,a);return this});function zf(a,b){this.xa=a;this.pa=b}zf[t].cb=H("xa");zf[t].ba=H("pa");function Af(a){var b=N();a[F](function(a){a.ba()[F](b.add[E](b))});return b};function Bf(a,b){this.global=a;this.vb=a.m(Ad);this.rd=b.map(function(a){return a[nb]});this.Ve=b.map(function(a){return a.ae});this.xe=Af(this.Ve);this.lf=Cf(this);this.Rb=Jc()}function Cf(a){return a.rd[ab](function(a){return!(a instanceof xf)})?1:0}I=Bf[t];
  ma(I,function(){function a(){var h=d[qb]();if(h){var l=f[c[C]];return h.cb()[Oa](b,l)[z](function(b){c[x](b[0]);return a()})}return Ec()}var b=new ue(this[Wa],this.xe),c=[],d=this.Ve[n](),f=this.rd;return a()[z](function(){return this.vb.Hb(this.lf,b).ja()}[E](this))[z](function(){this.Yd(c);return c}[E](this),function(a){b.Cb();throw a;})});I.S=H("lf");I.ba=H("xe");I.uc=H("Rb");I.Y=function(){return Sb(this)};I.Yd=Gb();function Df(a,b){Bf[r](this,a,b);this.Ab=a.m(Fd)}K(Df,Bf);Ca(Df[t],Ib(0));Df[t].Yd=function(a){this.rd[F](function(b,c){Ef(this.Ab,b,a[c])},this)};function Ff(a,b){this.i=a;this.Ab=a.m(Fd);this.Pa=a.m(Ed);this.kd=new Xd(a);this.mb=b;var c=a.m(Gd),d=this.mb.map(function(a){return c[k](a[u]())});this.pa=N(d);this.Rb=Jc()}I=Ff[t];ma(I,function(){this.kd[Va](this.mb);this.Jc();return Ec()});I.S=Ib(1);I.ba=H("pa");I.uc=H("Rb");I.Y=function(){return Sb(this)};Ca(I,Ib(1));I.Jc=function(){var a=Gf(this.Ab,this.pa);0!=a[C]&&(a=new Df(this.i,a),Hf(this.Pa,a))};function If(a){this.i=a;this.vb=a.m(Ad);this.Pa=a.m(Ed)}If[t].Wd=function(a){a=new Ff(this.i,a);Hf(this.Pa,a)};function S(a,b){this.Ka=a;this.h=b;this.Sa=M()}J("lf.backstore.FirebaseRawBackStore",S);S[t].fd=H("h");S[t].gd=function(){throw new P(351);};function Jf(a,b){var c=Jc(),d=a;b[C]&&(d=a[jb](b));d[Fa]("value",function(a){c[Eb](a.val())},function(a){c[Ja](a)});return c.ga}function Kf(a,b,c){function d(a){a?f[Ja](a):f[Eb]()}c=c||!1;var f=Jc();c?a.set(b,d):a[Va](b,d);return f.ga}
  S[t].Ba=function(a){return Jf(this.h,"@rev/R")[z](function(a){this.Ia=a;return Jf(this.h,"@table")}[E](this))[z](function(b){var c=0,d;for(d in b)this.Sa.set(d,b[d]),b[d]>c&&(c=b[d]);a.Ta()[F](function(a){this.Sa.has(a[u]())||(b[a[u]()]=++c)},this);d=this.h[jb]("@table");return Kf(d,b)}[E](this))};
  function Lf(a,b,c){var d=a.Sa.get(b);return null!=d?function(){var a={},b=Jc();this.h[cb]("T").equalTo(d)[Fa]("value",function(d){d[F](function(b){var d=c(b.val());a[da(b.key(),10)]=d});b[Eb](a)});return b.ga}[r](a)[z](function(a){a["@rev"]={R:++this.Ia};return Kf(this.h,a)}[E](a)):Ec()}S[t].nc=function(a){return Lf(this,a,Ib(null))[z](function(){this.Sa[Ya](a);return Kf(this.h[jb]("@table/"+a),null,!0)}[E](this))};S[t].dropTable=S[t].nc;
  S[t].ic=function(a,b,c){return Lf(this,a,function(a){var f=a.P;f[b]=c;return{R:this.Ia+1,T:a.T,P:f}}[E](this))};S[t].addTableColumn=S[t].ic;S[t].oc=function(a,b){return Lf(this,a,function(a){var d=a.P;delete d[b];return{R:this.Ia+1,T:a.T,P:d}}[E](this))};S[t].dropTableColumn=S[t].oc;S[t].Ic=function(a,b,c){return Lf(this,a,function(a){var f=a.P;f[c]=f[b];delete f[b];return{R:this.Ia+1,T:a.T,P:f}}[E](this))};S[t].renameTableColumn=S[t].Ic;S[t].xb=function(){throw new P(351);};S[t].createRow=S[t].xb;
  S[t].xc=H("Ka");S[t].getVersion=S[t].xc;S[t].ac=function(a){var b=Jc();a=this.Sa.get(a);this.h[cb]("T").equalTo(a)[Fa]("value",function(a){var d=[];a[F](function(a){d[x](a.val().P)});b[Eb](d)});return b.ga};ka(S[t],function(){var a={},b=qd(this.Sa).map(function(b){return this.ac(b)[z](function(d){a[b]=d})}[E](this));return Ic(b)[z](function(){return a})});ka(S[t],S[t].dump);function Mf(a,b,c){td[r](this,c,b);this.h=a}K(Mf,td);Mf[t].I=function(a){return this.h.vc(a)};
  Mf[t].kc=function(){var a=this.Na.mb;if(0==a[G])this.Z[Eb]();else{var b=this.h.Ia+1;this.h.Ia=b;var c={"@rev":{R:b}};a[F](function(a,f){var h=this.h.Sa.get(f);a.ya[F](function(a,d){c[d]={R:b,T:h,P:a.o}});a.ma[F](function(a,d){c[d]={R:b,T:h,P:a[1].o}});a.za[F](function(a,b){c[b]=null})},this);this.h.h[Va](c,function(c){if(null===c)this.Z[Eb]();else this.h.Ia=b-1,c=rd(a).map(function(a){return Nf(this.h,a[u]())},this),Ic(c)[z](this.Z[Ja][E](this.Z),this.Z[Ja][E](this.Z))}[E](this))}return this.Z.ga};function Of(){this.ob=M()}function Pf(a,b){if(0==b[C])return rd(a.ob);var c=[];b[F](function(a){a=this.ob.get(a)||null;null===a||c[x](a)},a);return c}Of[t].getData=H("ob");Of[t].get=function(a){return Ec(Pf(this,a))};function Qf(a,b){b[F](function(a){this.ob.set(a.id(),a)},a)}Of[t].put=function(a){Qf(this,a);return Ec()};function Rf(a,b){0==b[C]||b[C]==a.ob[G]?a.ob[w]():b[F](function(a){this.ob[Ya](a)},a)}va(Of[t],function(a){Rf(this,a);return Ec()});
  function Sf(a){return 0==a.ob[G]?0:qd(a.ob)[Ia](function(a,c){return a>c?a:c},0)};function Tf(a,b){this.s=a;this.rf=b;this.Hc=M();this.Ia=-1;this.J=M();this.Sa=M();this.Cd=null}I=Tf[t];
  I.Ba=function(a){this.h=this.rf[jb](this.s[q]());var b=a||function(){return Ec()};return Jf(this.h,"@db/version")[z](function(a){return null===a?Kf(this.h,Uf(this),!0)[z](function(){var a=new S(0,this.h);return b(a)}[E](this)):a==this.s[tb]()?Jf(this.h,"@rev/R")[z](function(a){this.Ia=a;return Jf(this.h,"@table")}[E](this))[z](function(a){for(var b in a)this.Sa.set(b,a[b]);a=this.s.Ta().map(function(a){return Nf(this,a[u]())},this);return Ic(a)}[E](this))[z](function(){Vf(this);Wf(this);return Ec()}[E](this)):
  this.Zd(a,b)[z](function(){return this.Ba()}[E](this))}[E](this))};I.Zd=function(a,b){var c=new S(a,this.h);return c.Ba(this.s)[z](function(){return Ec()}[E](this))[z](function(){return b(c)})[z](function(){var a=this.h[jb]("@db");return Kf(a,{version:this.s[tb]()},!0)}[E](this))};function Wf(a){a.h.off();a.h.on("child_removed",a.bg[E](a));a.Dd&&(a.Dd.off(),a.Hc[w]());a.Dd=a.h[cb]("R").startAt(a.Ia+1);a.Dd.on("value",a.Wd[E](a))}
  function Vf(a){Wc=rd(a.J).map(function(a){return Sf(a)})[Ia](function(a,c){return a>c?a:c},0)+1}I.bg=function(a){var b=a.val(),c=this.Hc.get(b.T)||null;null===c&&(c=N(),this.Hc.set(b.T,c));c.add(da(a.key(),10))};I.Wd=function(a){var b=a[jb]("@rev/R").val();null!=b&&b!=this.Ia&&(this.Ia=b,a=Xf(this,a),a[F](function(a){var b=this.J.get(a[u]()),f=qd(a.za);0<f[C]&&Rf(b,f);var h=rd(a.ya);a.ma[F](function(a){h[x](a[1])});Qf(b,h)},this),0<a[C]&&this.Cc(a),Wf(this))};
  function Xf(a,b){var c=N(),d=M();a.Sa[F](function(a,b){var l=this.J.get(b),p=new se(b);if(this.Hc.has(a)){var y=Ld(this.Hc.get(a));y[F](function(a){c.add(a)});Pf(l,y)[F](function(a){p[Ya](a)})}d.set(a,p)}[E](a));b[F](function(a){if("@rev"!=a.key()){var b=da(a.key(),10);if(!c.has(b)){a=a.val();var l=d.get(a.T),p=this.J.get(l[u]());p.getData().has(b)?l.modify([Pf(p,[b])[0],new Vc(b,a.P)]):l.add(new Vc(b,a.P))}}}[E](a));return rd(d)[Ea](function(a){return!a.ld()})}
  function Nf(a,b){var c=Jc(),d=a.Sa.get(b);a.h[cb]("T").equalTo(d)[Fa]("value",function(a){var d=new Of,l=[];a[F](function(a){l[x](new Vc(da(a.key(),10),a.val().P))});Qf(d,l);this.J.set(b,d);c[Eb]()}[E](a));return c.ga}function Uf(a){var b={};b["@db"]={version:a.s[tb]()};b["@rev"]={R:1};a.Ia=1;b["@table"]={};a.s.Ta()[F](function(a,d){var f=a[u]();b["@table"][f]=d;this.J.set(f,new Of);this.Sa.set(f,d)},a);return b}I.Hb=function(a,b){return new Mf(this,a,b)};
  I.vc=function(a){var b=this.J.get(a)||null;if(null!==b)return b;throw new P(101,a);};oa(I,Gb());Aa(I,Hb("Cd"));I.Cc=function(a){null!=this.Cd&&this.Cd(a)};function T(a,b,c,d){this.h=b;this.Ja=c;this.Ka=a;this.Uc=d}J("lf.backstore.IndexedDBRawBackStore",T);T[t].fd=H("h");T[t].getRawDBInstance=T[t].fd;T[t].gd=H("Ja");T[t].getRawTransaction=T[t].gd;T[t].nc=function(a){return new L(function(b,c){try{this.h.deleteObjectStore(a)}catch(d){c(d);return}b()},this)};T[t].dropTable=T[t].nc;
  function Yf(a,b,c,d){return new L(function(a,h){var l;try{var p=this.Ja[ub](b);l=p[Da]()}catch(y){h(y);return}sa(l,function(){var b=l[Fb];b?(c(b),b[gb]()):(d(p),a())});ya(l,h)},a)}function Zf(a){var b=null;return b=a instanceof ArrayBuffer?Zc(a):a instanceof Date?a[Db]():a}function $f(a,b,c){function d(a){var b=Rd(a[v]),d=b.o,f;for(f in d){var O=Xc(d[f]);c(O);d[f]=O.Fa()}a[Va](b.Fa())}function f(a){var b=Xc(a[v]);c(b);a[Va](b.Fa())}return Yf(a,b,a.Uc?d:f,Gb())}
  T[t].ic=function(a,b,c){var d=Zf(c);return $f(this,a,function(a){a.o[b]=d})};T[t].addTableColumn=T[t].ic;T[t].oc=function(a,b){return $f(this,a,function(a){delete a.o[b]})};T[t].dropTableColumn=T[t].oc;T[t].Ic=function(a,b,c){return $f(this,a,function(a){a.o[c]=a.o[b];delete a.o[b]})};T[t].renameTableColumn=T[t].Ic;
  function ag(a,b){var c=[];return new L(function(a,f){var h;try{h=this.Ja[ub](b)[Da]()}catch(l){f(l);return}sa(h,function(){var b=h[Fb];if(b){if(this.Uc){var f;f=Rd(b[v]).o;for(var l in f)c[x](f[l])}else c[x](b[v]);b[gb]()}else a(c)}[E](this));ya(h,f)},a)}T[t].xb=function(a){var b={},c;for(c in a)b[c]=Zf(a[c]);return Yc(b)};T[t].createRow=T[t].xb;T[t].xc=H("Ka");T[t].getVersion=T[t].xc;
  ka(T[t],function(){for(var a=this.h[Ga],b=[],c=0;c<a[C];++c){var d=a[La](c);b[x](this.ac(d))}return Ic(b)[z](function(b){var c={};b[F](function(b,d){c[a[La](d)]=b});return c})});ka(T[t],T[t].dump);T[t].ac=function(a){return ag(this,a)[z](function(a){return a.map(function(a){return a[v]})})};function bg(a,b){this.X=a;this.Ib=b}I=bg[t];I.get=function(a){if(0==a[C])return this.sc();a=a.map(function(a){return new L(function(c,d){var f;try{f=this.X.get(a)}catch(h){d(h);return}ya(f,d);sa(f,function(a){c(this.Ib(a[Ma][Fb]))}[E](this))},this)},this);return Ic(a)};I.sc=function(){return new L(function(a,b){var c=[],d;try{d=this.X[Da]()}catch(f){b(f);return}ya(d,b);sa(d,function(){var b=d[Fb];b?(c[x](this.Ib(b[v])),b[gb]()):a(c)}[E](this))},this)};
  I.Pb=function(a){return new L(function(b,c){var d;try{d=a()}catch(f){c(f);return}sa(d,b);ya(d,c)},this)};I.put=function(a){if(0==a[C])return Ec();a=a.map(function(a){return this.Pb(function(){return this.X.put(a.Fa())}[E](this))},this);return Ic(a)};
  va(I,function(a){return new L(function(b,c){var d=this.X[bb]();sa(d,function(d){if(0==a[C]||d[Ma][Fb]==a[C])return this.Pb(function(){return this.X[w]()}[E](this))[z](b,c);d=a.map(function(a){return this.Pb(function(){return this.X[Ya](a)}[E](this))},this);Ic(d)[z](b,c)}[E](this));ya(d,c)},this)});function cg(a,b,c,d,f){td[r](this,c,d);this.i=a;this.Ja=b;this.Uc=f;this.Ja.oncomplete=this.Z[Eb][E](this.Z);this.Ja.onabort=this.Z[Ja][E](this.Z)}K(cg,td);cg[t].I=function(a,b,c){return this.Uc?(c=null!=c?c:0,a=this.Ja[ub](a),new Sd(a,b,0==c?Zb(Ud,this.i):Vd)):new bg(this.Ja[ub](a),b)};cg[t].kc=function(){return this.Z.ga};function dg(a,b){this.i=a;this.s=b;this.Vc=b.We().Df||!1}I=dg[t];I.Ba=function(a){var b=ca.indexedDB||ca.mozIndexedDB||ca.webkitIndexedDB||ca.msIndexedDB;if(null==b)throw new P(352);var c=a||function(){return Ec()};return new L(function(a,f){var h;try{h=b.open(this.s[q](),this.s[tb]())}catch(l){f(l);return}ya(h,f);h.onupgradeneeded=function(a){eg(this,c,a)[z](Gb(),f)}[E](this);sa(h,function(b){this.h=b[Ma][Fb];this.fe()[z](function(b){Wc=b+1;a(this.h)}[E](this))}[E](this))},this)};
  function eg(a,b,c){var d=c[Ma][Fb],f=c[Ma][lb];c=new T(c.oldVersion,d,f,a.Vc);fg(d);a.s.Ta()[F](Zb(a.yf,d,f),a);return b(c)}function fg(a){for(var b=[],c=0;c<a[Ga][C];++c){var d=a[Ga][La](c);-1!=d[$a](".")&&b[x](d)}b[F](function(b){try{a.deleteObjectStore(b)}catch(c){}})}I.yf=function(a,b,c){a[Ga][sb](c[u]())||a.createObjectStore(c[u](),{keyPath:"id"});c.Bb()&&(c.Aa()[F](function(c){this.mc(a,b,c.j(),"btree")},this),this.mc(a,b,c.u+".#","rowid"))};
  I.mc=function(a,b,c,d){a[Ga][sb](c)||(a.createObjectStore(c,{keyPath:"id"}),a=b[ub](c),(this.Vc?new Sd(a,Xc,Vd):new bg(a,Xc)).put([new ad(new $c(d))]))};I.Hb=function(a,b){var c=qd(b.ba());ve(b)[F](function(a){c[x](a)});var d=this.h[lb](c,0==a?"readonly":"readwrite");return new cg(this.i,d,b,a,this.Vc)};
  I.fe=function(a){function b(){if(0==d[C])return Ec();var a=d[qb]();return c(a)[z](b)}function c(b){return new L(function(c,d){var Ra;try{Ra=(a||f[lb]([b]))[ub](b)[Da](null,"prev")}catch(Sa){d(Sa);return}sa(Ra,function(a){(a=a[Ma][Fb])&&(h=ba.max(h,l(a)));c(h)});ya(Ra,function(){c(h)})})}var d=this.s.Ta().map(function(a){return a[u]()}),f=this.h,h=0,l=function(a){return this.Vc?(a=Rd(a[v]),aa[kb](a.o)[Ia](function(a,b){return ba.max(a,b)},0)):a.key}[E](this);return new L(function(a){b()[z](function(){a(h)})})};
  oa(I,function(){this.h[Pa]()});I.vc=function(){throw new P(511);};Aa(I,Gb());I.Cc=Gb();function gg(a,b,c){td[r](this,c,b);this.X=a;0==b&&this.Z[Eb]()}K(gg,td);gg[t].I=function(a){return this.X.vc(a)};gg[t].kc=function(){this.Z[Eb]();return this.Z.ga};function hg(a){this.s=a;this.J=M()}I=hg[t];I.Ba=function(){this.s.Ta()[F](this.Of,this);return Ec()};I.vc=function(a){var b=this.J.get(a)||null;if(null===b)throw new P(101,a);return b};I.Hb=function(a,b){return new gg(this,a,b)};function ig(a,b){if(!a.J.has(b)){var c=new Of;a.J.set(b,c);return c}return null}I.Of=function(a){ig(this,a[u]());a.Bb()&&(a.Aa()[F](function(a){this.mc(a.j(),"btree")},this),this.mc(a.u+".#","rowid"))};I.mc=function(a,b){var c=ig(this,a);null===c||c.put([new ad(new $c(b))])};
  oa(I,Gb());Aa(I,Gb());I.Cc=Gb();function jg(a){hg[r](this,a);this.nd=null}K(jg,hg);Aa(jg[t],function(a){null===this.nd&&(this.nd=a)});jg[t].Cc=function(a){null===this.nd||this.nd(a)};function kg(a,b,c){this.Ja=a;this.u=b;this.Ib=c}kg[t].get=function(a){var b=this.Ib;lg(this.Ja,"SELECT id, value FROM "+this.u+" "+(0==a[C]?"":"WHERE id IN ("+a[m](",")+")"),[],function(a){for(var d=a[Bb][C],f=e(d),h=0;h<d;++h)f[h]=b({id:a[Bb][La](h).id,value:ga.parse(a[Bb][La](h)[v])});return f});return this.Ja.ja()};kg[t].put=function(a){if(0==a[C])return Ec();var b="INSERT OR REPLACE INTO "+this.u+"(id, value) VALUES (?, ?)";a[F](function(a){lg(this.Ja,b,[a.id(),ga[xb](a.o)])},this);return Ec()};
  va(kg[t],function(a){lg(this.Ja,"DELETE FROM "+this.u+" "+(0==a[C]?"":"WHERE id IN ("+a[m](",")+")"),[]);return Ec()});function mg(a,b,c){td[r](this,b,c);this.h=a;this.J=M();this.Fd=[]}K(mg,td);mg[t].I=function(a,b){var c=this.J.get(a)||null;null===c&&(c=new kg(this,a,b),this.J.set(a,c));return c};function lg(a,b,c,d){a.Fd[x]({og:b,eg:c,transform:d})}
  mg[t].kc=function(){var a,b,c=this.Z[Ja][E](this.Z),d=function(a,b){this.Z[Ja](b)}[E](this),f=function(c,l){a=l;if(this.Fd[C]){var p=this.Fd[qb]();b=p.transform;c.executeSql(p.og,p.eg,f,d)}else p=a,null!=b&&null!=a&&(p=b(a)),this.Z[Eb](p)}[E](this);0==this.kf?this.h.readTransaction(f,c):this.h[lb](f,c);return this.Z.ga};function U(a,b,c){this.h=c;this.i=a;this.Ka=b}J("lf.backstore.WebSqlRawBackStore",U);U[t].fd=H("h");U[t].getRawDBInstance=U[t].fd;U[t].gd=function(){throw new P(356);};U[t].getRawTransaction=U[t].gd;function ng(a){return new mg(a.h,new ue(a.i,N()),1)}U[t].nc=function(a){var b=ng(this);lg(b,"DROP TABLE "+a,[]);return b.ja()};U[t].dropTable=U[t].nc;
  U[t].ac=function(a){var b=ng(this);lg(b,"SELECT id, value FROM "+a,[]);return b.ja()[z](function(a){for(var b=a[Bb][C],f=e(b),h=0;h<b;++h)f[h]={id:a[Bb][La](h).id,value:ga.parse(a[Bb][La](h)[v])};return Ec(f)})};function og(a,b,c){var d=ng(a),f="UPDATE "+b+" SET value=? WHERE id=?";return a.ac(b)[z](function(a){a[F](function(a){a=c(a);lg(d,f,[ga[xb](a[v]),a.id])});return d.ja()})}U[t].ic=function(a,b,c){var d=Zf(c);return og(this,a,function(a){a[v][b]=d;return a})};U[t].addTableColumn=U[t].ic;
  U[t].oc=function(a,b){return og(this,a,function(a){delete a[v][b];return a})};U[t].dropTableColumn=U[t].oc;U[t].Ic=function(a,b,c){return og(this,a,function(a){a[v][c]=a[v][b];delete a[v][b];return a})};U[t].renameTableColumn=U[t].Ic;U[t].xb=function(a){var b={},c;for(c in a)b[c]=Zf(a[c]);return Yc(b)};U[t].createRow=U[t].xb;U[t].xc=H("Ka");U[t].getVersion=U[t].xc;
  function pg(a){lg(a,'SELECT tbl_name FROM sqlite_master WHERE type="table"',[],function(a){for(var c=e(a[Bb][C]),d=0;d<c[C];++d)c[d]=a[Bb][La](d).tbl_name;return c})}ka(U[t],function(){var a=Jc(),b=ng(this);pg(b);var c={};b.ja()[z](function(b){b=b[Ea](function(a){return"__lf_ver"!=a&&"__WebKitDatabaseInfoTable__"!=a}).map(function(a){return this.ac(a)[z](function(b){c[a]=b})},this);Ic(b)[z](function(){a[Eb](c)})}[E](this));return a.ga});ka(U[t],U[t].dump);function qg(a,b,c){this.i=a;this.s=b;this.ng=c||4194304}function rg(a){return new ue(a.i,N())}I=qg[t];I.Ba=function(a){if(null==ca.openDatabase)throw new P(353);var b=a||function(){return Ec()};return new L(function(a,d){try{var f=ca.openDatabase(this.s[q](),"",this.s[q](),this.ng);if(null!=f)this.h=f,sg(this,b)[z](a,d);else throw new P(354);}catch(h){d(h)}},this)};
  function sg(a,b){var c=Jc(),d=new mg(a.h,rg(a),1);lg(d,"CREATE TABLE IF NOT EXISTS __lf_ver(id INTEGER PRIMARY KEY, v INTEGER)",[]);lg(d,"SELECT v FROM __lf_ver WHERE id = 0",[]);d.ja()[z](function(a){var d=0;a[Bb][C]&&(d=a[Bb][La](0).v);d<this.s[tb]()?this.Zd(b,d)[z](c[Eb][E](c)):d>this.s[tb]()?c[Ja](new P(108)):c[Eb]()}[E](a));return c.ga}I.Hb=function(a,b){if(null!=this.h)return new mg(this.h,b,a);throw new P(2);};oa(I,Gb());I.vc=function(){throw new P(512);};Aa(I,function(){throw new P(355);});
  I.Cc=function(){throw new P(355);};I.Zd=function(a,b){var c=Jc();tg(this)[z](function(){a(new U(this.i,b,this.h))[z](function(){return this.fe()}[E](this))[z](c[Eb][E](c))}[E](this),c[Ja][E](c));return c.ga};
  function tg(a){var b=a.s.Ta(),c=new mg(a.h,rg(a),1),d=new mg(a.h,rg(a),1);lg(c,"INSERT OR REPLACE INTO __lf_ver VALUES (0, ?)",[a.s[tb]()]);pg(c);return c.ja()[z](function(a){a[Ea](function(a){return-1!=a[$a](".")})[F](function(a){lg(d,"DROP TABLE "+a,[])});var c=a[Ea](function(a){return-1==a[$a](".")});b.map(function(a){return a[u]()})[Ea](function(a){return-1==c[$a](a)})[F](function(a){lg(d,"CREATE TABLE "+a+"(id INTEGER PRIMARY KEY, value TEXT)",[])});return d.ja()})}
  I.fe=function(){var a=0,b=Jc(),c=function(b){var c=new mg(this.h,rg(this),0);lg(c,"SELECT MAX(id) FROM "+b,[]);return c.ja()[z](function(b){b=b[Bb][La](0)[0];a=ba.max(b,a)})}[E](this),d=this.s.Ta().map(function(a){return c(a[u]())});Ic(d)[z](function(){b[Eb](a)},function(a){b[Ja](a)});return b.ga};function ug(){this.l=M();this.ke=M()}function vg(a,b){var c=a.ke.get(b);Kb(c)||(c=N(),a.ke.set(b,c));return c}I=ug[t];I.set=function(a,b){this.l.set(b.id(),b);vg(this,a).add(b.id())};I.he=function(a,b){var c=vg(this,a);b[F](function(a){this.l.set(a.id(),a);c.add(a.id())},this)};I.get=function(a){return this.l.get(a)||null};function wg(a,b){return b.map(function(a){return this.get(a)},a)}
  I.bb=function(a,b,c){var d=[],f=ba.min(b,c),h=ba.max(b,c);a=vg(this,a);if(a[G]<h-f)a[F](function(a){a>=f&&a<=h&&(a=this.l.get(a),d[x](a))},this);else for(b=f;b<=h;++b)a.has(b)&&(c=this.l.get(b),d[x](c));return d};va(I,function(a,b){this.l[Ya](b);vg(this,a)[Ya](b)});I.tc=function(a){return null!=a?vg(this,a)[G]:this.l[G]};ta(I,function(){this.l[w]();this.ke[w]()});function xg(a,b,c){var d=0,f=a[C];for(c=c||yg;d<f;){var h=d+f>>1;0>c(a[h],b)?d=h+1:f=h}return d==f&&a[d]==b?d:~d}function yg(a,b){return a-b}function zg(a,b,c){c=xg(a,b,c);return 0>c?(a[A](-(c+1),0,b),!0):!1};function Ag(a,b,c,d){a=b?a[fb]():a;if(null==c&&null==d)return a;c=ba.min(Kb(c)?c:a[C],a[C]);if(0==c)return[];d=ba.min(d||0,a[C]);return a[n](d,d+c)};function Bg(){this.qa=0}Bg[t].add=function(a,b){this.qa+=b};va(Bg[t],function(a,b){this.qa-=b});ta(Bg[t],function(){this.qa=0});function Cg(a,b){a[w]();b[F](function(a){this.qa+=a.qa},a)};function Dg(a,b,c,d){this.u=a;this.U=b;this.me=c;this.kb=new Bg;if(d){a=511;a*=a*a;if(d[C]>=a)throw new P(6,a);d=Eg(this,d);this.oa=d=Fg(d)}else this[w]()}var Gg=[];I=Dg[t];na(I,H("u"));g(I,function(){return this.oa[D]()});I.add=function(a,b){this.oa=this.oa.rb(a,b)};I.set=function(a,b){this.oa=this.oa.rb(a,b,!0)};va(I,function(a,b){this.oa=this.oa[ib](a,b)});I.get=function(a){return this.oa.get(a)};I.Zc=function(a){if(null==a)return this.Ra().qa;if(a instanceof ye){if(De(a))return this.Ra().qa;if(Ee(a))return this.get(a.c)[C]}return this.bb([a])[C]};
  I.Ra=H("kb");I.sc=function(a,b,c,d){c=e(a);this.oa.fill({offset:b?this.kb.qa-a-d:d,count:a,je:0},c);return b?c[fb]():c};
  I.bb=function(a,b,c,d){var f=Hg(this.oa).b[0];if(!Kb(f)||0==c)return Gg;b=b||!1;c=null!=c?ba.min(c,this.kb.qa):this.kb.qa;d=d||0;var h=ba.min(ba.max(this.kb.qa-d,0),c);if(0==h)return Gg;if(!Kb(a)||1==a[C]&&a[0]instanceof ye&&De(a[0]))return this.sc(h,b,c,d);a=this.U.ff(a);var l=e(b?this.kb.qa:h),p={count:0,W:l[C],reverse:b,N:d};a[F](function(a){for(var b=this.U.sd(a),b=this.U.Pd(a)?f:b[0],b=Ig(this.oa,b),c=p[bb],d=0;null!=b&&p[bb]<p.W;)b.bb(a,p,l),p[bb]!=c?(d=0,c=p[bb]):d++,b=2==d?null:b[pb]()},this);
  l[A](p[bb],h-p[bb]);return b?Ag(l,b,c,d):l};ta(I,function(){this.oa=Jg(this);this.kb[w]()});I.Ha=function(a){return this.oa.Ha(a)};I.min=function(){return this.Bc(this.U.min[E](this.U))};I.max=function(){return this.Bc(this.U.max[E](this.U))};I.Bc=function(a){var b=Hg(this.oa),c=Kg(this.oa);if(0==b.b[C]&&0==c.b[C])return null;var d=b.b[0],b=b.A[0],f=c.b[c.b[C]-1],c=c.A[c.b[C]-1];return 1==a(d,f)?[d,this.me?[b]:b]:[f,this.me?[c]:c]};I.Da=H("me");I.lc=H("U");
  I.Td=function(a,b){return null!=a?-1==this.U[zb](a,b):!1};I.Ma=function(a,b){return null!=a?0==this.U[zb](a,b):!1};I.Fa=function(){for(var a=[],b=Hg(this.oa);b;)a[x](new Vc(b.ka,[b.b,b.A])),b=b.ua;return a};function Lg(a,b,c,d){a=new Dg(b,a,c);d=Mg(d,a);a.oa=d;return a}function Ng(a,b){this.ka=a;this.D=b;this.eb=0;this.ua=this.ub=this.C=null;this.b=[];this.A=[];this.g=[]}function Jg(a){return new Ng(Wc++,a)}function Og(a){return 0==a.eb}I=Ng[t];xa(I,H("ua"));
  function Pg(a){function b(a){return null!=a?a.ka[D]():"_"}var c=a.ka+"["+a.b[m]("|")+"]",d=a.g.map(function(a){return a.ka})[m]("|"),f=a.A[m]("/"),h=b(a.ub)+"{",h=Og(a)?h+f:h+d,h=h+"}"+b(a.C);a.ua&&(a=Pg(a.ua),c=c+"  "+a[0],h=h+"  "+a[1]);return[c,h]}g(I,function(){var a="",b=Pg(this),a=a+(b[0]+"\n"+b[1]+"\n");this.g[C]&&(a+=this.g[0][D]());return a});function Hg(a){return Og(a)?a:Hg(a.g[0])}function Kg(a){return Og(a)?a:Kg(a.g[a.g[C]-1])}function Qg(a,b){b&&(b.ub=a);a&&(a.ua=b)}
  function Eg(a,b){for(var c=b[C],d=0,f=Jg(a),h=f;0<c;){var l=768<=c?511:257<=c&&511>=c?c:257,p=b[n](d,d+l);f.b=p.map(function(a){return a.key});f.A=p.map(function(a){return a[v]});d+=l;c-=l;0<c&&(l=Jg(f.D),Qg(f,l),f=l)}return h}function Rg(a){var b=a[0],c=Jg(b.D);c.eb=b.eb+1;c.g=a;for(b=0;b<a[C];++b)a[b].C=c,0<b&&c.b[x](a[b].b[0]);return c}
  function Fg(a){var b=a,c=[];do c[x](b),b=b.ua;while(b);if(512>=c[C])b=Rg(c);else{var d=c[C],f=0,b=Jg(a.D);for(b.eb=a.eb+2;0<d;){a=768<=d?511:257<=d&&511>=d?d:257;var h=c[n](f,f+a),l=Rg(h);l.C=b;b.g[C]&&(b.b[x](h[0].b[0]),Qg(b.g[b.g[C]-1],l));b.g[x](l);f+=a;d-=a}}return b}I.get=function(a){var b=Sg(this,a);if(Og(this)){var c=Gg;this.D.Ma(this.b[b],a)&&(c=c[Qa](this.A[b]));return c}b=this.D.Ma(this.b[b],a)?b+1:b;return this.g[b].get(a)};
  I.Ha=function(a){var b=Sg(this,a);return this.D.Ma(this.b[b],a)?!0:Og(this)?!1:this.g[b].Ha(a)};va(I,function(a,b){Tg(this,a,-1,b);if(null==this.C){var c=this;1==this.g[C]&&(c=this.g[0],c.C=null);return c}return this});function Ug(a){return Og(a)?a.b[0]:Ug(a.g[0])}function Vg(a){a.b=[];for(var b=1;b<a.g[C];++b)a.b[x](Ug(a.g[b]))}
  function Tg(a,b,c,d){var f=Sg(a,b),h=Og(a);if(!h){var l=a.D.Ma(a.b[f],b)?f+1:f;if(Tg(a.g[l],b,l,d))Vg(a);else return!1}else if(!a.D.Ma(a.b[f],b))return!1;if(a.b[C]>f&&a.D.Ma(a.b[f],b)){if(Kb(d)&&!a.D.Da()&&h&&(l=a.A[f],d=xg(l,d,void 0),0>d?d=!1:(l[A](d,1),d=!0),d&&a.D.Ra()[ib](b,1),a.A[f][C]))return!1;a.b[A](f,1);h&&(h=a.D.Da()?1:a.A[f][C],a.A[A](f,1),a.D.Ra()[ib](b,h))}if(256>a.b[C]&&null!=a.C){a:{b=null;if(a.ua&&256<a.ua.b[C])b=a.ua,f=d=0,h=a.b[C]+1;else if(a.ub&&256<a.ub.b[C])b=a.ub,d=a.ub.b[C]-
  1,f=Og(a)?d:d+1,h=0;else{b=!1;break a}a.b[A](h,0,b.b[d]);b.b[A](d,1);d=Og(a)?a.A:a.g;l=null;Og(a)?l=b.A:(l=b.g,l[f].C=a);d[A](h,0,l[f]);l[A](f,1);Og(b)||(Vg(b),Vg(a));b=!0}b||Wg(a,c)}return!0}function Wg(a,b){var c,d,f;a.ua&&511>a.ua.b[C]?(c=a.ua,f=d=0):a.ub&&(c=a.ub,d=c.b[C],f=Og(c)?c.A[C]:c.g[C]);d=[d,0][Qa](a.b);e[t][A][wb](c.b,d);d=null;Og(a)?d=a.A:(d=a.g,d[F](function(a){a.C=c}));d=[f,0][Qa](d);e[t][A][wb](Og(c)?c.A:c.g,d);Qg(a.ub,a.ua);Og(c)||Vg(c);-1!=b&&(a.C.b[A](b,1),a.C.g[A](b,1))}
  I.rb=function(a,b,c){var d=Sg(this,a);if(Og(this)){if(this.D.Ma(this.b[d],a)){if(c)this.D.Ra()[ib](a,this.D.Da()?1:this.A[d][C]),this.A[d]=this.D.Da()?b:[b];else{if(this.D.Da())throw new P(201);if(!zg(this.A[d],b))throw new P(109);}this.D.Ra().add(a,1);return this}this.b[A](d,0,a);this.A[A](d,0,this.D.Da()?b:[b]);this.D.Ra().add(a,1);512==this.b[C]?(d=Jg(this.D),a=Jg(this.D),a.eb=1,a.b=[this.b[256]],a.g=[this,d],a.C=this.C,this.C=a,d.b=this.b[A](256),d.A=this.A[A](256),d.C=a,Qg(d,this.ua),Qg(this,
  d),d=a):d=this;return d}d=this.D.Ma(this.b[d],a)?d+1:d;a=this.g[d].rb(a,b,c);Og(a)||1!=a.b[C]||(this.b[A](d,0,a.b[0]),a.g[1].C=this,a.g[0].C=this,this.g[A](d,1,a.g[1]),this.g[A](d,0,a.g[0]));return 512==this.b[C]?Xg(this):this};function Xg(a){var b=Jg(a.D),c=Jg(a.D);b.C=a.C;b.eb=a.eb+1;b.b=[a.b[256]];b.g=[a,c];a.b[A](256,1);c.C=b;c.eb=a.eb;c.b=a.b[A](256);c.g=a.g[A](257);c.g[F](function(a){a.C=c});a.C=b;Qg(c,a.ua);Qg(a,c);return b}
  function Sg(a,b){for(var c=0,d=a.b[C];c<d;){var f=c+d>>1;a.D.Td(a.b[f],b)?c=f+1:d=f}return c}function Ig(a,b){if(!Og(a)){var c=Sg(a,b);a.D.Ma(a.b[c],b)&&c++;return Ig(a.g[c],b)}return a}
  I.bb=function(a,b,c){function d(a){return a[0]?a[1]?0:1:-1}var f=this.D.lc(),h=0,l=this.b[C]-1,p=this.b,y=d(f.nb(p[h],a)),O=d(f.nb(p[l],a));if(1!=y&&(-1!=y||-1!=O)){var Ra=function(a,b){var c=a+b>>1;return c==a?c+1:c},Sa=function(b,c,h){if(b>=c)return 0==h?c:-1;var l=d(f.nb(p[b],a));if(0==l)return b;if(1==l)return-1;l=Ra(b,c);if(l==c)return 0==h?c:-1;var y=d(f.nb(p[l],a));return 0==y?Sa(b,l,y):-1==y?Sa(l+1,c,h):Sa(b+1,l,y)},Tb=function(b,c){if(b>=c)return b;var h=d(f.nb(p[c],a));if(0==h)return c;
  if(-1==h)return b;h=Ra(b,c);if(h==c)return b;var l=d(f.nb(p[h],a));return 0==l?Tb(h,c):1==l?Tb(b,h-1):-1};0!=y&&(h=Sa(h+1,l,O));-1!=h&&(l=Tb(h,l),-1!=l&&l>=h&&Yg(this,b,c,h,l+1))}};function Yg(a,b,c,d,f){for(;d<f&&(b[fb]||!(b[bb]>=b.W));++d)if(a.D.Da())!b[fb]&&b.N?b.N--:c[b.count++]=a.A[d];else for(var h=0;h<a.A[d][C]&&b[bb]<c[C];++h)!b[fb]&&b.N?b.N--:c[b.count++]=a.A[d][h]}
  I.fill=function(a,b){if(Og(this))for(var c=0;c<this.A[C]&&0<a[bb];++c)if(0<a[vb]){if(a.offset=a[vb]-(this.D.Da()?1:this.A[c][C]),0>a[vb])for(var d=this.A[c][C]+a[vb];d<this.A[c][C]&&0<a[bb];++d)b[a.je++]=this.A[c][d],a.count--}else if(this.D.Da())b[a.je++]=this.A[c],a.count--;else for(d=0;d<this.A[c][C]&&0<a[bb];++d)b[a.je++]=this.A[c][d],a.count--;else for(c=0;c<this.g[C]&&0<a[bb];++c)this.g[c].fill(a,b)};
  function Mg(a,b){for(var c=b.Ra(),d=a.map(function(a){var d=new Ng(a.id(),b);d.b=a.o[0];d.A=a.o[1];d.b[F](function(a,f){c.add(a,b.Da()?1:d.A[f][C])});return d}),f=0;f<d[C]-1;++f)Qg(d[f],d[f+1]);return 1<d[C]?Fg(d[0]):d[0]};function Zg(a){if(1==a.f[C])return new $g(a.f[0].gb);a=a.f.map(function(a){return a.gb});return new ah(a)}function $g(a){this.Yc=0==a?bh:ch;this.Ud=0==a?function(a){return null!=a?a[fb]():null}:function(a){return a||null};this.$d=0==a?dh:eh}K($g,Wd);function ch(a,b){return a>b?1:a<b?-1:0}function bh(a,b){return ch(b,a)}function eh(a,b){return Fe(a,b)}function dh(a,b){return Fe(b,a)}I=$g[t];
  I.nb=function(a,b){var c=this.Ud(b),d=[null===c.c,null===c.w];if(!d[0]){var f=this.Yc(a,c.c);d[0]=c.$?1==f:-1!=f}d[1]||(f=this.Yc(a,c.w),d[1]=c.ia?-1==f:1!=f);return d};I.compare=function(a,b){return this.Yc(a,b)};I.min=function(a,b){return a<b?1:a==b?0:-1};I.max=function(a,b){return a>b?1:a==b?0:-1};I.Od=function(a,b){var c=this.nb(a,b);return c[0]&&c[1]};I.ff=function(a){return a[Ea](function(a){return null!==a})[Za](function(a,c){return this.$d(a,c)}[E](this))};I.Pd=function(a){return Nb(this.Ud(a).c)};
  I.sd=function(a){a=this.Ud(a);return[a.c,a.w]};g(I,function(){return this.Yc==bh?"SimpleComparator_DESC":"SimpleComparator_ASC"});function ah(a){this.Ga=a.map(function(a){return new $g(a)})}K(ah,Wd);function fh(a,b,c,d){for(var f=0,h=0;h<a.Ga[C]&&0==f;++h)f=d(a.Ga[h],b[h],c[h]);return f}I=ah[t];I.compare=function(a,b){return fh(this,a,b,function(a,b,f){return a[zb](b,f)})};I.min=function(a,b){return fh(this,a,b,function(a,b,f){return a.min(b,f)})};
  I.max=function(a,b){return fh(this,a,b,function(a,b,f){return a.max(b,f)})};I.nb=function(a,b){for(var c=[!0,!0],d=0;d<this.Ga[C]&&(c[0]||c[1]);++d){var f=this.Ga[d].nb(a[d],b[d]);c[0]=c[0]&&f[0];c[1]=c[1]&&f[1]}return c};I.Od=function(a,b){for(var c=!0,d=0;d<this.Ga[C]&&c;++d)c=this.Ga[d].Od(a[d],b[d]);return c};
  I.ff=function(a){var b=a[Ea](function(a){return a[Ua](Ob)});a=e(this.Ga[C]);for(var c=0;c<a[C];c++)a[c]=b.map(function(a){return a[c]});a[F](function(a,b){a[Za](function(a,c){return this.Ga[b].$d(a,c)}[E](this))},this);b=e(b[C]);for(c=0;c<b[C];c++)b[c]=a.map(function(a){return a[c]});return b[Za](function(a,b){for(var c=0,l=0;l<this.Ga[C]&&0==c;++l)c=this.Ga[l].$d(a[l],b[l]);return c}[E](this))};I.Pd=function(a){return this.Ga[0].Pd(a[0])};
  I.sd=function(a){var b=a.map(function(a,b){return this.Ga[b].sd(a)[0]},this);a=a.map(function(a,b){return this.Ga[b].sd(a)[1]},this);return[b,a]};function gh(a){this.ca=a;this.fb=N();this.Kc=new Bg;this.kb=new Bg}I=gh[t];na(I,function(){return this.ca[u]()});I.add=function(a,b){null===a?(this.fb.add(b),this.Kc.add(a,1)):this.ca.add(a,b)};I.set=function(a,b){null===a?(this.fb[w](),this.Kc[w](),this.add(a,b)):this.ca.set(a,b)};va(I,function(a,b){if(null===a)b?(this.fb[Ya](b),this.Kc[ib](a,1)):(this.fb[w](),this.Kc[w]());else this.ca[ib](a,b)});I.get=function(a){return null===a?Ld(this.fb):this.ca.get(a)};I.Zc=function(a){return this.ca.Zc(a)};
  I.Ra=function(){Cg(this.kb,[this.ca.Ra(),this.Kc]);return this.kb};I.bb=function(a,b,c,d){b=this.ca.bb(a,b,c,d);return null!=a?b:b[Qa](Ld(this.fb))};ta(I,function(){this.fb[w]();this.ca[w]()});I.Ha=function(a){return null===a?0!=this.fb[G]:this.ca.Ha(a)};I.min=function(){return this.ca.min()};I.max=function(){return this.ca.max()};I.Fa=function(){return[new Vc(-2,Ld(this.fb))][Qa](this.ca.Fa())};I.lc=function(){return this.ca.lc()};
  function hh(a,b){for(var c=-1,d=0;d<b[C];++d)if(-2==b[d].id()){c=d;break}if(-1==c)throw new P(102);var d=b[c].o,f=b[n](0);f[A](c,1);var c=a(f),h=new gh(c);d[F](function(a){h.fb.add(a)});return h}I.Da=function(){return this.ca.Da()};function ih(a){this.u=a;this.jb=N();this.U=new $g(1)}I=ih[t];na(I,H("u"));I.add=function(a){if("number"!=typeof a)throw new P(103);this.jb.add(a)};I.set=function(a,b){this.add(a,b)};va(I,function(a){this.jb[Ya](a)});I.get=function(a){return this.Ha(a)?[a]:[]};I.min=function(){return this.Bc(this.U.min[E](this.U))};I.max=function(){return this.Bc(this.U.max[E](this.U))};
  I.Bc=function(a){if(0==this.jb[G])return null;var b=Ld(this.jb)[Ia](function(b,d){return null===b||1==a(d,b)?d:b},null);return[b,[b]]};I.Zc=function(){return this.jb[G]};I.bb=function(a,b,c,d){var f=a||[Ce()];a=Ld(this.jb)[Ea](function(a){return f[ab](function(b){return this.U.Od(a,b)},this)},this);return Ag(a,b,c,d)};ta(I,function(){this.jb[w]()});I.Ha=function(a){return this.jb.has(a)};I.Fa=function(){return[new Vc(0,Ld(this.jb))]};I.lc=H("U");
  function jh(a,b){var c=new ih(a);b[0].o[F](function(a){c.add(a,a)});return c}I.Da=Ib(!0);I.Ra=function(){var a=new Bg;a.qa=this.jb[G];return a};function kh(a){this.i=a;this.vb=a.m(Ad);this.F=a.m(Cd);this.ha=a.m(Bd)}kh[t].Ba=function(a){var b=a.Ta(),c=function(){if(0==b[C])return Ec();var a=b[qb]();return(a.Bb()?lh(this,a):mh(this,a))[z](c)}[E](this);return c()};function mh(a,b){var c=new ue(a.i,N([b]));return a.vb.Hb(0,c).I(b[u](),b.$b[E](b)).get([])[z](function(a){this.ha.he(b[u](),a);nh(this,b,a)}[E](a))}function nh(a,b,c){var d=a.F.Lc.get(b[u]())||[];c[F](function(a){d[F](function(b){var c=a.Mb(b[u]());b.add(c,a.id())})})}
  function lh(a,b){var c=new ue(a.i,N([b])),d=a.vb.Hb(0,c),c=d.I(b[u](),b.$b).get([])[z](function(a){this.ha.he(b[u](),a)}[E](a)),f=b.Aa().map(function(a){return oh(this,a,d)},a)[Qa](ph(a,b,d));return Ic(f[Qa](c))}function oh(a,b,c){c=c.I(b.j(),Xc,1);var d=Zg(b);return c.get([])[z](function(a){if(1<a[C]){if(qh(b)){var c=Lg[E](void 0,d,b.j(),b.zc);a=hh(c,a[n](1))}else a=Lg(d,b.j(),b.zc,a[n](1));this.F.set(b.Mc,a)}}[E](a))}
  function ph(a,b,c){return c.I(b.u+".#",Xc,1).get([])[z](function(a){1<a[C]&&(a=jh(b.u+".#",a[n](1)),this.F.set(b[u](),a))}[E](a))};function rh(){this.X=M();this.Lc=M()}rh[t].Ba=function(a){a.Ta()[F](function(a){var c=[];this.Lc.set(a[u](),c);var d=a.u+".#";if(null===this.get(d)){var f=new ih(d);c[x](f);this.X.set(d,f)}a.Aa()[F](function(a){var b;b=Zg(a);b=new Dg(a.j(),b,a.zc);b=qh(a)?new gh(b):b;c[x](b);this.X.set(a.j(),b)},this)},this);return Ec()};rh[t].get=function(a){return this.X.get(a)||null};
  rh[t].set=function(a,b){var c=this.Lc.get(a)||null;null===c&&(c=[],this.Lc.set(a,c));for(var d=null,f=0;f<c[C];f++)if(c[f][u]()==b[u]()){d=f;break}null!==d&&0<c[C]?c[A](d,1,b):c[x](b);this.X.set(b[u](),b)};function sh(a){this.fc=[];Kb(a)&&this.add(a)}g(sh[t],function(){return this.fc.map(function(a){return a[D]()})[m](",")});sh[t].Ha=function(a){return this.fc[ab](function(b){return b[sb](a)})};sh[t].ta=H("fc");
  sh[t].add=function(a){if(0!=a[C])if(a=this.fc[Qa](a),1==a[C])this.fc=a;else{a[Za](Fe);for(var b=[],c=a[0],d=1;d<a[C];++d)if(Ae(c,a[d])){var f=a[d],h=Ce();if(null!==c.c&&null!==f.c){var l=Be(c.c,f.c,!0);1!=l?(h.c=c.c,h.$=0!=l?c.$:c.$&&f.$):(h.c=f.c,h.$=f.$)}null!==c.w&&null!==f.w&&(l=Be(c.w,f.w,!1),-1!=l?(h.w=c.w,h.ia=0!=l?c.ia:c.ia&&f.ia):(h.w=f.w,h.ia=f.ia));c=h}else b[x](c),c=a[d];b[x](c);this.fc=b}};
  function th(a,b){var c=[];a.ta().map(function(a){return b.ta().map(function(b){var c;if(Ae(a,b)){c=Ce();var l=Be(a.c,b.c,!0),l=0==l?a.$?a:b:-1!=l?a:b;c.c=l.c;c.$=l.$;null===a.w||null===b.w?b=null===a.w?b:a:(l=Be(a.w,b.w,!1),b=0==l?a.ia?a:b:-1==l?a:b);c.w=b.w;c.ia=b.ia}else c=null;return c})})[F](function(a){c=c[Qa](a)});return new sh(c[Ea](function(a){return null!==a}))};function uh(a,b){var c=[],d=null,f=null;mf(a,function(a){var l=b(a);null==a[Ab]()?f=l:hf(d,l);var p=a[Ab]();null!==p&&R(p)[C]==R(d)[C]&&(p=c[$a](d),-1!=p&&c[A](p,1));1<R(a)[C]&&c[x](l);d=null===a.g?c[c[C]-1]:l});return f}function vh(a){return wh(a,function(a){return null===a.g})}function xh(a){var b=a[Ab](),c=0;null!==b&&(c=R(b)[$a](a),b[hb](a));var d=R(a)[n]();d[F](function(d,h){a[hb](d);null===b||gf(b,d,c+h)});return{parent:b,children:d}}
  function yh(a,b){R(a)[n]()[F](function(c){a[hb](c);hf(b,c)});hf(a,b)}function zh(a){var b=ff(a,0);xh(a);yh(b,a);return b}function Ah(a,b,c){var d=ff(a,0),f=R(d)[n]();if(!f[ab](function(a){return b(a)}))return a;xh(a);f[F](function(f,l){if(b(f)){var p=c(a);jf(d,l);hf(p,f);gf(d,p,l)}});return d}function Bh(a,b,c,d){var f=a[Ab]();null!==f&&(a=R(f)[$a](a),jf(f,a),gf(f,c,a));R(b)[n]()[F](function(a){b[hb](a);hf(d,a)});return c}
  function wh(a,b,c){function d(a){b(a)&&f[x](a);null!=c&&c(a)||R(a)[F](d)}var f=[];d(a);return f}function Ch(a,b){var c=b||function(a){return a[D]()+"\n"},d="";mf(a,function(a){for(var b=0;b<ef(a);b++)d+="-";d+=c(a)});return d};function Dh(a){nf[r](this);this.Ob=a;this.Xa=!1}K(Dh,nf);I=Dh[t];I.Gb=function(){return uh(this,function(a){if(a instanceof Dh){var b=new Dh(a.Ob);b.Xa=a.Xa;a=a.Y();b.ka=a;return b}return a.Gb()}[E](this))};I.ab=function(a){var b=a||[];mf(this,function(a){a!=this&&a.ab(b)}[E](this));a=N(b);return Ld(a)};I.ud=function(a){this.Xa!=a&&(this.Xa=a,this.Ob="and"==this.Ob?"or":"and",R(this)[F](function(b){return b.ud(a)}))};
  I.eval=function(a){var b=R(this).map(function(b){return b.eval(a)});return Eh(this,b)};function Eh(a,b){return"and"==a.Ob?Me(b):Ne(b)}g(I,function(){return"combined_pred_"+this.Ob[D]()});function Fh(){this.l=M();this.size=0}I=Fh[t];I.has=function(a){return this.l.has(a)};I.set=function(a,b){var c=this.l.get(a)||null;null===c&&(c=N(),this.l.set(a,c));c.has(b)||(c.add(b),this.size++);return this};I.he=function(a,b){var c=this.l.get(a)||null;null===c&&(c=N(),this.l.set(a,c));b[F](function(a){c.has(a)||(c.add(a),this.size++)},this);return this};ra(I,function(a,b){var c=this.l.get(a,null);if(null===c)return!1;var d=c[Ya](b);d&&(--this.size,0==c[G]&&this.l[Ya](a));return d});
  I.get=function(a){a=this.l.get(a)||null;return null===a?null:Ld(a)};ta(I,function(){this.l[w]();this.size=0});I.keys=function(){return qd(this.l)};ua(I,function(){var a=[];this.l[F](function(b){a[x][wb](a,Ld(b))});return a});function Gh(a,b,c){nf[r](this);this.la=a;this.na=b;this.L=c;this.Vd=null;a=We.cd();this.$c=bf(a,this.la.S(),this.L);this.Tf=a.Le.get(this.la.S())||null}K(Gh,nf);I=Gh[t];I.Gb=function(){var a=new Gh(this.la,this.na,this.L),b=this.Y();a.ka=b;return a};I.ab=function(a){return null!=a?(a[x](this.la),a[x](this.na),a):[this.la,this.na]};
  I.reverse=function(){var a=this.L;switch(this.L){case "gt":a="lt";break;case "lt":a="gt";break;case "gte":a="lte";break;case "lte":a="gte"}return new Gh(this.na,this.la,a)};I.eval=function(a){var b=a[B][Ea](function(a){var b=Re(a,this.la);a=Re(a,this.na);return this.$c(b,a)},this);return new Ge(b,Q(a))};g(I,function(){return"join_pred("+this.la.j()+", "+this.na.j()+")"});function Hh(a,b,c){var d=null,f=null;-1!=Q(b)[$a](Se(a.la.I()))?(d=b,f=c):(d=c,f=b);return[d,f]}
  function Ih(a){var b={};a.ab()[F](function(a){b[a[u]()]=null});return b}function Jh(a,b,c){null===a.Vd&&(a.Vd=Ih(a.na.I()));var d=new Pe(new Vc(-1,a.Vd),!1);return Ue(b,c,d,[Se(a.na.I())])}
  function Kh(a,b,c,d){var f=[b,c];d||(f=Hh(a,b,c));b=f[0];c=f[1];var f=b,h=c,l=a.la,p=a.na;if(d||b[B][C]>c[B][C])f=c,h=b,l=a.na,p=a.la;var y=new Fh,O=[];f[B][F](function(a){var b=ha(Re(a,l));y.set(b,a)});var Ra=Q(f),Sa=Q(h);h[B][F](function(a){var b=Re(a,p),c=ha(b);null!==b&&y.has(c)?y.get(c)[F](function(b){b=Ue(a,Sa,b,Ra);O[x](b)}):d&&O[x](Jh(this,a,Sa))}[E](a));a=Q(b)[Qa](Q(c));return new Ge(O,a)}
  function Lh(a,b,c,d,f){function h(a,b){var c=new Pe(b,1<Ra[C]),c=Ue(a,Sa,c,Ra);O[x](c)}var l=d.Mf.I(),p=b,y=c;-1!=Q(b)[$a](Se(l))&&(p=c,y=b);var O=[],Ra=Q(y),Sa=Q(p);p[B][F](function(a){var b=this.Tf(Re(a,d.Zf)),b=d[mb].get(b);0!=b[C]&&(d[mb].Da()?h(a,f.get(b[0])):wg(f,b)[F](h[E](null,a)))},a);a=Q(p)[Qa](Q(y));return new Ge(O,a)};function Mh(a,b,c){return null===b?new pf(a,b,c):Kb(b.j)?new Gh(a,b,c):new pf(a,b,c)};var Nh={};J("lf.schema.DataStoreType",Nh);Nh.INDEXED_DB=0;Nh.MEMORY=1;Nh.LOCAL_STORAGE=2;Nh.FIREBASE=3;Nh.WEB_SQL=4;Nh.OBSERVABLE_STORE=5;function Oh(a,b,c,d){this.Mc=a;ja(this,b);this.zc=c;this.f=d}Oh[t].j=function(){return this.Mc+"."+this[q]};function qh(a){return a.f[ab](function(a){return a.da.yc()})}function V(a,b,c,d){this.u=a;this.fa=c;this.H=b;this.pd=d;this.Za=null}J("lf.schema.Table",V);na(V[t],H("u"));na(V[t],V[t][u]);V[t].Wa=H("Za");function Se(a){return a.Za||a.u}
  V[t].jc=function(a){var b=new this.constructor(this.u);b.Za=a;b.jg=this.jg;return b};V[t].as=V[t].jc;V[t].createRow=V[t].xb;V[t].deserializeRow=V[t].$b;V[t].Aa=H("fa");V[t].getIndices=V[t].Aa;V[t].ab=H("H");V[t].getColumns=V[t].ab;V[t].getConstraint=V[t].zb;V[t].Bb=H("pd");V[t].persistentIndex=V[t].Bb;function Ph(a,b){wa(this,a);this.Eb=b;this.Za=null}I=Ph[t];na(I,function(){return this.Eb+"("+this[jb][u]()+")"});I.j=function(){return this.Eb+"("+this[jb].j()+")"};I.I=function(){return this[jb].I()};g(I,function(){return this.j()});I.S=function(){return this[jb].S()};I.Wa=H("Za");I.Aa=function(){return[]};I.sa=Ib(null);I.yc=Ib(!1);I.jc=function(a){this.Za=a;return this};Ph[t].as=Ph[t].jc;function Qh(a){for(var b=[a];a instanceof Ph;)b[x](a[jb]),a=a[jb];return b}
  function Rh(a){this.Za=a||null;this.O=new V("#UnknownTable",[],[],!1)}I=Rh[t];na(I,Ib("*"));I.j=function(){return this[u]()};g(I,function(){return this.j()});I.I=H("O");I.S=Ib(4);I.Wa=H("Za");I.Aa=function(){return[]};I.sa=Ib(null);I.yc=Ib(!1);J("lf.fn.avg",function(a){return new Ph(a,"AVG")});function Sh(a){return new Ph(a||new Rh,"COUNT")}J("lf.fn.count",Sh);function Th(a){return new Ph(a,"DISTINCT")}J("lf.fn.distinct",Th);J("lf.fn.max",function(a){return new Ph(a,"MAX")});J("lf.fn.min",function(a){return new Ph(a,"MIN")});J("lf.fn.stddev",function(a){return new Ph(a,"STDDEV")});J("lf.fn.sum",function(a){return new Ph(a,"SUM")});J("lf.fn.geomean",function(a){return new Ph(a,"GEOMEAN")});function W(a,b){cf[r](this);this.Ff=b}K(W,cf);ma(W[t],function(a,b){switch(this.Ff){case 1:return Uh(this,a,b);case 0:return Vh(this,a,b);default:return Wh(this,a,b)}});g(W[t],Ib("dummy_node"));W[t].Nc=function(){return this[D]()};function Wh(a,b,c){return new L(function(a){a(this.aa(b,[],c))}[E](a))}function Uh(a,b,c){return ff(a,0)[Oa](b,c)[z](function(a){return this.aa(b,a,c)}[E](a))}
  function Vh(a,b,c){var d=R(a).map(function(a){return a[Oa](b,c)});return Ic(d)[z](function(a){var d=[];a[F](function(a){for(var b=0;b<a[C];++b)d[x](a[b])});return this.aa(b,d,c)}[E](a))};function Xh(a){W[r](this,0,1);this.se=a}K(Xh,W);g(Xh[t],function(){return"aggregation("+this.se.map(function(a){return a.j()})[D]()+")"});Xh[t].aa=function(a,b){b[F](function(a){Yh(new Zh(a,this.se))},this);return b};function Zh(a,b){this.Ea=a;this.H=b}
  function Yh(a){a.H[F](function(a){a=Qh(a)[fb]();for(var c=1;c<a[C];c++){var d=a[c],f=Qh(d)[n](-1)[0],h=d[jb]instanceof Ph?Je(this.Ea,d[jb]):this.Ea;if(null!==h.Va&&h.Va.has(d.j()))break;h=$h(d.Eb,h,f);f=this.Ea;null===f.Va&&(f.Va=M());f.Va.set(d.j(),h)}},a)}
  function $h(a,b,c){var d=null;switch(a){case "MIN":d=ai(b,c,function(a,b){return b<a?b:a});break;case "MAX":d=ai(b,c,function(a,b){return b>a?b:a});break;case "DISTINCT":d=bi(b,c);break;case "COUNT":d=ci(b,c);break;case "SUM":d=di(b,c);break;case "AVG":a=ci(b,c);0<a&&(d=di(b,c)/a);break;case "GEOMEAN":d=ei(b,c);break;default:d=fi(b,c)}return d}function ai(a,b,c){return a[B][Ia](function(a,f){var h=Re(f,b);return null===h?a:null===a?h:c(a,h)},null)}
  function ci(a,b){return b instanceof Rh?a[B][C]:a[B][Ia](function(a,d){return a+(Nb(Re(d,b))?0:1)},0)}function di(a,b){return ai(a,b,function(a,b){return b+a})}function fi(a,b){var c=[];a[B][F](function(a){a=Re(a,b);null===a||c[x](a)});return 0==c[C]?null:fd[wb](null,c)}function ei(a,b){var c=0,d=a[B][Ia](function(a,d){var l=Re(d,b);if(0==l||null===l)return a;c++;return a+ba.log(l)},0);return 0==c?null:ba.pow(ba.E,d/c)}
  function bi(a,b){var c=M();a[B][F](function(a){var f=Re(a,b);c.set(f,a)});return new Ge(rd(c),Q(a))};function gi(a,b){this.xa=a;this.pa=b}gi[t].cb=H("xa");gi[t].ba=H("pa");function hi(){cf[r](this)}K(hi,cf);function ii(a,b){cf[r](this);ia(this,a);ua(this,b)}K(ii,hi);function ji(a,b){ii[r](this,a,b)}K(ji,ii);function ki(a){cf[r](this);ia(this,a)}K(ki,hi);g(ki[t],function(){return"delete("+this[k][u]()+")"});function li(a,b){cf[r](this);ia(this,a);this.ne=b}K(li,hi);
  g(li[t],function(){var a=[];this.ne&&(a=this.ne.map(function(a){return a.K[u]()},this));return"update("+this[k][u]()+", ["+a[m](",")+"])"});function mi(a){cf[r](this);this.G=a}K(mi,hi);g(mi[t],function(){return"select("+this.G[D]()+")"});function ni(a){cf[r](this);ia(this,a)}K(ni,hi);g(ni[t],function(){var a="table_access("+this[k][u]();null===this[k].Wa()||(a+=" as "+this[k].Wa());return a+")"});function oi(){cf[r](this)}K(oi,hi);g(oi[t],Ib("cross_product"));
  function pi(a,b){cf[r](this);this.f=a;this.Jb=b}K(pi,hi);g(pi[t],function(){var a="project("+this.f[D]();if(null!==this.Jb)var b=this.Jb.map(function(a){return a.j()})[m](", "),a=a+(", groupBy("+b+")");return a+")"});function qi(a){cf[r](this);this.M=a}K(qi,hi);g(qi[t],function(){return"order_by("+yf(this.M)+")"});function ri(a){cf[r](this);this.f=a}K(ri,hi);g(ri[t],function(){return"aggregation("+this.f[D]()+")"});function si(a){cf[r](this);this.f=a}K(si,hi);
  g(si[t],function(){return"group_by("+this.f[D]()+")"});function ti(a){cf[r](this);this.W=a}K(ti,hi);g(ti[t],function(){return"limit("+this.W+")"});function ui(a){cf[r](this);this.N=a}K(ui,hi);g(ui[t],function(){return"skip("+this.N+")"});function vi(a,b){cf[r](this);this.G=a;this.Lb=b}K(vi,hi);g(vi[t],function(){return"join(type: "+(this.Lb?"outer":"inner")+", "+this.G[D]()+")"});function wi(){};function xi(){}K(xi,wi);xi[t].ib=function(a){this.V=a;this.Ua(this.V);return this.V};xi[t].Ua=function(a){if(a instanceof mi){var b=yi(this,a.G),b=zi(this,b);Bh(a,a,b[0],b[1]);a==this.V&&(this.V=b[0]);a=b[0]}R(a)[F](function(a){this.Ua(a)},this)};function yi(a,b){if(0==R(b)[C]||"and"!=b.Ob)return[b];var c=R(b)[n]().map(function(a){b[hb](a);return yi(this,a)},a);return jc(c)}function zi(a,b){var c=null,d=null;b.map(function(a,b){var l=new mi(a);0==b?c=l:hf(d,l);d=l},a);return[c,d]};function Ai(){}K(Ai,wi);Ai[t].ib=function(a){this.V=a;this.Ua(this.V);return this.V};Ai[t].Ua=function(a){if(a instanceof oi)for(;2<R(a)[C];){for(var b=new oi,c=0;2>c;c++){var d=jf(a,0);hf(b,d)}gf(a,b,0)}R(a)[F](function(a){this.Ua(a)},this)};function Bi(){W[r](this,0,0)}K(Bi,W);g(Bi[t],Ib("cross_product"));Bi[t].aa=function(a,b){for(var c=b[0],d=b[1],f=[],h=Q(c),l=Q(d),p=0;p<c[B][C];p++)for(var y=0;y<d[B][C];y++){var O=Ue(c[B][p],h,d[B][y],l);f[x](O)}c=Q(c)[Qa](Q(d));return[new Ge(f,c)]};function Ci(a,b){Bf[r](this,a,b);this.Pa=a.m(Ed);this.Ab=a.m(Fd)}K(Ci,Bf);Ca(Ci[t],Ib(2));Ci[t].Yd=function(a){0==this.S()?Di(this,a):this.Jc()};function Di(a,b){a.rd[F](function(a,d){a instanceof xf&&Ef(this.Ab,a,b[d])},a)}Ci[t].Jc=function(){var a=Gf(this.Ab,this.ba());0!=a[C]&&(a=new Df(this[Wa],a),Hf(this.Pa,a))};function Ei(a){sf[r](this,a)}K(Ei,sf);Ei[t].ba=function(){var a=N();a.add(this.c);var b=this.da[yb]();Fi(this.c[u](),b.g)[F](a.add[E](a));return a};la(Ei[t],function(){var a=new Ei(this.da);vf(a,this);a.c=this.c;return a});za(Ei[t],function(a){Ei.Db[E][r](this,a);wf(this,a);return this});function Gi(a){sf[r](this,a)}K(Gi,sf);Gi[t].ba=function(){var a=N();a.add(this.Ca);var b=this.da[yb]();Fi(this.Ca[u](),b.Te)[F](a.add[E](a));this.Wb&&Fi(this.Ca[u](),b.g)[F](a.add[E](a));return a};la(Gi[t],function(){var a=new Gi(this.da);vf(a,this);a.Ca=this.Ca;this[db]&&ua(a,this[db]instanceof Ve?this[db]:this[db][n]());a.Wb=this.Wb;a.Xb=this.Xb;return a});
  za(Gi[t],function(a){Gi.Db[E][r](this,a);this.Xb&&ua(this,this.Xb instanceof Ve?a[this.Xb.sa()]:this.Xb.map(function(b){return b instanceof Ve?a[b.sa()]:b}));return this});function Hi(a){sf[r](this,a)}K(Hi,sf);Hi[t].ba=function(){var a=N();a.add(this[k]);var b=this.set.map(function(a){return a.K.j()}),c=this.da[yb]();Ii(c,b)[F](a.add[E](a));Ji(c,b)[F](a.add[E](a));return a};la(Hi[t],function(){var a=new Hi(this.da);vf(a,this);ia(a,this[k]);a.set=this.set?this.set[n]():this.set;return a});za(Hi[t],function(a){Hi.Db[E][r](this,a);this.set[F](function(b){-1!=b.Tc&&pa(b,a[b.Tc])});wf(this,a);return this});function Ki(a,b){if(null==b)return"NULL";switch(a){case 1:return b?1:0;case 3:case 4:return b;case 0:return"'"+Zc(b)+"'";default:return"'"+b[D]()+"'"}}function Li(a,b){var c=a.Wb?"INSERT OR REPLACE":"INSERT",d=a.Ca.ab(),c=c+(" INTO "+a.Ca[u]()+"("),c=c+d.map(function(a){return a[u]()})[m](", "),c=c+") VALUES (";return a[db].map(function(a){var h=d.map(function(c){var d=a.o[c[u]()];return b?null!=d?"#":"NULL":Ki(c.S(),d)});return c+h[m](", ")+");"})[m]("\n")}
  function Mi(a){switch(a){case "between":return"BETWEEN";case "eq":return"=";case "gte":return">=";case "gt":return">";case "in":return"IN";case "lte":return"<=";case "lt":return"<";case "match":return"LIKE";case "neq":return"<>";default:return"UNKNOWN"}}function Ni(a,b,c,d){return a instanceof Ve?"?"+a.sa()[D]():d?null!=a?"#":"NULL":"match"==b?"'"+a[D]()+"'":"in"==b?"("+a.map(function(a){return Ki(c,a)})[m](", ")+")":"between"==b?Ki(c,a[0])+" AND "+Ki(c,a[1]):Ki(c,a)[D]()}
  function Oi(a,b){return R(a).map(function(a){return"("+Pi(a,b)+")"})[m]("and"==a.Ob?" AND ":" OR ")}function Qi(a){return[a.la.j(),Mi(a.L),a.na.j()][m](" ")}function Pi(a,b){if(a instanceof pf){var c=a.K.j(),d=Mi(a.L),f=Ni(a[v],a.L,a.K.S(),b);return"="==d&&"NULL"==f?[c,"IS NULL"][m](" "):"<>"==d&&"NULL"==f?[c,"IS NOT NULL"][m](" "):[c,d,f][m](" ")}if(a instanceof Dh)return Oi(a,b);if(a instanceof Gh)return Qi(a);throw new P(357,typeof a);}function Ri(a,b){var c=Pi(a,b);return c?" WHERE "+c:""}
  function Si(a,b){var c="UPDATE "+a[k][u]()+" SET ",c=c+a.set.map(function(a){var b=a.K.j()+" = ";return-1!=a.Tc?b+"?"+a.Tc[D]():b+Ki(a.K.S(),a[v])[D]()})[m](", ");a.B&&(c+=Ri(a.B,b));return c+";"}
  function Ti(a,b){var c="*";a.f[C]&&(c=a.f.map(function(a){return a.Wa()?a.j()+" AS "+a.Wa():a.j()})[m](", "));c="SELECT "+c+" FROM ";null!=a.sb&&0!=a.sb[G]?c+=Ui(a,b):(c+=a.c.map(Vi)[m](", "),a.B&&(c+=Ri(a.B,b)));if(a.M)var d=a.M.map(function(a){return a.K.j()+(0==a.gb?" DESC":" ASC")})[m](", "),c=c+(" ORDER BY "+d);a.ea&&(d=a.ea.map(function(a){return a.j()})[m](", "),c+=" GROUP BY "+d);a.W&&(c+=" LIMIT "+a.W[D]());a.N&&(c+=" SKIP "+a.N[D]());return c+";"}
  function Vi(a){return Se(a)!=a[u]()?a[u]()+" AS "+Se(a):a[u]()}function Ui(a,b){for(var c=wh(a.B,function(a){return a instanceof Gh}),d=c.map(Qi),f=Vi(a.c[0]),h=1;h<a.c[C];h++)var l=Vi(a.c[h]),f=a.sb.has(c[d[C]-h].Y())?f+(" LEFT OUTER JOIN "+l):f+(" INNER JOIN "+l),f=f+(" ON ("+d[d[C]-h]+")");c=ff(a.B,0);c instanceof Gh||(f+=" WHERE "+Pi(c,b));return f}
  function Wi(a,b){var c=b||!1,d=a.a[Na]();if(d instanceof Gi)return Li(d,c);if(d instanceof Ei){var f="DELETE FROM "+d.c[u]();d.B&&(f+=Ri(d.B,c));return f+";"}if(d instanceof Hi)return Si(d,c);if(d instanceof xf)return Ti(d,c);throw new P(358,typeof d);};function Xi(a,b){this.global=a;this.ig=a.m(Dd);this.Pa=a.m(Ed);this.a=b}J("lf.query.BaseBuilder",Xi);ma(Xi[t],function(){try{this.$a()}catch(a){return Fc(a)}return new L(function(a,c){var d=new Ci(this[Wa],[this.wc()]);Hf(this.Pa,d)[z](function(c){a(He(c[0]))},c)},this)});ma(Xi[t],Xi[t][Oa]);Xi[t].Hf=function(){var a=function(a){return a.Nc(this.a)+"\n"}[E](this);return Ch(Yi(this).cb(),a)};Xi[t].explain=Xi[t].Hf;za(Xi[t],function(a){this.a[E](a);return this});za(Xi[t],Xi[t][E]);
  Xi[t].pg=function(a){return Wi(this,a)};Xi[t].toSql=Xi[t].pg;Xi[t].$a=Gb();function Yi(a){if(null==a.Ue){var b;b=a.ig;var c=a.a,d=b.Wf.create(c);b=b.fg.create(d,c);a.Ue=b}return a.Ue}Xi[t].wc=function(){return{context:this.a[Na](),ae:Yi(this)}};function Zi(a){Xi[r](this,a,new Ei(a.m(Gd)))}K(Zi,Xi);J("lf.query.DeleteBuilder",Zi);Zi[t].c=function(a){if(null!=this.a.c)throw new P(515);this.a.c=a;return this};Zi[t].from=Zi[t].c;Zi[t].B=function(a){this.Ad();this.a.B=a;return this};Zi[t].where=Zi[t].B;Zi[t].Ad=function(){if(null!=this.a.B)throw new P(516);};Zi[t].$a=function(){Zi.Db.$a[r](this);if(null==this.a.c)throw new P(517);};function $i(a,b){Xi[r](this,a,new Gi(a.m(Gd)));this.a.Wb=b||!1}K($i,Xi);J("lf.query.InsertBuilder",$i);$i[t].$a=function(){$i.Db.$a[r](this);var a=this.a;if(null==a.Ca||null==a[db])throw new P(518);if(a.Wb&&null===a.Ca.zb().ed())throw new P(519);};$i[t].Ca=function(a){if(null!=this.a.Ca)throw new P(520);this.a.Ca=a;return this};$i[t].into=$i[t].Ca;ua($i[t],function(a){if(null!=this.a[db])throw new P(521);a instanceof Ve||a[ab](function(a){return a instanceof Ve})?this.a.Xb=a:ua(this.a,a);return this});
  ua($i[t],$i[t][db]);function aj(a){return bj("and",e[t][n][r](arguments))}J("lf.op.and",aj);J("lf.op.or",function(a){return bj("or",e[t][n][r](arguments))});function bj(a,b){var c=new Dh(a);b[F](function(a){hf(c,a)});return c}J("lf.op.not",function(a){a.ud(!0);return a});function X(a,b){Xi[r](this,a,new xf(a.m(Gd)));this.Be=this.vd=!1;this.a.f=b;cj(this);dj(this)}K(X,Xi);J("lf.query.SelectBuilder",X);X[t].$a=function(){X.Db.$a[r](this);var a=this.a;if(null==a.c)throw new P(522);if(Kb(a.Nb)&&!Kb(a.W)||Kb(a.Vb)&&!Kb(a.N))throw new P(523);null!=this.a.ea?ej(this):fj(this)};function cj(a){var b=a.a.f[Ea](function(a){return a instanceof Ph&&"DISTINCT"==a.Eb},a);if(0!=b[C]&&(1!=b[C]||1!=a.a.f[C]))throw new P(524);}
  function ej(a){var b=a.a.f[Ea](function(a){return!(a instanceof Ph)}).map(function(a){return a.j()}),c=!1;if(0==a.a.ea[C]||0==a.a.f[C])c=!0;else{var d=a.a.ea.map(function(a){return a.j()});(c=b[ab](function(a){return-1==d[$a](a)}))||(c=a.a.ea[ab](function(a){a=a.S();return 6==a||0==a}))}if(c)throw new P(525);}function fj(a){var b=a.a.f[ab](function(a){return a instanceof Ph},a);a=a.a.f[ab](function(a){return!(a instanceof Ph)},a)||0==a.a.f[C];if(b&&a)throw new P(526);}
  function dj(a){a.a.f[F](function(a){if(a instanceof Ph&&!gj(a.Eb,a.S()))throw new P(527,a.j());},a)}X[t].c=function(a){if(this.Be)throw new P(515);this.Be=!0;null==this.a.c&&(this.a.c=[]);this.a.c[x][wb](this.a.c,e[t][n][r](arguments));return this};X[t].from=X[t].c;X[t].B=function(a){if(this.vd)throw new P(516);this.vd=!0;hj(this,a);return this};X[t].where=X[t].B;function hj(a,b){if(null!=a.a.B){var c=aj(b,a.a.B);a.a.B=c}else a.a.B=b}
  X[t].Pf=function(a,b){if(null==this.a.c)throw new P(542);if(this.vd)throw new P(547);this.a.c[x](a);hj(this,b);return this};X[t].innerJoin=X[t].Pf;X[t].Uf=function(a,b){if(!(b instanceof Gh))throw new P(541);if(null==this.a.c)throw new P(542);if(this.vd)throw new P(547);this.a.c[x](a);null==this.a.sb&&(this.a.sb=N());var c=b;Se(a)!=Se(b.na.I())&&(c=b[fb]());this.a.sb.add(c.Y());hj(this,c);return this};X[t].leftOuterJoin=X[t].Uf;
  X[t].W=function(a){if(null!=(this.a.W||this.a.Nb))throw new P(528);if(a instanceof Ve)this.a.Nb=a;else{if(0>a)throw new P(531);this.a.W=a}return this};X[t].limit=X[t].W;X[t].N=function(a){if(null!=(this.a.N||this.a.Vb))throw new P(529);if(a instanceof Ve)this.a.Vb=a;else{if(0>a)throw new P(531);this.a.N=a}return this};X[t].skip=X[t].N;X[t].M=function(a,b){null==this.a.M&&(this.a.M=[]);this.a.M[x]({K:a,gb:null!=b?b:1});return this};X[t].orderBy=X[t].M;
  X[t].ea=function(a){if(null!=this.a.ea)throw new P(530);null==this.a.ea&&(this.a.ea=[]);this.a.ea[x][wb](this.a.ea,e[t][n][r](arguments));return this};X[t].groupBy=X[t].ea;function gj(a,b){switch(a){case "COUNT":case "DISTINCT":return!0;case "AVG":case "GEOMEAN":case "STDDEV":case "SUM":return 4==b||3==b;case "MAX":case "MIN":return 4==b||3==b||5==b||2==b}return!1}la(X[t],function(){var a=new X(this[Wa],this.a.f);a.a=this.a[Na]();a.a.Xc=null;return a});la(X[t],X[t][Na]);function ij(a,b){Xi[r](this,a,new Hi(a.m(Gd)));ia(this.a,b)}K(ij,Xi);J("lf.query.UpdateBuilder",ij);ij[t].set=function(a,b){var c={Tc:b instanceof Ve?b.sa():-1,K:a,value:b};null!=this.a.set?this.a.set[x](c):this.a.set=[c];return this};ij[t].set=ij[t].set;ij[t].B=function(a){this.Ad();this.a.B=a;return this};ij[t].where=ij[t].B;ij[t].Ad=function(){if(null!=this.a.B)throw new P(516);};
  ij[t].$a=function(){ij.Db.$a[r](this);if(null==this.a.set)throw new P(532);if(this.a.set[ab](function(a){return a[v]instanceof Ve}))throw new P(501);};function jj(a){this.a=a;this.xa=null}jj[t].dc=function(){null===this.xa&&(this.xa=this.bd());return this.xa};function kj(a){jj[r](this,a)}K(kj,jj);kj[t].bd=function(){return this.a.Wb?new ji(this.a.Ca,this.a[db]):new ii(this.a.Ca,this.a[db])};function lj(a){jj[r](this,a)}K(lj,jj);lj[t].bd=function(){var a=new li(this.a[k],this.a.set),b=null!=this.a.B?new mi(this.a.B.Gb()):null,c=new ni(this.a[k]);null===b?hf(a,c):(hf(b,c),hf(a,b));return a};function mj(a,b,c){this.xa=a;this.be=b;this.Sb=c}mj[t].dc=function(){this.Sb[F](function(a){this.xa=a.ib(this.xa,this.be)},this);return this.xa};function nj(a,b){jj[r](this,a);this.Sb=b}K(nj,jj);nj[t].bd=function(){var a=new ki(this.a.c),b=null!=this.a.B?new mi(this.a.B.Gb()):null,c=new ni(this.a.c);null===b?hf(a,c):(hf(b,c),hf(a,b));return(new mj(a,this.a,this.Sb)).dc()};function oj(){}K(oj,wi);oj[t].ib=function(a,b){this.V=a;this.Ua(this.V,b);return this.V};oj[t].Ua=function(a,b){if(a instanceof mi&&a.G instanceof Gh){var c=a.G.Y(),d=ff(a,0);d instanceof oi&&(c=Kb(b)&&null!=b.sb&&b.sb.has(c),c=new vi(a.G,c),Bh(a,d,c,c),a==this.V&&(this.V=c),a=c)}R(a)[F](function(a){this.Ua(a,b)},this)};function pj(){this.Sc=N()}K(pj,wi);pj[t].ib=function(a){this.Sc[w]();this.V=a;this.Ua(this.V);this.Sc[w]();return this.V};pj[t].Ua=function(a){if(qj(a)){var b=a.G instanceof pf?rj(this,a):sj(this,a);this.Sc.add(a);b==a&&(b=ff(a,0));null!==b&&(Nb(b[Ab]())&&(this.V=b),qj(b)&&!this.Sc.has(b)&&this.Ua(b))}else R(a)[F](function(a){this.Ua(a)},this)};
  function tj(a,b,c){var d=b;if(ff(b,0)instanceof mi)d=zh(b),tj(a,b,c);else if(uj(b)){var f=[],d=Ah(b,c,function(a){a=new mi(a.G);f[x](a);return a});f[F](function(a){tj(this,a,c)},a)}return d}function rj(a,b){var c=N([Se(b.G.K.I())]),d=function(a){return vj(this,a,c)}[E](a);return tj(a,b,d)}function sj(a,b){var c=N([Se(b.G.la.I()),Se(b.G.na.I())]),d=function(a){return vj(this,a,c)}[E](a);return tj(a,b,d)}
  function vj(a,b,c){var d=N();vh(b)[F](function(a){d.add(Se(a[k]))},a);b instanceof ni&&d.add(Se(b[k]));return Md(d,c)}function qj(a){return a instanceof mi&&!(a.G instanceof Dh)}function uj(a){a=ff(a,0);return a instanceof oi||a instanceof vi};function wj(a,b){jj[r](this,a);this.Sb=b;this.Ye=this.Pe=this.ef=this.Se=this.te=this.Ee=this.df=this.ye=this.gf=null}K(wj,jj);
  wj[t].bd=function(){xj(this);2<=this.a.c[C]&&(this.ye=new oi);this.df=null!=this.a.B?new mi(this.a.B.Gb()):null;this.a.M&&(this.Se=new qi(this.a.M));null!=this.a.N&&0<this.a.N&&(this.ef=new ui(this.a.N));null!=this.a.W&&(this.Pe=new ti(this.a.W));null!=this.a.ea&&(this.Ee=new si(this.a.ea));yj(this);this.Ye=new pi(this.a.f||[],this.a.ea||null);var a=zj(this);return(new mj(a,this.a,this.Sb)).dc()};
  function zj(a){for(var b=[a.Pe,a.ef,a.Ye,a.Se,a.te,a.Ee,a.df,a.ye],c=null,d=null,f=0;f<b[C];f++){var h=b[f];null!==h&&(null===d?d=h:hf(b[c],h),c=f)}a.gf[F](function(a){hf(b[c],a)});return d}function xj(a){a.gf=a.a.c.map(function(a){return new ni(a)},a)}function yj(a){var b=a.a.f[Ea](function(a){return a instanceof Ph});null!=a.a.M&&a.a.M[F](function(a){a.K instanceof Ph&&b[x](a.K)});0<b[C]&&(a.te=new ri(b))};function Aj(){this.ge=[new xi,new Ai,new pj,new oj];this.Gd=[new xi]}Aj[t].create=function(a){var b=null;if(a instanceof Gi)b=new kj(a);else if(a instanceof Ei)b=new nj(a,this.Gd);else if(a instanceof xf)b=new wj(a,this.ge);else if(a instanceof Hi)b=new lj(a);else throw new P(513);b=b.dc();return new gi(b,a.ba())};function Bj(a){W[r](this,0,1);this.O=a}K(Bj,W);g(Bj[t],function(){return"delete("+this.O[u]()+")"});Bj[t].aa=function(a,b){var c=b[0][B].map(function(a){return a.ra});a[ib](this.O,c);return[Le()]};function Cj(a,b){W[r](this,0,-1);ia(this,b);this.F=a.m(Cd)}K(Cj,W);g(Cj[t],function(){return"get_row_count("+this[k][u]()+")"});Cj[t].aa=function(){var a=this.F.get(this[k].u+".#"),b=new Ge([],[this[k][u]()]),c=Sh(),a=a.Ra().qa;null===b.Va&&(b.Va=M());b.Va.set(c.j(),a);return[b]};function Dj(a,b){W[r](this,0,-1);this.ha=a.m(Bd);this.F=a.m(Cd);ia(this,b)}K(Dj,W);g(Dj[t],function(){var a="table_access("+this[k][u]();null===this[k].Wa()||(a+=" as "+this[k].Wa());return a+")"});Dj[t].aa=function(){var a=this.F.get(this[k].u+".#").bb();return[Oe(wg(this.ha,a),[Se(this[k])])]};function Ej(a){this.i=a}K(Ej,wi);Ej[t].ib=function(a,b){this.V=a;if(!this.Bd(b))return a;var c=wh(a,function(a){return a instanceof Dj})[0],d=new Cj(this.i,c[k]);Bh(c,c,d,d);return this.V};Ej[t].Bd=function(a){return 1==a.f[C]&&1==a.c[C]&&null==a.B&&null==a.W&&null==a.N&&null==a.ea?(a=a.f[0],a instanceof Ph&&"COUNT"==a.Eb&&a[jb]instanceof Rh):!1};function Fj(a){W[r](this,0,1);this.De=a}K(Fj,W);g(Fj[t],function(){return"groupBy("+this.De.map(function(a){return a.j()})[D]()+")"});Fj[t].aa=function(a,b){return Gj(this,b[0])};function Gj(a,b){var c=new Fh,d=function(a){return this.De.map(function(b){return Re(a,b)},this)[m](",")}[E](a);b[B][F](function(a){c.set(d(a),a)},a);return c[kb]().map(function(a){return new Ge(c.get(a),Q(b))},a)};function Hj(a,b,c){W[r](this,0,0);this.F=a.m(Cd);this.ha=a.m(Bd);this.G=b;this.Lb=c;this.yd="eq"==this.G.L?0:2;this.Fe=null}K(Hj,W);var Ij=["hash","index_nested_loop","nested_loop"];g(Hj[t],function(){return"join(type: "+(this.Lb?"outer":"inner")+", impl: "+Ij[this.yd]+", "+this.G[D]()+")"});
  Hj[t].aa=function(a,b){switch(this.yd){case 0:return[Kh(this.G,b[0],b[1],this.Lb)];case 1:return[Lh(this.G,b[0],b[1],this.Fe,this.ha)];default:var c=this.G,d=b[0],f=b[1],h=this.Lb,l=[d,f];h||(l=Hh(c,d,f));for(var d=l[0],f=l[1],l=[],p=Q(d),y=Q(f),O=0;O<d[B][C];O++){var Ra=!1,Sa=Re(d[B][O],c.la);if(null!==Sa)for(var Tb=0;Tb<f[B][C];Tb++)if(c.$c(Sa,Re(f[B][Tb],c.na))){var Ra=!0,Lj=Ue(d[B][O],p,f[B][Tb],y);l[x](Lj)}h&&!Ra&&l[x](Jh(c,d[B][O],p))}c=Q(d)[Qa](Q(f));return[new Ge(l,c)]}};
  function Jj(a,b){a.yd=1;var c=a.F.get(b.sa().j());a.Fe={Mf:b,Zf:b==a.G.la?a.G.na:a.G.la,index:c}};function Kj(a){W[r](this,0,-1);this.$e=a}K(Kj,W);g(Kj[t],function(){return"no_op_step("+Q(this.$e[0])[m](",")+")"});Kj[t].aa=H("$e");function Mj(){}K(Mj,wi);Mj[t].ib=function(a,b){this.V=a;if(!this.Bd(b))return a;wh(a,function(a){return a instanceof Hj})[F](this.hg,this);return this.V};Mj[t].Bd=function(a){return 1<a.c[C]};Mj[t].hg=function(a){if("eq"==a.G.L&&!a.Lb){var b=function(b){if(!(b instanceof Dj))return null;b=Se(b[k])==Se(a.G.na.I())?a.G.na:a.G.la;return Nb(b.sa())?null:b},c=b(ff(a,0)),b=b(ff(a,1));if(null!==c||null!==b){b=null===b?c:b;Jj(a,b);var d=new Ge([],[Se(b.I())]);kf(a,new Kj([d]),b==c?0:1)}}};function Nj(a){a=a.map(function(a){return a.ta()});a=kd[wb](null,a);var b=[];jd(a,function(a){b[x](a)});return b}function Oj(a){this.Kb=a}Oj[t].dd=function(){return 1==this.Kb.f[C]?[Ce()]:[this.Kb.f.map(function(){return Ce()})]};function Pj(a,b){this.Kb=a;this.wa=b;this.Ed=this.Ne=null}
  function Qj(a,b){var c=M();a.wa[kb]()[F](function(a){var f=this.wa.get(a).map(function(a){return tf(b,a)},this),h=new sh([Ce()]);f[F](function(a){var b=null;"between"==a.L?b=new ye(a[v][0],a[v][1],!1,!1):"eq"==a.L?(b=a[v],b=new ye(b,b,!1,!1)):b="gte"==a.L?new ye(a[v],null,!1,!1):"gt"==a.L?new ye(a[v],null,!0,!1):"lte"==a.L?new ye(null,a[v],!1,!1):new ye(null,a[v],!1,!0);a=a.Xa?ze(b):[b];a=new sh(a);h=th(h,a)});c.set(a,h)},a);return c}
  Pj[t].dd=function(a){if(this.Ne==a)return this.Ed;for(var b=Qj(this,a),c=this.Kb.f[C]-1;0<=c;c--){var d=this.Kb.f[c];if(null!==(b.get(d.da[u]())||null))break;b.set(d.da[u](),new sh([Ce()]))}this.Ed=1==this.Kb.f[C]?rd(b)[0].ta():Nj(Rj(this,b));this.Ne=a;return this.Ed};function Rj(a,b){var c=M(),d=0;a.Kb.f[F](function(a){c.set(a.da[u](),d);d++});return qd(b)[Za](function(a,b){return c.get(a)-c.get(b)}).map(function(a){return b.get(a)})};function Sj(a,b){this.hf=b;this.F=a.m(Cd)}function Tj(a,b,c){c=c[Ea](a.Qf,a);if(0==c[C])return null;a=Uj(a,c);if(0==a[C])return null;if(1==a[C])return a[0];var d=Number.MAX_VALUE;return a[Ia](function(a,c){var l=Vj(c,b);return l<d?(d=l,c):a},null)}function Uj(a,b){return a.hf.Aa().map(function(a){a=new Wj(this.F,a);Xj(a,b);return a},a)[Ea](function(a){if(null===a.wa)a=!1;else{for(var b=!1,f=!0,h=0;h<a.qb.f[C];h++){var l=a.wa.has(a.qb.f[h].da[u]());if(b&&l){f=!1;break}l||(b=!0)}a=f}return a})}
  Sj[t].Qf=function(a){var b;if(b=a instanceof pf)qf(a),b=null!==a[v]&&("between"==a.L||"eq"==a.L||"gt"==a.L||"gte"==a.L||"lt"==a.L||"lte"==a.L);return b?a.K.I()==this.hf:!1};function Wj(a,b){this.F=a;this.qb=b;this.Nf=N(this.qb.f.map(function(a){return a.da[u]()}));this.Sd=this.wa=null}function Yj(a){null===a.Sd&&(a.Sd=new Pj(a.qb,a.wa));return a.Sd}function Xj(a,b){b[F](function(a){var b=a.ab()[0][u]();this.Nf.has(b)&&(null===this.wa&&(this.wa=new Fh),this.wa.set(b,a.Y()))},a)}
  function Vj(a,b){var c=Yj(a).dd(b),d=a.F.get(a.qb.j());return c[Ia](function(a,b){return a+d.Zc(b)},0)};function Zj(a,b,c,d){W[r](this,0,-1);this.F=a.m(Cd);this.index=b;this.Me=c;this.ee=d;this.Rc=this.Qc=!1}K(Zj,W);g(Zj[t],function(){return"index_range_scan("+this[mb].j()+", ?, "+(this.ee?"reverse":"natural")+(this.Qc?", limit:?":"")+(this.Rc?", skip:?":"")+")"});Zj[t].Nc=function(a){var b=this[D](),c=this.Me.dd(a),b=b[eb]("?",c[D]());this.Qc&&(b=b[eb]("?",a.W[D]()));this.Rc&&(b=b[eb]("?",a.N[D]()));return b};
  Zj[t].aa=function(a,b,c){a=this.Me.dd(c);b=this.F.get(this[mb].j());c=(1==a[C]&&a[0]instanceof ye&&Ee(a[0])?Ag(b.get(a[0].c),!1,this.Qc?c.W:void 0,this.Rc?c.N:void 0):b.bb(a,this.ee,this.Qc?c.W:void 0,this.Rc?c.N:void 0)).map(function(a){return new Vc(a,{})},this);return[Oe(c,[this[mb].Mc])]};function ak(a){W[r](this,0,1);this.qd=a}K(ak,W);g(ak[t],Ib("select(?)"));ak[t].Nc=function(a){a=tf(a,this.qd);return this[D]()[eb]("?",a[D]())};ak[t].aa=function(a,b,c){return[tf(c,this.qd).eval(b[0])]};function bk(a,b){W[r](this,0,1);this.ha=a.m(Bd);this.O=b}K(bk,W);g(bk[t],function(){return"table_access_by_row_id("+this.O[u]()+")"});bk[t].aa=function(a,b){return[Oe(wg(this.ha,Ie(b[0])),[Se(this.O)])]};function ck(a){this.i=a}K(ck,wi);ck[t].ib=function(a,b){this.V=a;wh(a,function(a){return a instanceof Dj})[F](function(a){var d=dk(a);if(0!=d[C]){var f=Tj(new Sj(this.i,a[k]),b,d.map(function(a){return tf(b,a.qd)}));if(null!==f){var h=M();d[F](function(a){h.set(a.qd,a)},this);this.V=ek(this,f,h,a)}}},this);return this.V};function dk(a){var b=[];for(a=a[Ab]();a;)a instanceof ak&&b[x](a),a=a[Ab]();return b}
  function ek(a,b,c,d){(null===b.wa?[]:b.wa[db]()).map(function(a){return c.get(a)})[F](xh);b=new Zj(a.i,b.qb,Yj(b),!1);a=new bk(a.i,d[k]);hf(a,b);Bh(d,d,a,b);return b.cb()};function fk(a,b){W[r](this,0,-1);this.F=a.m(Cd);this.O=b}K(fk,W);g(fk[t],function(){return"insert("+this.O[u]()+")"});fk[t].aa=function(a,b,c){gk(this.O,c[db],this.F);a.rb(this.O,c[db]);return[Oe(c[db],[this.O[u]()])]};function gk(a,b,c){a=a.zb().ed();if(null===a?0:a.f[0][ob]){var d=a.f[0].da[u]();c=c.get(a.j()).max();var f=null===c?0:c[0];b[F](function(a){if(0==a.o[d]||null==a.o[d])f++,a.o[d]=f})}}function hk(a,b){W[r](this,0,-1);this.F=a.m(Cd);this.O=b}K(hk,W);
  g(hk[t],function(){return"insert_replace("+this.O[u]()+")"});hk[t].aa=function(a,b,c){gk(this.O,c[db],this.F);a.Nd(this.O,c[db]);return[Oe(c[db],[this.O[u]()])]};function ik(){W[r](this,0,1)}K(ik,W);g(ik[t],Ib("limit(?)"));ik[t].Nc=function(a){return this[D]()[eb]("?",a.W[D]())};ik[t].aa=function(a,b,c){b[0][B][A](c.W);return b};function jk(a){W[r](this,0,1);this.M=a}K(jk,W);I=jk[t];g(I,function(){return"order_by("+yf(this.M)+")"});I.aa=function(a,b){if(1==b[C]){var c;c=b[0];for(var d=null,f=0;f<this.M[C];f++){var h=Th(this.M[f].K);if(null!==c.Va&&c.Va.has(h.j())){d=h;break}}c=d;(null===c?b[0]:Je(b[0],c))[B][Za](this.Ef[E](this))}else b[Za](this.kg[E](this));return b};
  I.U=function(a,b){var c=null,d=null,f=null,h=-1;do h++,f=this.M[h].K,c=this.M[h].gb,d=a(f),f=b(f);while(d==f&&h+1<this.M[C]);d=d<f?-1:d>f?1:0;return 1==c?d:-d};I.kg=function(a,b){return this.U(function(b){return b instanceof Ph?Je(a,b):Re(a[B][a[B][C]-1],b)},function(a){return a instanceof Ph?Je(b,a):Re(b[B][b[B][C]-1],a)})};I.Ef=function(a,b){return this.U(function(b){return Re(a,b)},function(a){return Re(b,a)})};function kk(a,b){this.Ea=a;this.H=b}function lk(a){return a.H[ab](function(a){return a instanceof Ph},a)?mk(a):nk(a)}function mk(a){if(1==a.H[C]&&"DISTINCT"==a.H[0].Eb)return a=Je(a.Ea,a.H[0])[B].map(function(a){var b=new Pe(new Vc(-1,{}),1<this.Ea.J[G]);Te(b,this.H[0],Re(a,this.H[0][jb]));return b},a),new Ge(a,[]);var b=new Pe(new Vc(-1,{}),1<a.Ea.J[G]);a.H[F](function(a){var d=a instanceof Ph?Je(this.Ea,a):Re(this.Ea[B][0],a);Te(b,a,d)},a);return new Ge([b],Q(a.Ea))}
  function nk(a){var b=e(a.Ea[B][C]),c=1<a.Ea.J[G];a.Ea[B][F](function(a,f){b[f]=new Pe(new Vc(a.ra.id(),{}),c);this.H[F](function(c){Te(b[f],c,Re(a,c))},this)},a);return new Ge(b,Q(a.Ea))}function ok(a,b){var c=a.map(function(a){return lk(new kk(a,b))[B][0]});return new Ge(c,Q(a[0]))};function pk(a,b){W[r](this,0,1);this.f=a;this.Jb=b}K(pk,W);g(pk[t],function(){var a="project("+this.f[D]();if(null!==this.Jb)var b=this.Jb.map(function(a){return a.j()})[m](", "),a=a+(", groupBy("+b+")");return a+")"});pk[t].aa=function(a,b){var c;0==b[C]?c=[Le()]:1==b[C]?(c=b[0],c=[0==this.f[C]?c:lk(new kk(c,this.f))]):c=[ok(b,this.f)];return c};function qk(a){return a.f[ab](function(a){return a instanceof Ph})||null!==a.Jb};function rk(){W[r](this,0,1)}K(rk,W);g(rk[t],Ib("skip(?)"));rk[t].Nc=function(a){return this[D]()[eb]("?",a.N[D]())};rk[t].aa=function(a,b,c){return[new Ge(b[0][B][n](c.N),Q(b[0]))]};function sk(){}K(sk,wi);sk[t].ib=function(a){var b=wh(a,function(a){return a instanceof ik||a instanceof rk});if(0==b[C])return a;var c=tk(a);if(null===c)return a;b[F](function(a){a instanceof ik?c.Qc=!0:c.Rc=!0;xh(a)},this);return c.cb()};function tk(a){a=wh(a,function(a){return a instanceof Zj},function(a){return a instanceof pk&&qk(a)||a instanceof jk||1!=R(a)[C]||a instanceof ak});return 0<a[C]?a[0]:null};function uk(a){this.i=a}K(uk,wi);uk[t].ib=function(a){var b=vk(a);if(null===b)return a;a:{var c=b;a=wk(ff(b,0));if(null!==a){var d;d=b.M;for(var f=null,h=a[k].Aa(),l=0;l<h[C]&&null===f;l++)f=xk(h[l],d);d=f;if(null===d){a=c;break a}c=new Zj(this.i,d.qb,new Oj(d.qb),d.Je);d=new bk(this.i,a[k]);hf(d,c);xh(b);c=Bh(a,a,d,c)}a=c}if(a==b)a:if(a=b,c=yk(ff(b,0)),null!==c){d=xk(c[mb],b.M);if(null===d)break a;c.ee=d.Je;a=xh(b).parent}return a.cb()};
  function yk(a){a=wh(a,function(a){return a instanceof Zj},function(a){return 1!=R(a)[C]});return 0<a[C]?a[0]:null}function wk(a){a=wh(a,function(a){return a instanceof Dj},function(a){return 1!=R(a)[C]});return 0<a[C]?a[0]:null}function vk(a){a=wh(a,function(a){return a instanceof jk});return 0<a[C]?a[0]:null}function xk(a,b){if(a.f[C]!=b[C]||!b[Ua](function(b,c){return b.K[u]()==a.f[c].da[u]()}))return null;var c=zk(b,a);return c[0]||c[1]?{qb:a,Je:c[1]}:null}
  function zk(a,b){var c=a[Ia](function(a,b){return a<<1|(0==b.gb?0:1)},0),d=b.f[Ia](function(a,b){return a<<1|(0==b.gb?0:1)},0),d=c^d,c=0==d,d=d==ba.pow(2,ba.max(a[C],b.f[C]))-1;return[c,d]};function Ak(a,b,c){this.xa=a;this.be=b;this.Sb=c}Ak[t].dc=function(){this.Sb[F](function(a){this.xa=a.ib(this.xa,this.be)},this);return this.xa};function Bk(a,b){W[r](this,0,1);this.O=a;this.sg=b}K(Bk,W);g(Bk[t],function(){return"update("+this.O[u]()+")"});Bk[t].aa=function(a,b){var c=b[0][B].map(function(a){var b=this.O.$b(a.ra.Fa());this.sg[F](function(a){b.o[a.K[u]()]=a[v]},this);return b},this);a[Va](this.O,c);return[Le()]};function Ck(a){this.i=a;this.ge=[new Mj,new ck(this.i),new uk(this.i),new sk,new Ej(this.i)];this.Gd=[new ck(this.i)]}Ck[t].create=function(a,b){var c=a.cb();if(c instanceof ji||c instanceof ii)return Dk(this,a,b);if(c instanceof pi||c instanceof ti||c instanceof ui)return Dk(this,a,b,this.ge);if(c instanceof ki||c instanceof li)return Dk(this,a,b,this.Gd);throw new P(8);};function Dk(a,b,c,d){a=uh(b.cb(),a.Yf[E](a));null!=d&&(a=(new Ak(a,c,d)).dc());return new zf(a,b.ba())}
  Ck[t].Yf=function(a){if(a instanceof pi)return new pk(a.f,a.Jb);if(a instanceof si)return new Fj(a.f);if(a instanceof ri)return new Xh(a.f);if(a instanceof qi)return new jk(a.M);if(a instanceof ui)return new rk;if(a instanceof ti)return new ik;if(a instanceof mi)return new ak(a.G.Y());if(a instanceof oi)return new Bi;if(a instanceof vi)return new Hj(this.i,a.G,a.Lb);if(a instanceof ni)return new Dj(this.i,a[k]);if(a instanceof ki)return new Bj(a[k]);if(a instanceof li)return new Bk(a[k],a.ne);if(a instanceof
  ji)return new hk(this.i,a[k]);if(a instanceof ii)return new fk(this.i,a[k]);throw new P(514);};function Ek(a){this.Wf=new Aj;this.fg=new Ck(a)};function Fk(){this.Qe=M()}function Gk(a,b){var c=a.Qe.get(b[u]())||null;null===c&&(c=new Hk,a.Qe.set(b[u](),c));return c}function Ik(a,b,c,d){c[F](function(a){a=Gk(this,a);0==d?(a.Ya=null,a.pc=b):3==d?(null===a.Ub&&(a.Ub=N()),a.Ub.add(b),null===a.Oa&&(a.Oa=N()),a.Oa[Ya](b)):1==d?(null===a.Oa&&(a.Oa=N()),a.Oa.add(b)):2==d&&(a.Ya=b)},a)}
  function Jk(a,b,c,d){var f=!0;c[F](function(a){if(f){a=Gk(this,a);var c=null===a.Oa||0==a.Oa[G];f=0==d?(null===a.Ub||0==a.Ub[G])&&c&&null===a.pc&&null!==a.Ya&&a.Ya==b:3==d?null===a.pc&&null===a.Ya&&null!==a.Oa&&a.Oa.has(b):1==d?null===a.Ya:c&&(null===a.Ya||a.Ya==b)}},a);return f}function Kk(a,b,c,d){var f=Jk(a,b,c,d);f&&Ik(a,b,c,d);return f}Fk[t].releaseLock=function(a,b){b[F](function(b){Gk(this,b).releaseLock(a)},this)};function Lk(a,b){b[F](function(a){Gk(this,a).Ya=null},a)}
  function Hk(){this.Ub=this.Oa=this.Ya=this.pc=null}Hk[t].releaseLock=function(a){this.pc==a&&(this.pc=null);this.Ya==a&&(this.Ya=null);null===this.Oa||this.Oa[Ya](a);null===this.Ub||this.Ub[Ya](a)};function Mk(){this.Qb=new Nk;this.Ac=new Fk}function Hf(a,b){(2>b[Cb]()||2>b[Cb]())&&Lk(a.Ac,b.ba());a.Qb.rb(b);Ok(a);return b.uc().ga}function Ok(a){for(var b=a.Qb.ta(),c=0;c<b[C];c++){var d=b[c],f=!1;if(f=0==d.S()?Pk(a,d,1,3):Pk(a,d,2,0))a.Qb[ib](d),f=a,d[Oa]()[z](f.dg[E](f,d),f.cg[E](f,d))}}function Pk(a,b,c,d){var f=!1;Kk(a.Ac,b.Y(),b.ba(),c)&&(f=Kk(a.Ac,b.Y(),b.ba(),d));return f}Mk[t].dg=function(a,b){this.Ac.releaseLock(a.Y(),a.ba());a.uc()[Eb](b);Ok(this)};
  Mk[t].cg=function(a,b){this.Ac.releaseLock(a.Y(),a.ba());a.uc()[Ja](b);Ok(this)};function Nk(){this.Qb=[]}Nk[t].rb=function(a){zg(this.Qb,a,function(a,c){var d=a[Cb]()-c[Cb]();return 0==d?a.Y()-c.Y():d})};Nk[t].ta=function(){return this.Qb[n]()};va(Nk[t],function(a){var b=this.Qb;a=cc(b,a);var c;(c=0<=a)&&bc[A][r](b,a,1);return c});function Qk(a,b){this.Hd=We.cd();this.ce=a;this.md=b;this.H=Rk(this)}function Rk(a){if(0<a.ce.f[C])return a.ce.f;var b=[];a.ce.c[F](function(a){a.ab()[F](function(a){b[x](a)})});return b}Qk[t].U=function(a,b){return this.H[Ua](function(c){return bf(this.Hd,c.S(),"eq")(Re(a,c),Re(b,c))},this)};
  function Sk(a,b,c){var d=null===b?[]:b[B],f=bd(d,c[B],a.U[E](a),function(a){return d[a]});b=[];for(var h=0,l=0;l<d[C];l++){var p=d[l];f[h]==p?h++:(p=a.md[A](h,1),p=Tk(l,p,0,a.md),b[x](p))}f=bd(d,c[B],a.U[E](a),function(a,b){return c[B][b]});for(l=h=0;l<c[B][C];l++)p=c[B][l],f[h]==p?h++:(a.md[A](l,0,p.ra.o),p=Tk(l,[],1,a.md),b[x](p));return b}function Tk(a,b,c,d){return{tg:c,index:a,object:d,vg:b,type:"splice"}};function Uk(){this.bc=M()}Uk[t].xd=function(a,b){var c=Sb(a.a)[D](),d=this.bc.get(c)||null;null===d&&(d=new Vk(a),this.bc.set(c,d));d.xd(b)};Uk[t].de=function(a,b){var c=Sb(a.a)[D](),d=this.bc.get(c)||null;d.de(b);0<d.Ec[G]||this.bc[Ya](c)};function Gf(a,b){var c=N();b[F](function(a){c.add(a[u]())});var d=[];a.bc[F](function(a){a=a.wc();a[nb].c[ab](function(a){return c.has(a[u]())})&&d[x](a)});return d}function Ef(a,b,c){b=Sb(null!=b.Xc?b.Xc:b)[D]();a=a.bc.get(b)||null;null!==a&&Wk(a,c)}
  function Vk(a){this.vf=a;this.Ec=N();this.ag=[];this.Oe=null;this.Cf=new Qk(a.a,this.ag)}Vk[t].xd=function(a){this.Ec.has(a)||this.Ec.add(a)};Vk[t].de=function(a){return this.Ec[Ya](a)};Vk[t].wc=function(){var a=this.vf;return{context:a.a,ae:Yi(a)}};function Wk(a,b){var c=Sk(a.Cf,a.Oe,b);a.Oe=b;0<c[C]&&a.Ec[F](function(a){a(c)})};function Xk(a,b){var c=a.m(Gd),d=b||{},f=new ug;a.hb(Bd,f);var f=null,h=!1;switch(d.storeType||0){case 1:f=new hg(c);break;case 5:f=new jg(c);break;case 4:f=new qg(a,c,d.webSqlDbSize);break;case 3:f=new Tf(c,d.firebase);h=!0;break;default:f=new dg(a,c)}a.hb(Ad,f);var l=new rh;a.hb(Cd,l);return f.Ba(d.onUpgrade)[z](function(){var b=new Ek(a);a.hb(Dd,b);b=new Mk;a.hb(Ed,b);b=new Uk;a.hb(Fd,b);return l.Ba(c)})[z](function(){if(h){var b=new If(a);b.vb.subscribe(b.Wd[E](b))}return(new kh(a)).Ba(c)})};function Yk(a,b){this.i=a;this.vb=a.m(Ad);this.Pa=a.m(Ed);this.Ab=a.m(Fd);this.pa=N(b);this.Na=new ue(this.i,this.pa);this.Rb=Jc();this.qc=Jc();this.pe=Jc()}I=Yk[t];ma(I,function(){this.pe[Eb]();return this.qc.ga});I.S=Ib(1);I.ba=H("pa");I.uc=H("Rb");I.Y=function(){return Sb(this)};Ca(I,Ib(2));function Zk(a){Hf(a.Pa,a);return a.pe.ga}
  function $k(a,b){var c=b.wc();return c.ae.cb()[Oa](a.Na,c[nb])[z](function(a){return He(a[0])},function(a){this.Na.Cb();var b=new Pc(a[q]);this.qc[Ja](b);throw a;}[E](a))}I.ja=function(){this.vb.Hb(this.S(),this.Na).ja()[z](function(){this.Jc();this.qc[Eb]()}[E](this),function(a){this.Na.Cb();this.qc[Ja](a)}[E](this));return this.Rb.ga};I.Cb=function(){this.Na.Cb();this.qc[Eb]();return this.Rb.ga};I.Jc=function(){var a=Gf(this.Ab,this.pa);0!=a[C]&&(a=new Df(this.i,a),Hf(this.Pa,a))};function al(a){this.i=a;this.Pa=a.m(Ed);this.Oc=null;this.Qa=0;0==bl[G]&&(bl.set(0,N([1,4])),bl.set(1,N([2])),bl.set(2,N([3,5,6])),bl.set(3,N([2,7])),bl.set(4,N([7])),bl.set(5,N([7])),bl.set(6,N([7])))}J("lf.proc.Transaction",al);var bl=M();function cl(a,b){var c=bl.get(a.Qa)||null;if(null===c||!c.has(b))throw new P(107,a.Qa,b);a.Qa=b}
  ma(al[t],function(a){cl(this,4);var b=[];try{a[F](function(a){a.$a();b[x](a.wc())},this)}catch(c){return cl(this,7),Fc(c)}a=new Ci(this.i,b);return Hf(this.Pa,a)[z](function(a){cl(this,7);return a.map(function(a){return He(a)})}[E](this),function(a){cl(this,7);throw a;}[E](this))});ma(al[t],al[t][Oa]);al[t].tf=function(a){cl(this,1);this.Oc=new Yk(this.i,a);return Zk(this.Oc)[z](function(){cl(this,2)}[E](this))};al[t].begin=al[t].tf;
  al[t].sf=function(a){cl(this,3);return $k(this.Oc,a)[z](function(a){cl(this,2);return a}[E](this),function(a){cl(this,7);throw a;}[E](this))};al[t].attach=al[t].sf;al[t].ja=function(){cl(this,5);return this.Oc.ja()[z](function(){cl(this,7)}[E](this))};al[t].commit=al[t].ja;al[t].Cb=function(){cl(this,6);return this.Oc.Cb()[z](function(){cl(this,7)}[E](this))};al[t].rollback=al[t].Cb;function Y(a){this.i=a;this.s=a.m(Gd);this.Md=!1}J("lf.proc.Database",Y);Y[t].Ba=function(a){this.i.hb(Gd,this.s);return Xk(this.i,a)[z](function(){this.Md=!0;return this}[E](this))};Y[t].init=Y[t].Ba;Y[t].pb=H("s");Y[t].getSchema=Y[t].pb;function dl(a){if(!a.Md)throw new P(2);}Y[t].select=function(a){dl(this);return new X(this.i,1!=arguments[C]||null!=arguments[0]?e[t][n][r](arguments):[])};Y[t].select=Y[t].select;Y[t].rb=function(){dl(this);return new $i(this.i)};Y[t].insert=Y[t].rb;
  Y[t].Nd=function(){dl(this);return new $i(this.i,!0)};Y[t].insertOrReplace=Y[t].Nd;qa(Y[t],function(a){dl(this);return new ij(this.i,a)});qa(Y[t],Y[t][Va]);ra(Y[t],function(){dl(this);return new Zi(this.i)});Y[t]["delete"]=Y[t][Ya];Y[t].observe=function(a,b){this.i.m(Fd).xd(a,b)};Y[t].observe=Y[t].observe;Y[t].unobserve=function(a,b){this.i.m(Fd).de(a,b)};Y[t].unobserve=Y[t].unobserve;Y[t].Af=function(){dl(this);return new al(this.i)};Y[t].createTransaction=Y[t].Af;
  oa(Y[t],function(){try{this.i.m(Ad)[Pa]()}catch(a){}this.i[w]();this.Md=!1});oa(Y[t],Y[t][Pa]);function Z(a,b,c,d,f,h){this.O=a;this.u=b;this.Ke=c;this.Ie=d;this.mf=f;this.Za=h||null}J("lf.schema.BaseColumn",Z);I=Z[t];na(I,H("u"));I.j=function(){return Se(this.O)+"."+this.u};g(I,function(){return this.j()});I.I=H("O");I.S=H("mf");Z[t].getType=Z[t].S;Z[t].Wa=H("Za");Z[t].Aa=function(){null==this.fa&&(this.fa=[],this.I().Aa()[F](function(a){-1!=a.f.map(function(a){return a.da[u]()})[$a](this.u)&&this.fa[x](a)},this));return this.fa};
  Z[t].sa=function(){if(!Kb(this.ca)){var a=this.Aa()[Ea](function(a){return 1!=a.f[C]?!1:a.f[0].da[u]()==this[u]()},this);this.ca=0<a[C]?a[0]:null}return this.ca};Z[t].yc=H("Ie");Z[t].isNullable=Z[t].yc;Z[t].zc=H("Ke");Z[t].Ma=function(a){return Mh(this,a,"eq")};Z[t].eq=Z[t].Ma;Z[t].Re=function(a){return Mh(this,a,"neq")};Z[t].neq=Z[t].Re;Z[t].Td=function(a){return Mh(this,a,"lt")};Z[t].lt=Z[t].Td;Z[t].Xf=function(a){return Mh(this,a,"lte")};Z[t].lte=Z[t].Xf;Z[t].Jf=function(a){return Mh(this,a,"gt")};
  Z[t].gt=Z[t].Jf;Z[t].Kf=function(a){return Mh(this,a,"gte")};Z[t].gte=Z[t].Kf;Z[t].match=function(a){return Mh(this,a,"match")};Z[t].match=Z[t].match;Z[t].uf=function(a,b){return Mh(this,[a,b],"between")};Z[t].between=Z[t].uf;Z[t].Lf=function(a){return Mh(this,a,"in")};Z[t]["in"]=Z[t].Lf;Z[t].Sf=function(){return this.Ma(null)};Z[t].isNull=Z[t].Sf;Z[t].Rf=function(){return this.Re(null)};Z[t].isNotNull=Z[t].Rf;Z[t].jc=function(a){return new Z(this.O,this.u,this.Ke,this.Ie,this.mf,a)};Z[t].as=Z[t].jc;function el(){this.td=M()}var fl;ta(el[t],function(){this.td[w]()});ta(el[t],el[t][w]);el[t].hb=function(a,b){this.td.set(a[D](),b);return b};el[t].registerService=el[t].hb;el[t].m=function(a){var b=this.td.get(a[D]())||null;if(null===b)throw new P(7,a[D]());return b};el[t].getService=el[t].m;el[t].Rd=function(a){return this.td.has(a[D]())};el[t].isRegistered=el[t].Rd;function gl(a){this.s=a;this.Ze=new Fh;this.Te=new Fh;this.we=M();this.g=new Fh;this.ve=new Fh;hl(this)}function hl(a){a.s.Ta()[F](function(a){var c=a[u]();a.zb().Kd()[F](function(d){this.Ze.set(d.tb,d);this.Te.set(c,this.s[k](d.tb));this.g.set(d.tb,a);this.we.set(a[u]()+"."+d.Fb,d.tb);this.ve.set(d.tb+"."+d.Gc,a[u]())},this)},a)}function oe(a,b){return a.Ze.get(b)}function Fi(a,b){var c=b.get(a);return null===c?[]:c}
  function Ii(a,b){var c=N();b[F](function(a){(a=this.we.get(a))&&c.add(a)},a);return Ld(c).map(function(a){return this.s[k](a)},a)}function Ji(a,b){var c=N();b[F](function(a){(a=this.ve.get(a))&&a[F](function(a){c.add(a)})},a);return Ld(c).map(function(a){return this.s[k](a)},a)};function il(a,b,c){this.gg=a;this.$f=b;this.If=c}J("lf.schema.Constraint",il);il[t].ed=H("gg");il[t].getPrimaryKey=il[t].ed;il[t].Kd=H("If");il[t].getForeignKeys=il[t].Kd;function jl(a,b){var c=a.ref[Ha](".");if(2!=c[C])throw new P(540,b);this.Fb=a.local;this.tb=c[0];this.Gc=c[1];ja(this,b);this.action=a.action;this.timing=a[Ka]};function kl(a){ll(a);this.Hd=We.cd();this.u=a;this.H=M();this.le=N();this.Pc=N();this.Dc=N();this.va=null;this.fa=M();this.pd=!1;this.yb=[]}J("lf.schema.TableBuilder",kl);function ml(a){ja(this,a[q]);this.gb=a.order;this.autoIncrement=a[ob]}var nl=N([0,6]);function ll(a){if(!/^[A-Za-z_][A-Za-z0-9_]*$/.test(a))throw new P(502,a);}function ol(a,b){if(b==a.u)throw new P(546,b);if(a.H.has(b)||a.fa.has(b)||a.Pc.has(b))throw new P(503,a.u+"."+b);}
  function pl(a,b){var c=!1;b[F](function(a){var b=this.H.get(a[q]);c=c||a[ob];if(a[ob]&&3!=b)throw new P(504);},a);if(c&&1<b[C])throw new P(505);}function ql(a){if(null!==a.va){var b=a.fa.get(a.va).map(function(a){return a[q]}),c=0;if(a.yb[ab](function(a,f){c=f;return-1!=b[$a](a.Fb)},a))throw new P(543,a.yb[c][q]);}}
  function rl(a){if(null!==a.va){var b=function(a){return a[q]},c=ga[xb](a.fa.get(a.va).map(b));a.fa[F](function(a,f){if(f!=this.va){var h=a.map(b);if(ga[xb](h)==c)throw new P(544,this.u+"."+f);}},a)}}function sl(a){null===a.va||a.fa.get(a.va)[F](function(a){if(this.Dc.has(a[q]))throw new P(545,this.u+"."+a[q]);},a)}kl[t].nf=function(a,b){ll(a);ol(this,a);this.H.set(a,b);nl.has(b)&&this.re([a]);return this};kl[t].addColumn=kl[t].nf;
  kl[t].pf=function(a,b){var c=this.u;this.va="pk"+(c[0].toUpperCase()+c.substring(1));ll(this.va);ol(this,this.va);c=tl(this,a,!0,void 0,b);pl(this,c);1==c[C]&&this.le.add(c[0][q]);this.Pc.add(this.va);this.fa.set(this.va,c);return this};kl[t].addPrimaryKey=kl[t].pf;
  kl[t].of=function(a,b){ll(a);ol(this,a);var c=new jl(b,this.u+"."+a);Kb(c.action)||(c.action=0);Kb(c[Ka])||(c.timing=0);if(1==c.action&&1==c[Ka])throw new P(506);if(!this.H.has(c.Fb))throw new P(540,a);this.yb[x](c);this.qe(a,[c.Fb],!1);return this};kl[t].addForeignKey=kl[t].of;kl[t].qf=function(a,b){ll(a);ol(this,a);var c=tl(this,b,!0);ul(this,a,c);1==c[C]&&this.le.add(c[0][q]);this.fa.set(a,c);this.Pc.add(a);return this};kl[t].addUnique=kl[t].qf;
  kl[t].re=function(a){a=tl(this,a,!1);vl(this,a);a[F](function(a){this.Dc.add(a[q])},this);return this};kl[t].addNullable=kl[t].re;function vl(a,b){qd(a.fa)[F](function(a){var d=N();this.fa.get(a)[F](function(a){d.add(a[q])});var f=b[Ea](function(a){return d.has(a[q])});if(1<d[G]&&0<f[C])throw new P(507,a,f[m](","));},a)}kl[t].qe=function(a,b,c,d){ll(a);ol(this,a);b=tl(this,b,!0,d);ul(this,a,b);c&&this.Pc.add(a);this.fa.set(a,b);return this};kl[t].addIndex=kl[t].qe;
  function ul(a,b,c){if(1<c[C]&&(a=c[Ea](function(a){return this.Dc.has(a[q])},a),0<a[C]))throw new P(507,b,a[m](","));}kl[t].Bb=Hb("pd");kl[t].persistentIndex=kl[t].Bb;kl[t].pb=function(){ql(this);rl(this);sl(this);return new (wl(this))};kl[t].getSchema=kl[t].pb;function xl(a){return a.yb}
  function tl(a,b,c,d,f){var h=b,h="string"==typeof b[0]?b.map(function(a){return new ml({name:a,order:null!=d?d:1,autoIncrement:f||!1})}):b.map(function(a){return new ml(a)});h[F](function(a){if(!this.H.has(a[q]))throw new P(508,this.u,a[q]);if(c){var b=this.H.get(a[q]);if(0==b||6==b)throw new P(509,this.u,a[q]);}},a);return h}
  function wl(a){function b(){function b(c){return a.fa.get(c).map(function(a){return{da:this[a[q]],gb:a.gb,autoIncrement:a[ob]}},this)}var d=qd(a.H).map(function(b){this[b]=new Z(this,b,a.le.has(b),a.Dc.has(b),a.H.get(b));return this[b]},this),f=qd(a.fa).map(function(d){return new Oh(a.u,d,a.Pc.has(d),b[r](this,d))},this);V[r](this,a.u,d,f,a.pd);var h=null===a.va?null:new Oh(a.u,a.va,!0,b[r](this,a.va)),l=d[Ea](function(b){return!a.Dc.has(b[u]())});this.xf=new il(h,l,a.yb);this.cf=yl(a,d,f)}K(b,V);
  b[t].xb=function(a){return new this.cf(Wc++,a)};b[t].createRow=b[t].xb;b[t].$b=function(a){var b={};this.ab()[F](function(f){var h=f[u]();f=f.S();var l=a[v][h];if(0==f)if(f=l,null!=f&&""!=f){0!=f[C]%2&&(f="0"+f);for(var l=new ArrayBuffer(f[C]/2),p=new Uint8Array(l),y=0,O=0;y<f[C];y+=2)p[O++]=da(f.substr(y,2),16);f=l}else f=null;else f=2==f?null!=l?new Date(l):null:l;b[h]=f},this);return new this.cf(a.id,b)};b[t].deserializeRow=b[t].$b;b[t].zb=H("xf");b[t].getConstraint=b[t].zb;return b}
  function yl(a,b,c){function d(a,d){this.H=b;this.fa=c;Vc[r](this,a,d)}K(d,Vc);d[t].ze=function(){var a={};this.H[F](function(b){a[b[u]()]=b.yc()?null:ge[b.S()]});return a};d[t].jf=function(){var a={};this.H[F](function(b){var c=b[u]();b=b.S();var d=this.o[c];a[c]=0==b?null!=d?Zc(d):null:2==b?null!=d?d[Db]():null:6==b?null!=d?d:null:d},this);return a};var f=function(a){var b=this.H.get(a[u]()),c=this.Hd.Le.get(b)||null;return function(b){return c(b[a[u]()])}}[E](a),h=function(a){var b=a.map(function(a){return f(a.da)});
  return function(a){return b.map(function(b){return b(a)})}}[E](a),l={};c[F](function(a){var b=a.j();a=1==a.f[C]?f(a.f[0].da):h(a.f);l[b]=a});d[t].Mb=function(a){return-1!=a[$a]("#")?this.id():l[rb](a)?l[a](this.o):null};return d};function zl(a,b){this.s=new Al(a,b);this.lb=M();this.rc=!1}J("lf.schema.Builder",zl);function Bl(a,b){b.yb[F](function(a){var d=a.tb;if(!this.lb.has(d))throw new P(536,a[q]);var d=this.lb.get(d).pb(),f=a.Gc;if(!d[rb](f))throw new P(537,a[q]);if(b.pb()[a.Fb].S()!=d[f].S())throw new P(538,a[q]);if(!d[f].zc())throw new P(539,a[q]);},a)}zl[t].wf=function(a){a.yb[F](function(a){xl(this.lb.get(a.tb))[F](function(c){if(c.Fb==a.Gc)throw new P(534,a[q]);},this)},this)};
  function Cl(a){a.rc||(a.lb[F](function(a){Bl(this,a);a=a.pb();this.s.J.set(a[u](),a)},a),rd(a.lb)[F](a.wf,a),Dl(a),a.lb[w](),a.rc=!0)}function El(a,b,c){b.oe||(b.oe=!0,b.Xd=!0,b.Ae[F](function(a){a=c.get(a);if(!a.oe)El(this,a,c);else if(a.Xd&&b!=a)throw new P(533);},a));b.Xd=!1}function Dl(a){var b=M();a.s.J[F](function(a,d){b.set(d,new Fl(d))},a);a.lb[F](function(a,d){a.yb[F](function(a){b.get(a.tb).Ae.add(d)})});rd(b)[F](function(a){El(this,a,b)},a)}
  function Fl(a){this.Xd=this.oe=!1;this.Ae=N();this.Mc=a}zl[t].pb=function(){this.rc||Cl(this);return this.s};zl[t].getSchema=zl[t].pb;zl[t].Ce=function(){var a=new zd("ns_"+this.s[q]()),b;fl||(fl=new el);b=fl;var c=null;b.Rd(a)?c=b.m(a):(c=new el,b.hb(a,c));return c};zl[t].getGlobal=zl[t].Ce;zl[t].connect=function(a){var b=this.Ce();b.Rd(Gd)||b.hb(Gd,this.pb());return(new Y(b)).Ba(a)};zl[t].connect=zl[t].connect;
  zl[t].zf=function(a){if(this.lb.has(a))throw new P(503,a);if(this.rc)throw new P(535);this.lb.set(a,new kl(a));return this.lb.get(a)};zl[t].createTable=zl[t].zf;zl[t].ie=function(a){if(this.rc)throw new P(535);this.s.ie(a);return this};zl[t].setPragma=zl[t].ie;function Al(a,b){this.u=a;this.Ka=b;this.J=M();this.Xe={Df:!1}}J("lf.schema.DatabaseSchema",Al);ja(Al[t],H("u"));ja(Al[t],Al[t][q]);Al[t].version=H("Ka");Al[t].version=Al[t][tb];Al[t].Ta=function(){return rd(this.J)};Al[t].tables=Al[t].Ta;
  ia(Al[t],function(a){if(!this.J.has(a))throw new P(101,a);return this.J.get(a)});ia(Al[t],Al[t][k]);Al[t].info=function(){this.Ge||(this.Ge=new gl(this));return this.Ge};Al[t].We=H("Xe");Al[t].pragma=Al[t].We;Al[t].ie=Hb("Xe");J("lf.schema.create",function(a,b){return new zl(a,b)});}.bind(window))()
  //# sourceMappingURL=lovefield.min.js.map
  