public void Start(IConfigSource config, IRegistryCore registry)
        {
            GridInfoHandlers handlers = new GridInfoHandlers(config, registry);
            registry.RegisterModuleInterface<IGridInfo>(handlers);

            IConfig handlerConfig = config.Configs["Handlers"];
            if (handlerConfig.GetString("GridInfoInHandler", "") != Name)
                return;

            handlerConfig = config.Configs["GridInfoService"];
            IHttpServer server =
                registry.RequestModuleInterface<ISimulationBase>().GetHttpServer(
                    (uint) handlerConfig.GetInt("GridInfoInHandlerPort", 0));

            server.AddStreamHandler(new GenericStreamHandler("GET", "/get_grid_info",
                                                             handlers.RestGetGridInfoMethod));
            server.AddXmlRPCHandler("get_grid_info", handlers.XmlRpcGridInfoMethod);
        }
        public void Start(IConfigSource config, IRegistryCore registry)
        {
            GridInfoHandlers handlers = new GridInfoHandlers(config, registry);

            registry.RegisterModuleInterface <IGridInfo>(handlers);

            IConfig handlerConfig = config.Configs["Handlers"];

            if (handlerConfig.GetString("GridInfoInHandler", "") != Name)
            {
                return;
            }

            handlerConfig = config.Configs["GridInfoService"];
            IHttpServer server =
                registry.RequestModuleInterface <ISimulationBase>().GetHttpServer(
                    (uint)handlerConfig.GetInt("GridInfoInHandlerPort", 0));

            server.AddStreamHandler(new GenericStreamHandler("GET", "/get_grid_info",
                                                             handlers.RestGetGridInfoMethod));
            server.AddXmlRPCHandler("get_grid_info", handlers.XmlRpcGridInfoMethod);
        }