/*
		* Accept an incoming connection from a remote node. Used by {@link
		* OtpSelf#accept() OtpSelf.accept()} to create a connection
		* based on data received when handshaking with the peer node, when
		* the remote node is the connection intitiator.
		*
		* @exception C#.io.IOException if it was not possible to connect to the peer.
		*
		* @exception OtpAuthException if handshake resulted in an authentication error
		*/
		// package scope
		internal OtpCookedConnection(OtpNode self, System.Net.Sockets.TcpClient s):base(self, s)
		{
			this.self = self;
			this.links = new Links(25);
            this.monitors = new System.Collections.Hashtable(49, (float)0.95);

			thread = new System.Threading.Thread(new System.Threading.ThreadStart(Start));
			thread.IsBackground = true;
			thread.Name = "cooked connection "+self.node()+" | "+s.ToString();
			thread.Start();
		}
Exemple #2
0
 // package constructor: called by OtpNode:createMbox(name)
 // to create a named mbox
 internal OtpMbox(OtpNode home, Erlang.Pid self, System.String name)
 {
     this._self = self;
     this.home = home;
     this.name = name;
     this.queue = new GenericQueue();
     this.links = new Links(10);
 }
Exemple #3
0
		// package constructor: called by OtpNode:createMbox(name)
		// to create a named mbox
		internal OtpMbox(OtpNode home, Erlang.Pid self, System.String name)
		{
			this._self = self;
			this.home = home;
			this.name = name;
			this.queue = new GenericQueue();
			this.links = new Links(10);
            this.monitors = new System.Collections.Hashtable(49, (float)0.95);
		}
        /*
		* Intiate and open a connection to a remote node.
		*
		* @exception C#.io.IOException if it was not possible to connect to the peer.
		*
		* @exception OtpAuthException if handshake resulted in an authentication error.
		*/
		// package scope
		internal OtpCookedConnection(OtpNode self, OtpPeer other, string cookie)
            : base(self, other, cookie)
		{
			this.self = self;
			this.links = new Links(25);
            this.monitors = new System.Collections.Hashtable(49, (float)0.95);

			thread = new System.Threading.Thread(new System.Threading.ThreadStart(Start));
			thread.IsBackground = true;
			thread.Name = "cooked connection2 "+self.node()+"->"+other.node();
			thread.Start();
		}
        /*
        * Intiate and open a connection to a remote node.
        *
        * @exception C#.io.IOException if it was not possible to connect to the peer.
        *
        * @exception OtpAuthException if handshake resulted in an authentication error.
        */
        // package scope
        internal OtpCookedConnection(OtpNode self, OtpPeer other)
            : base(self, other)
        {
            this.self = self;
            this.links = new Links(25);

            thread = new System.Threading.Thread(new System.Threading.ThreadStart(Start));
            thread.IsBackground = true;
            thread.Name = "cooked connection2 "+self.node()+"->"+other.node();
            thread.Start();
        }