function $a(){this.Init()}m("AdfRestDataService",$a);r.v($a);$a.ga=function(){this.iK="success";m("AdfRestDataService.SUCCESS_CALLBACK_KEY",$a.iK);this.hJ="error";m("AdfRestDataService.ERROR_CALLBACK_KEY",$a.hJ);this.Zi="priority";m("AdfRestDataService.PRIORITIZE",$a.Zi);this.Pm="clientId";m("AdfRestDataService.CLIENT_ID_KEY",$a.Pm);this.pt="request";m("AdfRestDataService.REQUEST_DATA",$a.pt)};m("AdfRestDataService.InitClass",$a.ga);
$a.prototype.Init=function(){$a.h.Init.call(this);this.EB=new Ef;this.Nkb=new Ff(this.EB)};r.a("AdfRestDataService.prototype.Init",{Init:$a.prototype.Init});$a.Jta=function(a,b){u.J(a);a=a.trim();a=$a.slb(a);a=$a.Gha(a);a=$a.a$a(a,b);a=$a.Wmb(a);$a.wta(a)&&(a=q.b.fP()+a);return a};m("AdfRestDataService.normalizeUrl",$a.Jta);$a.prototype.td=function(){return this.EB.Vsa()||this.Nkb.Tsa()};r.a("AdfRestDataService.prototype.isBusy",{td:$a.prototype.td});$a.wta=function(a){return-1==a.indexOf("://")};
m("AdfRestDataService.isRelativeUrl",$a.wta);$a.prototype.KZ=function(a,b){b=$a.Fhb(b);a=$a.Jta(a,b[$a.pt].mUa);this.EB.push(a,b)};r.a("AdfRestDataService.prototype.queueRequest",{KZ:$a.prototype.KZ});$a.prototype.h3=function(a,b,d){for(var e=a.options,f=0;f<e.length;f++){var g=e[f],h=g[b];if(h){u.Ja(h);try{var l=d.slice();l.push(g);h.apply(this,l)}catch(n){v.l.severe("Exception ocurred while invoking '"+b+"' callback for the URL '"+a.zu+"'.",n)}}}};
r.a("AdfRestDataService.prototype.__xhrCallback",{h3:$a.prototype.h3});$a.a$a=function(a,b){if(!b)return a;var d=a.indexOf("?");if(-1==d)return a+"?"+b;for(var e=a.substring(d+1).split("\x26"),f=b.split("\x26"),g="",h=0,l=e.length;h<l;h++){for(var n=e[h].split("\x3d")[0],t=0;t<f.length;t++)if(0==f[t].indexOf(n)){e[h]=f[t];f.splice(t,1);break}g+=e[h]+"\x26"}h=0;for(l=f.length;h<l;h++)g+=f[h]+"\x26";return $a.Gha(a.substring(0,d+1)+g)};
$a.Fhb=function(a){a||(a={});var b=a[$a.pt];b||(b={method:"GET"});a[$a.pt]=b;a[$a.Zi]=1==a[$a.Zi];return a};$a.Gha=function(a){var b;do b=a,a=a.replace(/[\/\?&]+$/,"");while(b!=a);return a};$a.slb=function(a){-1!=a.indexOf("#")&&(a=a.substring(0,a.indexOf("#")));return a};$a.Wmb=function(a){var b=a.indexOf("?");if(-1==b)return a;for(var d=a.substring(b+1).split("\x26").sort(),e="",f=0,g=d.length;f<g;f++)e+=d[f]+"\x26";e=e.replace(/&$/,"");return a.substring(0,b+1)+e};