
function CMS_RequestParam(mm){this.cf=CONFIG_PARAM;this.map=mm;}
CMS_RequestParam.prototype.setParam=function(){if(!this.cf.vp||this.cf.vp<0){this.cf.vp=this.cf.DEFAULT_VP;}
if(!this.cf.enc||this.cf.enc==''){this.cf.enc=this.cf.DEFAULT_ENC;}
if(this.cf.leg){if(this.cf.leg==''||this.cf.leg<this.cf.DEFAULT_LEG_MIN||this.cf.leg>this.cf.DEFAULT_LEG_MAX){this.cf.leg=this.cf.DEFAULT_LEG_MIN;}}
else{if(_ZIDtoSCL[this.map.getZoomLevel()]>=500000){this.cf.large_area_leg=10000;}
else{this.cf.large_area_leg='';}}
if(!this.cf.bid){this.cf.bid='';}
if(!this.cf.num||this.cf.num==''){this.cf.num=this.cf.DEFAULT_NUM;}
if(this.cf.marge_num&&this.cf.marge_num!=''){this.cf.merge_num=this.cf.marge_num;}else if(this.cf.merge_num&&this.cf.merge_num!=''){this.cf.merge_num=this.cf.merge_num;}else{this.cf.merge_num=this.cf.DEFAULT_MERGE_NUM;}
if(this.cf.marge_vp&&this.cf.marge_vp!=''){this.cf.merge_vp=this.cf.marge_vp;}else if(this.cf.merge_vp&&this.cf.merge_vp!=''){this.cf.merge_vp=this.cf.merge_vp;}else{this.cf.merge_vp=this.cf.DEFAULT_VP;}
if(!this.cf.flg_mass||(this.cf.flg_mass!=0&&this.cf.flg_mass!=1))this.cf.flg_mass=1;}
CMS_RequestParam.prototype.getNpURL=function(){this.setParam();var url=this.cf.FRONT_URL+this.cf.API+"/nearestPoi2?";if(typeof(this.cf.site_id)!="undefined")url+='mid='+this.cf.site_id;if(typeof(this.cf.site_pw)!="undefined")url+='&mpw='+this.cf.site_pw;return url;}
CMS_RequestParam.prototype.getNpAddURL=function(){this.setParam();var url=this.cf.FRONT_URL+this.cf.API+"/nearestAdd?";url+='mid='+this.cf.site_id;url+='&mpw='+this.cf.site_pw;return url;}
CMS_RequestParam.prototype.getNpMAlpsParam=function(){this.setParam();var param="";if(!this.cf.leg){if(this.cf.large_area_leg==''){param+="&scl="+_ZIDtoSCL[this.map.getZoomLevel()];if(this.cf.size_w==""||this.cf.size_h==""||this.cf.flg_resize==1){param+="&size="+this.map.div.offsetWidth+","+this.map.div.offsetHeight;}else{param+="&size="+this.cf.size_w+","+this.cf.size_h;}}else{param+="&leg="+this.cf.large_area_leg;}}else{param+="&leg="+this.cf.leg;}
param+="&gnr="+_GNR_CODE;param+="&vp="+this.cf.merge_vp;param+="&enc="+this.cf.enc;if(this.cf.search_grp!=''){if(this.cf.search_grp.indexOf(',')!=-1){var lays=this.cf.search_grp.split(',');for(var i=0;i<lays.length;i++){param+="&sgrp="+lays[i];}}else{param+="&sgrp="+this.cf.search_grp;}
param+="&grp="+this.cf.grp;}else{param+="&grp="+this.cf.grp;}
return param;}
CMS_RequestParam.prototype.getNpMMlocalParam=function(){this.setParam();var param="";param+="&scl="+_ZIDtoSCL[this.map.getZoomLevel()];param+="&bid="+this.cf.bid;param+="&num="+this.cf.merge_num;param+="&tag="+_MLOCAL_TAG;param+="&mass="+this.cf.flg_mass;param+="&ad=1";if(this.cf.size_w==""||this.cf.size_h==""||this.cf.flg_resize==1){param+="&size="+this.map.div.offsetWidth+","+this.map.div.offsetHeight;}else{param+="&size="+this.cf.size_w+","+this.cf.size_h;}
return param;}
CMS_RequestParam.prototype.getNpAlpsParam=function(){this.setParam();var param="";if(!this.cf.leg){if(this.cf.large_area_leg==''){param+="&scl="+_ZIDtoSCL[this.map.getZoomLevel()];if(this.cf.size_w==""||this.cf.size_h==""||this.cf.flg_resize==1){param+="&size="+this.map.div.offsetWidth+","+this.map.div.offsetHeight;}else{param+="&size="+this.cf.size_w+","+this.cf.size_h;}}else{param+="&leg="+this.cf.large_area_leg;}}else{param+="&leg="+this.cf.leg;}
param+="&gnr="+_GNR_CODE;param+="&vp="+this.cf.vp;param+="&enc="+this.cf.enc;if(typeof(this.cf.search_grp)!="undefined"&&this.cf.search_grp!=''){if(this.cf.search_grp.indexOf(',')!=-1){var lays=this.cf.search_grp.split(',');for(var i=0;i<lays.length;i++){param+="&sgrp="+lays[i];}}else{param+="&sgrp="+this.cf.search_grp;}
param+="&grp="+this.cf.grp;}else{param+="&grp="+this.cf.grp;}
return param;}
CMS_RequestParam.prototype.getNpMlocalParam=function(){this.setParam();var param="";param+="&grp="+this.cf.grp;param+="&scl="+_ZIDtoSCL[this.map.getZoomLevel()];param+="&bid="+this.cf.bid;param+="&num="+this.cf.num;param+="&tag="+_MLOCAL_TAG;param+="&mass="+this.cf.flg_mass;if(this.cf.size_w==""||this.cf.size_h==""){param+="&size="+this.map.div.offsetWidth+","+this.map.div.offsetHeight;}else{param+="&size="+this.cf.size_w+","+this.cf.size_h;}
return param;}
CMS_RequestParam.prototype.getNextNpMlocalParam=function(_a){this.setParam();var param="";param+="&grp="+this.cf.grp;param+="&scl="+_ZIDtoSCL[this.map.getZoomLevel()];param+="&tr="+this.cf.poiinfo.trans_code;param+="&pnum="+eval(new Number(this.cf.poiinfo.page)+1);param+="&bid="+this.cf.bid;param+="&vp="+this.cf.num;param+="&tag="+_MLOCAL_TAG;param+="&mass="+this.cf.flg_mass;if(this.cf.size_w==""||this.cf.size_h==""||this.cf.flg_resize==1){param+="&size="+this.map.div.offsetWidth+","+this.map.div.offsetHeight;}else{param+="&size="+this.cf.size_w+","+this.cf.size_h;}
return param;}
CMS_RequestParam.prototype.getPrevNpMlocalParam=function(_a){this.setParam();var param="";param+="&grp="+this.cf.grp;param+="&scl="+_ZIDtoSCL[this.map.getZoomLevel()];param+="&tr="+this.cf.poiinfo.trans_code;param+="&pnum="+eval(new Number(this.cf.poiinfo.page)-1);param+="&bid="+this.cf.bid;param+="&vp="+this.cf.num;param+="&tag="+_MLOCAL_TAG;param+="&mass="+this.cf.flg_mass;if(this.cf.size_w==""||this.cf.size_h==""||this.cf.flg_resize==1){param+="&size="+this.map.div.offsetWidth+","+this.map.div.offsetHeight;}else{param+="&size="+this.cf.size_w+","+this.cf.size_h;}
return param;}
CMS_RequestParam.prototype.getPosURL=function(){this.setParam();var url=this.cf.FRONT_URL+this.cf.API+"/posInfo?";url+="grp="+this.cf.grp;url+="&el="+CMSCommon.change10to60(this.map.getCenterLatLng().x);url+="&nl="+CMSCommon.change10to60(this.map.getCenterLatLng().y);return url;}
CMS_RequestParam.prototype.getNpMBlockParam=function(){if(!CONFIG_PARAM['grp'])return;var url=CONFIG_PARAM['PROTOCOL']+CONFIG_PARAM["block_domain"]+"/map/uc/PoiWithin?";if(!CONFIG_PARAM["block_grp"]&&typeof(CONFIG_PARAM["block_grp"]=="undefined")||CONFIG_PARAM["block_grp"]==""){url+="grp="+CONFIG_PARAM["grp"];}else{url+="grp="+CONFIG_PARAM["block_grp"];}
url+="&sgrp="+mblock_grp;url+="&el="+this.map.getCenterLatLng().x;url+="&nl="+this.map.getCenterLatLng().y;url+="&minel="+this.map.getBoundsLatLng().minX;url+="&minnl="+this.map.getBoundsLatLng().minY;url+="&maxel="+this.map.getBoundsLatLng().maxX;url+="&maxnl="+this.map.getBoundsLatLng().maxY;url+="&scl="+_ZIDtoSCL[this.map.getZoomLevel()];url+="&start=1";url+="&pm="+CONFIG_PARAM["pm"];if(!CONFIG_PARAM["ie"]&&typeof(CONFIG_PARAM["ie"]=="undefined")||CONFIG_PARAM["ie"]==""){url+="&ie=euc_jp";}else{url+="&ie="+CONFIG_PARAM["ie"].toString();}
if(!CONFIG_PARAM["oe"]&&typeof(CONFIG_PARAM["oe"]=="undefined")||CONFIG_PARAM["oe"]==""){url+="&oe=euc_jp";}else{url+="&oe="+CONFIG_PARAM["oe"].toString();}
if(mblock_code!=""){url+="&search_str01="+mblock_code;}
url+="&vo=mbml";url+="&json=1";url+="&callback=cb_getNpMBlockParam";return url;}
CMS_RequestParam.prototype.getNpMBlockMlocalParam=function(){if(!CONFIG_PARAM['grp'])return;var url=CONFIG_PARAM['PROTOCOL']+CONFIG_PARAM["block_domain"]+"/map/uc/PoiWithin?";if(!CONFIG_PARAM["block_grp"]&&typeof(CONFIG_PARAM["block_grp"]=="undefined")||CONFIG_PARAM["block_grp"]==""){url+="grp="+CONFIG_PARAM["grp"];}else{url+="grp="+CONFIG_PARAM["block_grp"];}
url+="&sgrp="+mblock_grp;url+="&el="+this.map.getCenterLatLng().x;url+="&nl="+this.map.getCenterLatLng().y;url+="&minel="+this.map.getBoundsLatLng().minX;url+="&minnl="+this.map.getBoundsLatLng().minY;url+="&maxel="+this.map.getBoundsLatLng().maxX;url+="&maxnl="+this.map.getBoundsLatLng().maxY;url+="&scl="+_ZIDtoSCL[this.map.getZoomLevel()];url+="&start=1";url+="&pm="+CONFIG_PARAM["marge_pm"];if(!CONFIG_PARAM["ie"]&&typeof(CONFIG_PARAM["ie"]=="undefined")||CONFIG_PARAM["ie"]==""){url+="&ie=euc_jp";}else{url+="&ie="+CONFIG_PARAM["ie"].toString();}
if(!CONFIG_PARAM["oe"]&&typeof(CONFIG_PARAM["oe"]=="undefined")||CONFIG_PARAM["oe"]==""){url+="&oe=euc_jp";}else{url+="&oe="+CONFIG_PARAM["oe"].toString();}
if(mblock_code!=""){url+="&search_str01="+mblock_code;}
url+="&vo=mbml";url+="&json=1";url+="&over_dist=1";url+="&callback=cb_getNpMBlockMlocalParam";url+="&site_id="+this.cf.site_id;url+="&site_pw="+this.cf.site_pw;url+="&cate_code="+_MLOCAL_TAG;url+="&req_count="+this.cf.merge_num;url+="&mas_flag="+this.cf.flg_mass;return url;}
