public void Register(RequestControllerConfigure controller) { IControllerConfigure client = null; try { client = myChannelFactory.CreateChannel(); client.ConnectToController(controller); ((ICommunicationObject)client).Close(); } catch { if (client != null) { ((ICommunicationObject)client).Abort(); } } }
public ResponseControllerConfigure GetController() { ResponseControllerConfigure result = new ResponseControllerConfigure(); IControllerConfigure client = null; try { client = myChannelFactory.CreateChannel(); result = client.GetController(); ((ICommunicationObject)client).Close(); } catch { if (client != null) { ((ICommunicationObject)client).Abort(); } } return(result); }