diff options
Diffstat (limited to 'java/test/Ice/classLoader/Server.java')
-rw-r--r-- | java/test/Ice/classLoader/Server.java | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/java/test/Ice/classLoader/Server.java b/java/test/Ice/classLoader/Server.java new file mode 100644 index 00000000000..fa68d032e53 --- /dev/null +++ b/java/test/Ice/classLoader/Server.java @@ -0,0 +1,41 @@ +// ********************************************************************** +// +// Copyright (c) 2003-2009 ZeroC, Inc. All rights reserved. +// +// This copy of Ice is licensed to you under the terms described in the +// ICE_LICENSE file included in this distribution. +// +// ********************************************************************** + +package test.Ice.classLoader; + +public class Server extends test.Util.Application +{ + public int run(String[] args) + { + Ice.Communicator communicator = communicator(); + Ice.ObjectAdapter adapter = communicator.createObjectAdapter("TestAdapter"); + Ice.Object object = new InitialI(adapter); + adapter.add(object, communicator.stringToIdentity("initial")); + adapter.activate(); + + return WAIT; + } + + protected Ice.InitializationData getInitData(Ice.StringSeqHolder argsH) + { + Ice.InitializationData initData = new Ice.InitializationData(); + initData.properties = Ice.Util.createProperties(argsH); + initData.properties.setProperty("Ice.Package.Test", "test.Ice.classLoader"); + initData.properties.setProperty("TestAdapter.Endpoints", "default -p 12010"); + return initData; + } + + public static void main(String[] args) + { + Server app = new Server(); + int result = app.main("Server", args); + System.gc(); + System.exit(result); + } +} |