CSharpRTMP.Core.NetIO.IOHandler.Dispose C# (CSharp) Method

Dispose() public method

public Dispose ( ) : void
return void
        public virtual void Dispose()
	    {
	        if (Protocol != null) {
		        Protocol.IOHandler = null;
		        Protocol.EnqueueForDelete();
		        Protocol = null;
	        }
	        this.UnRegisterIOHandler();
	    }

Usage Example

 public static void EnqueueForDelete(IOHandler ioHandler)
 {
     ioHandler.WriteEnabled  = false;
     ioHandler.ReadEnabled   = false;
     ioHandler.AcceptEnabled = false;
     ioHandler.DisableTimer();
     ioHandler.Dispose();
     //DeadIoHandler.AddLast(ioHandler);
 }
All Usage Examples Of CSharpRTMP.Core.NetIO.IOHandler::Dispose