	App_s = Class.create();
	S = Services = {
	  Version : '0.001',
	  Since : '2007-8-21 11:11:11',
	  Descr : '全局服务类的Locator' 
	}



Ajax.Service = Class.create();
Ajax.Service.prototype = {
  _defaultMethod : 'post',
  
  initialize : function()
  {   
  },
  
  Call : function(RemoteUrl, Para, CallBack, LoadingCallBack)
  {
    if ( arguments.length > 4 ) EvalResp = arguments[4];
    else EvalResp = false;    
    options = 
	{
      method : this._defaultMethod,
      parameters : Para 	  
    }    
        
    if ( EvalResp )
	{
     new Ajax.Request(RemoteUrl, {method: options.method, parameters: options.parameters,
		onLoading: LoadingCallBack,
        onSuccess: (function(Req){this.JSONEval(Req, CallBack)}).bind(this)});
    }
    else 
	{
      new Ajax.Request(RemoteUrl, {method: options.method, parameters: options.parameters, onSuccess: CallBack});
	}				
  },
	  
  JSONEval : function(Req, CallBack)
  {	
    if (Req.responseText == '')
	{
		CallBack(false);
		return;	
	}		
	var RespValid = true;    
    try
	{	 
      var res = eval('('+Req.responseText+')');     
    }
    catch(e)
	{
	  alert('Server Resp is not a valid JSON String');
      RespValid = false;
    }
    if (RespValid) CallBack(res);
  }

}
