@Override public synchronized HelloPrx createHello(Ice.Current c) { if (_destroy) { throw new Ice.ObjectNotExistException(); } HelloPrx hello = HelloPrxHelper.uncheckedCast(c.adapter.addWithUUID(new HelloI(_name, _nextId++))); _objs.add(hello); return hello; }
@Override public int run(String[] args) { if (args.length > 0) { System.err.println(appName() + ": too many arguments"); return 1; } HelloPrx hello = HelloPrxHelper.uncheckedCast(communicator().propertyToProxy("Hello.Proxy")); if (hello == null) { System.err.println(appName() + ": Hello.Proxy not set"); return 1; } hello.sayHello(); return 0; }