コード例 #1
0
 /// <summary>
 /// Opens endpoint by allocating transports (if necessary).
 /// ServerEndpoint can be Close() or Dispose() after it was open
 /// </summary>
 public void Open()
 {
     EnsureObjectNotDisposed();
     if (m_IsOpen)
     {
         return;
     }
     m_Transport = m_Binding.OpenServerEndpoint(this);
     m_IsOpen    = true;
 }
コード例 #2
0
 public void Close()
 {
     if (!m_IsOpen)
     {
         return;
     }
     m_Binding.CloseServerEndpoint(this);
     m_Transport = null;
     m_IsOpen    = false;
 }
コード例 #3
0
ファイル: Transport.cs プロジェクト: dotnetchris/nfx
 /// <summary>
 /// Creates instance of a transport that resulted from connection accept by
 /// listener. Not all technologies support listener/child transports (TCP does)
 /// </summary>
 protected ServerTransport(Binding binding, ServerTransport listener)
     : base(binding, TransportKind.Server)
 {
     m_Listener       = listener;
     m_ServerEndpoint = listener.m_ServerEndpoint;
 }