private networkManager(incomingLineEventHandler incomingDriveLineHandler, incomingLineEventHandler incomingEngineeringLineHandler, incomingLineEventHandler incomingArmLineHandler, incomingLineEventHandler incomingLogisticsLineHandler) { //Drive networking setup incomingDrive = incomingDriveLineHandler; DRIVECOM = new commSockSender("DRIVECOM"); DRIVECOM.incomingLineEvent += DRIVECOM_incomingLineEvent; DRIVECOM.connectionStatusChanged += DRIVECOM_connectionStatusChanged; DRIVECOM.beginConnect(rocConstants.MCIP_DRIVE, rocConstants.MCPORT_DRIVE); //Engineering networking setup incomingEngineering = incomingEngineeringLineHandler; ENGCOM = new commSockSender("ENGCOM"); ENGCOM.incomingLineEvent += ENGCOM_incomingLineEvent; ENGCOM.connectionStatusChanged += ENGCOM_connectionStatusChanged; ENGCOM.beginConnect(rocConstants.MCIP_ENG, rocConstants.MCPORT_ENGINEERING); //Arm networking setup incomingArm = incomingArmLineHandler; ARMCOM = new commSockSender("ARMCOM"); ARMCOM.incomingLineEvent +=ARMCOM_incomingLineEvent; ARMCOM.connectionStatusChanged +=ARMCOM_connectionStatusChanged; ARMCOM.beginConnect(rocConstants.MCIP_ARM, rocConstants.MCPORT_ARM); //Logistics networking setup incomingLogistics = incomingLogisticsLineHandler; LOGCOM = new commSockSender("LOGCOM"); LOGCOM.incomingLineEvent += LOGCOM_incomingLineEvent; LOGCOM.connectionStatusChanged += LOGCOM_connectionStatusChanged; LOGCOM.beginConnect(rocConstants.MCIP_LOGISTICS, rocConstants.MCPORT_LOGISTICS); }
public MainWindow() { InitializeComponent(); connectButton.Click += connectButton_Click; disconnectButton.Click += disconnectButton_Click; CSock = new commSockSender("testSock"); CSock.connectionStatusChanged += CSock_connectionStatusChanged; CSock.incomingLineEvent += CSock_incomingLineEvent; }