diff options
Diffstat (limited to 'cs/demo/Ice/throughput/Server.cs')
-rw-r--r-- | cs/demo/Ice/throughput/Server.cs | 37 |
1 files changed, 24 insertions, 13 deletions
diff --git a/cs/demo/Ice/throughput/Server.cs b/cs/demo/Ice/throughput/Server.cs index 7876ef284fd..3ed018453de 100644 --- a/cs/demo/Ice/throughput/Server.cs +++ b/cs/demo/Ice/throughput/Server.cs @@ -7,27 +7,38 @@ // // ********************************************************************** -public class Server : Ice.Application +using System; +using System.Reflection; + +[assembly: CLSCompliant(true)] + +[assembly: AssemblyTitle("IceThroughputServer")] +[assembly: AssemblyDescription("Ice throughput demo server")] +[assembly: AssemblyCompany("ZeroC, Inc.")] + +public class Server { - public override int - run(string[] args) + public class App : Ice.Application { - if(args.Length > 0) + public override int run(string[] args) { - System.Console.Error.WriteLine(appName() + ": too many arguments"); - return 1; - } + if(args.Length > 0) + { + System.Console.Error.WriteLine(appName() + ": too many arguments"); + return 1; + } - Ice.ObjectAdapter adapter = communicator().createObjectAdapter("Throughput"); - adapter.add(new ThroughputI(), communicator().stringToIdentity("throughput")); - adapter.activate(); - communicator().waitForShutdown(); - return 0; + Ice.ObjectAdapter adapter = communicator().createObjectAdapter("Throughput"); + adapter.add(new ThroughputI(), communicator().stringToIdentity("throughput")); + adapter.activate(); + communicator().waitForShutdown(); + return 0; + } } public static void Main(string[] args) { - Server app = new Server(); + App app = new App(); int status = app.main(args, "config.server"); if(status != 0) { |