public class Server {
public static void main(String[] args) {
CoreRemoteCallFramework.init();
CoreRemoteCallFramework.registerService("ServiceName", new ServiceImpl());
CoreRemoteCallFramework.startServer();
}
}
public class Client {
public static void main(String[] args) {
CoreRemoteCallFramework.init();
ServiceInterface service = CoreRemoteCallFramework.getService("ServiceName");
service.remoteMethod();
}
}
<config>
<server>
<port>8080</port>
</server>
<client>
<serverAddress>127.0.0.1</serverAddress>
<serverPort>8080</serverPort>
</client>
</config>