protected TCPMessageChannel( Socket sock, SIPMessageStack sipStack, TCPMessageProcessor msgProcessor) throws IOException { if (LogWriter.needsLogging)  { sipStack.logWriter.logMessage( "creating new TCPMessageChannel "); sipStack.logWriter.logStackTrace(); } mySock = sock; peerAddress = mySock.getInetAddress(); myAddress = sipStack.getHostAddress(); myClientInputStream = mySock.getInputStream(); myClientOutputStream = mySock.getOutputStream(); mythread = new Thread(this); mythread.setDaemon(true); mythread.setName("TCPMessageChannelThread");  stack = sipStack; this.tcpMessageProcessor = msgProcessor; this.myPort = this.tcpMessageProcessor.getPort();  super.messageProcessor = msgProcessor;  mythread.start(); }
protected TCPMessageChannel(SIPTransactionStack sipStack) { this.sipStack = sipStack;  }
    protected TCPMessageChannel(    Socket sock,    SIPMessageStack sipStack,    TCPMessageProcessor msgProcessor)    throws IOException {        if (LogWriter.needsLogging)  {            sipStack.logWriter.logMessage(            "creating new TCPMessageChannel ");            sipStack.logWriter.logStackTrace();        }        mySock = sock;        peerAddress = mySock.getInetAddress();        myAddress = sipStack.getHostAddress();        myClientInputStream = mySock.getInputStream();        myClientOutputStream = mySock.getOutputStream();        mythread = new Thread(this);	mythread.setDaemon(true);        mythread.setName("TCPMessageChannelThread");        // Stash away a pointer to our stack structure.        stack = sipStack;        this.tcpMessageProcessor = msgProcessor;        this.myPort = this.tcpMessageProcessor.getPort();        // Bug report by Vishwashanti Raj Kadiayl        super.messageProcessor = msgProcessor;        // Can drop this after response is sent potentially.        mythread.start();    }