proxyFactory.setLocalEnabled(true);
proxyFactory.setHessian2Reply(false);
// proxyFactory.setDebug(true);
HessianCAHProxyFactory.setCookieSeterName("Set-Cookie");
try {
PublicService api=proxyFactory.create(PublicService.class, url,
new DefaultCacheHandler(),
new CRMAsynTaskExecuter<Object, Throwable>(),
new CRMExceptionHandler(),null);
// parseAnnotations(api.getClass());
//Thread.sleep(1000);
//System.out.println(api.login("guxuede", "123456"));
// System.out.println(GxdInputStream.getAccumulatTotalLength());
// System.out.println(api.getAllAccountList());
// api.login("guxuede","123456",new CRMDefaultTaskListener<Staff,Throwable>(){
// @Override
// public void onExecuteSuccess(Method method, Object[] args,Staff result) {
// System.out.println("login sucess:"+result);
// }
// @Override
// public void onExceptionOccured(Method method, Object[] args,Throwable exception) {
// //exception.printStackTrace();
// System.out.println("异常:"+exception);
// }
// });
System.out.println(api.login("guxuede","123456"));
System.out.println(api.getLoginUser());
// System.out.println(api.login("guxuede","123456"));
// Thread.sleep(15000);
// System.out.println(api.login("guxuede","123456"));
} catch (Exception e) {
//System.out.println(e.getCause());