function gb(){this.Init()}m("AdfMarshalingService",gb);r.v(gb);gb.prototype.Init=function(){gb.h.Init.call(this);this.P7={}};r.a("AdfMarshalingService.prototype.Init",{Init:gb.prototype.Init});gb.prototype.cua=function(a){var b=a.P7,d=this.P7,e;for(e in b)d[e]={name:b[e],encoder:a}};r.a("AdfMarshalingService.prototype.registerEncoder",{cua:gb.prototype.cua});
gb.prototype.Ry=function(a,b,d){var e=Ef(this,b.constructor);null==e&&(e=Ef(this,Object));if(null==d)d=new gb.Nfa;else{var f;a:{f=d.stack;for(var g=f.length,h=0;h<g;h++){var l=f[h];if(l===b&&b.constructor===l.constructor){f=!0;break a}}f=!1}if(f)return null}d.push(b);f=e.Dvb;e=gb.l4(a.ownerDocument,e.name);a.appendChild(e);f.encode(e,b,d,this);d.pop(b);return e};r.a("AdfMarshalingService.prototype.marshal",{Ry:gb.prototype.Ry});
gb.getDefault=function(){var a=gb.Tbb;a||(a=new gb,a.cua(new gb.Ke),gb.Tbb=a);return a};m("AdfMarshalingService.getDefault",gb.getDefault);function Ef(a,b){return a.P7[b===String?"String":b===Boolean?"Boolean":b===Number?"Number":b===Array?"Array":b===Date?"Date":G.prototype.isPrototypeOf(b.prototype)?"AdfUIComponent":w===b?"AdfKeyStroke":"Object"]}
gb.l4=function(a,b){var d=q.b;return d.S()==q.ia&&11>d.Ib()?a.createNode(1,b,"http://oracle.com/richClient/comm"):a.createElementNS("http://oracle.com/richClient/comm",b)};gb.Nfa=function(){this.stack=[]};gb.Nfa.prototype.push=function(a){this.stack.push(a)};gb.Nfa.prototype.pop=function(){return this.stack.pop()};
gb.Ke=function(){var a={};a.Number=gb.Ke.XWa;a.Boolean=gb.Ke.xWa;a.String=gb.Ke.hXa;a.Date=gb.Ke.EWa;a.Array=gb.Ke.oWa;a.Object=gb.Ke.RWa;a.AdfUIComponent=gb.Ke.iWa;a.AdfKeyStroke=gb.Ke.hWa;this.P7=a};gb.Ke.pWa="o";gb.Ke.sya="k";gb.Ke.Cza="v";gb.Ke.CWa="n";gb.Ke.XWa="n";gb.Ke.xWa="b";gb.Ke.hXa="s";gb.Ke.EWa="d";gb.Ke.oWa="a";gb.Ke.RWa="m";gb.Ke.iWa="AdfUIComponent";gb.Ke.hWa="AdfKeyStroke";
gb.Ke.prototype.encode=function(a,b,d,e){var f=null,g=a.ownerDocument,h=b.constructor;if(h==String||h==Number)f=b;else if(h==Boolean)f=b?"1":"0";else if(h==Date)f=b.getTime();else if(h==Array){for(var l=0;l<b.length;l++)h=null,null!=b[l]&&(h=e.Ry(a,b[l],d)),null==h&&a.appendChild(gb.l4(g,gb.Ke.pWa));a.setAttribute(gb.Ke.CWa,b.length)}else if(h==Object)for(l in b)h=gb.l4(g,gb.Ke.sya),h.setAttribute(gb.Ke.Cza,l),a.appendChild(h),null!=b[l]&&e.Ry(h,b[l],d);else if(G.prototype.isPrototypeOf(b))f=b.g();
else if(w.prototype.isPrototypeOf(b))f=b.Qs();else for(var n in b)try{var t=b[n];if(null!=t&&"function"!=typeof t){var y=gb.l4(g,gb.Ke.sya);y.setAttribute(gb.Ke.Cza,n);a.appendChild(y);e.Ry(y,t,d)}}catch(z){v.l.Ge(z,"Error in marshaling object")}null!=f&&a.appendChild(g.createTextNode(f.toString()))};