function SnoovelCom(){
this.init=function(){
var _1=window.location.protocol;
_1=_1+"//"+window.location.host;
geodmService=conf_geodm_url;
};
this.getHrsMovie=function(_2,_3){
requestUrl=geodmService+"action=hrsGenHotelList&hrsObjectList="+dojo.toJson(_2);
try{
var _4=dojo.xhrGet({url:requestUrl,load:dojo.hitch(_3,"callbackMovie"),error:function(){
snConsole.debug("Request timed out.");
},timeout:100000,mimetype:"text/json"});
}
catch(e){
snConsole.debug("Error in "+e);
}
};
this.getMovieList=function(id,_6,_7){
var _8;
if(_6!=""){
_8=geodmService+"action=moviebykey&uid="+id+"&key="+_6;
}else{
_8=geodmService+"action=moviebyid&format=json&uid="+id;
}
try{
var _9=dojo.xhrGet({url:_8,load:dojo.hitch(_7,"callbackMovie"),error:function(){
snConsole.debug("Request timed out.");
},timeout:100000,mimetype:"text/json"});
}
catch(e){
snConsole.debug("Error in "+e);
}
};
this.getSceneList=function(id,_b){
var _c=geodmService+"action=scenebyid&uid="+id;
try{
var _d=dojo.xhrGet({url:_c,timeout:10000,error:function(){
snConsole.debug("Request threw error.");
alert(i18n.MSG_ERROR_UNKNOWNERROR);
},cancel:function(){
snConsole.debug("Request was canceld.");
alert(i18n.MSG_ERROR_UNKNOWNERROR);
},load:dojo.hitch(_b,"callbackSceneList")});
}
catch(e){
snConsole.debug(e);
}
};
this.getSceneImage=function(id,_f){
var _10=service+"&service=imageservice&pid="+id;
try{
var _11=dojo.xhrGet({url:_10,timeout:10000,error:function(){
snConsole.debug("Request threw error.");
},cancel:function(){
snConsole.debug("Request was canceld.");
},load:function(){
snConsole.debug("Callback getSceneImage");
}});
}
catch(e){
console.debug(e);
}
};
this.getGeObjectsToPoi=function(id,poi){
var _14=service+"&service=getGeObjects&snid="+id+"&snpoi="+poi;
snConsole.debug(_14);
try{
var _15=dojo.xhrGet({url:_14,load:dojo.hitch(snoovelCom,"callbackGetTrack"),error:function(){
snConsole.debug("Request timed out.");
},timeout:10000,mimetype:"text/xml"});
}
catch(e){
snConsole.debug(e);
}
};
this.getPublicMovies=function(){
var me=this;
var _17=service+"&service=movielist";
try{
var _18=dojo.xhrGet({url:_17,load:dojo.hitch(geList,"callbackPublicMovies"),error:function(){
snConsole.debug("Request timed out.");
},timeout:10000,mimetype:"text/xml"});
}
catch(e){
snConsole.debug("Error in "+e);
}
};
this.getMovieComments=function(_19){
var me=this;
var _1b=geodmService+"action=loadComments&tour="+_19+"&nocache="+new Date().getTime();
if(TOUR_KEY!=undefined){
_1b+="&key="+TOUR_KEY;
}
try{
var _1c=dojo.xhrGet({url:_1b,load:dojo.hitch(geDControl,"callbackLoadComments"),error:function(){
snConsole.debug("Request timed out.");
},timeout:10000,mimetype:"text/xml"});
}
catch(e){
snConsole.debug("Error in "+e);
}
};
this.getMovieStats=function(_1d){
var me=this;
var _1f=geodmService+"action=loadStats&tour="+_1d;
try{
var _20=dojo.xhrGet({url:_1f,load:dojo.hitch(geDControl,"callbackLoadStats"),error:function(){
snConsole.debug("Request timed out.");
},timeout:10000,mimetype:"text/xml"});
}
catch(e){
snConsole.debug("Error in "+e);
}
};
this.rateMovie=function(_21,_22){
var me=this;
var _24=geodmService+"action=submitRating&tour="+_21+"&rating="+_22;
if(TOUR_KEY!=undefined){
_24+="&key="+TOUR_KEY;
}
try{
var _25=dojo.xhrGet({url:_24,load:dojo.hitch(geDControl,"callbackSubmitRating"),error:function(){
snConsole.debug("Request timed out.");
},timeout:10000,mimetype:"text/xml"});
}
catch(e){
snConsole.debug("Error in "+e);
}
};
this.submitCommentForm=function(cf,_27){
var me=this;
var _29=conf_geodm_url+"action=addComment&tour="+_27;
if(TOUR_KEY!=undefined){
_29+="&key="+TOUR_KEY;
}
try{
var _2a=dojo.xhrPost({url:_29,form:cf,load:dojo.hitch(geDControl,"callbackAddedComment"),error:function(){
snConsole.debug("Request timed out.");
},timeout:10000,mimetype:"text/xml"});
}
catch(e){
snConsole.debug("Error in "+e);
}
};
this.submitLog=function(_2b){
var me=this;
var _2d=logServiceURL+"/LogAction?action=log";
try{
var _2e={url:_2d,postData:_2b,error:function(){
snConsole.debug("Request timed out.");
},timeout:10000,headers:{"Content-Type":"application/json"}};
var req=dojo.rawXhrPut(_2e);
}
catch(e){
snConsole.debug("Error in "+e);
}
};
this.loadLanguages=function(){
var me=this;
var _31=geodmService+"action=listCountries";
var _32=dojo.xhrGet({url:_31,load:dojo.hitch(geDControl,"callbackListCountries"),error:function(){
snConsole.debug("Request timed out.");
},timeout:10000,mimetype:"text/xml"});
};
this.init();
};


