Пример #1
0
        //
        // Methods
        //

        public void SendUserRegistration( )
        {
            if (null == _protocolHandler)
            {
                throw new InvalidOperationException("Server.ProtocolHandler property must be set before using SendUserRegistration method");
            }

            Debug.Print("Server.SendUserRegistration");

            if (!string.IsNullOrWhiteSpace(ServerPassword))
            {
                _protocolHandler.SendToServer("PASS {0}", ServerPassword);
            }

            _protocolHandler.StartCapture("Server.SendUserRegistration running CapNegotiator");
            var capNego = new CapNegotiator(this, CapNegotiatorComplete);

            capNego.Start( );
        }
Пример #2
0
        //
        // Methods
        //

        public void SendUserRegistration( )
        {
            if (null == _protocolHandler)
            {
                throw new InvalidOperationException("Server.ProtocolHandler property must be set before using SendUserRegistration method");
            }

            Debug.Print("Server.SendUserRegistration");

            if (!string.IsNullOrWhiteSpace(ServerPassword))
            {
                _protocolHandler.SendToServer("PASS {0}", ServerPassword);
            }

            var capNego = new CapNegotiator {
                Server = this,
            };

            capNego.Complete += CapNegotiatorComplete;

            _protocolHandler.SaveAndClearHandlers( );
            capNego.RegisterMessages( );
            capNego.Start( );
        }
Пример #3
0
        //
        // Methods
        //
        public void SendUserRegistration( )
        {
            if ( null == _protocolHandler ) {
                throw new InvalidOperationException( "Server.ProtocolHandler property must be set before using SendUserRegistration method" );
            }

            Debug.Print( "Server.SendUserRegistration" );

            if ( !string.IsNullOrWhiteSpace( ServerPassword ) ) {
                _protocolHandler.SendToServer( "PASS {0}", ServerPassword );
            }

            _protocolHandler.StartCapture( "Server.SendUserRegistration running CapNegotiator" );
            var capNego = new CapNegotiator( this, CapNegotiatorComplete );
            capNego.Start( );
        }
Пример #4
0
        //
        // Methods
        //
        public void SendUserRegistration( )
        {
            if ( null == _protocolHandler ) {
                throw new InvalidOperationException( "Server.ProtocolHandler property must be set before using SendUserRegistration method" );
            }

            Debug.Print( "Server.SendUserRegistration" );

            if ( !string.IsNullOrWhiteSpace( ServerPassword ) ) {
                _protocolHandler.SendToServer( "PASS {0}", ServerPassword );
            }

            var capNego = new CapNegotiator {
                Server = this,
            };
            capNego.Complete += CapNegotiatorComplete;

            _protocolHandler.SaveAndClearHandlers( );
            capNego.RegisterMessages( );
            capNego.Start( );
        }