public PacketIF(String server, int port, bool local, bool asClient) { Debug.Assert(server != null); wpClientData = this; workProcInstalled = false; socket = null; error = false; deferPacketHandling = false; deleting = false; packetSender = false; line = ""; echoCallback = null; echoClientData = null; endReceiving = true; linkHandler = null; stallingWorker = null; stallingWorkerData = null; if (asClient) connectAsClient(server, port, local); else connectAsServer(port); output_queue = new List<QueuedBytes>(); if (!error) { installInputHandler(); } }
protected virtual void installLinkHandler() { linkHandler = new LinkHandler(this); }