HessianConnectionFactory connFactory=new MyConnectionFactory();
proxyFactory.setConnectionFactory(connFactory);
connFactory.setHessianProxyFactory(proxyFactory);
try {
IWeibo weibo;
weibo = (IWeibo) proxyFactory.create(IWeibo.class, url);
System.out.println(weibo.getContacts());
} catch (Exception e) {
System.out.println("Exception:"+ ((InteractionException)e).getTypeId());
e.printStackTrace();
}
try {
IWeibo weibo;
weibo = (IWeibo) proxyFactory.create(IWeibo.class, url);
System.out.println(weibo.getContacts());
} catch (Exception e) {
System.out.println("Exception:"+ ((InteractionException)e).getTypeId());
e.printStackTrace();
}
}