Exemple #1
0
        /// <summary>
        /// Add new listener with message collector (character splitter).
        /// </summary>
        /// <param name="name">The listener's name.</param>
        /// <param name="ipAddress">The listener's IP address.</param>
        /// <param name="port">The listener's tcp port.</param>
        /// <param name="maxConnections">The number of maximum allowed connections.</param>
        /// <param name="readBufferSize">The read buffer size for each connection in bytes.</param>
        /// <param name="connectionTimeOut">The connections time-out in milliseconds. Set to 0 for no time-out.</param>
        /// <param name="backLog">The number of outstanding connection requests the listener can have.</param>
        /// <param name="splitter">The message splitter.</param>
        /// <returns>The listener.</returns>
        public TCPListener AddListener(string name, IPAddress ipAddress, int port, int maxConnections, int readBufferSize, int connectionTimeOut, int backLog, string splitter)
        {
            TCPListener listener = new TCPListener(name, ipAddress, port, maxConnections, readBufferSize, connectionTimeOut, backLog, splitter);

            listener.SetMyExtasysTCPServer(this);
            fListeners.Add(listener);
            return(listener);
        }