Class Connection

java.lang.Object
com.sun.xml.ws.transport.tcp.io.Connection

public final class Connection extends Object
Author:
Alexey Stashok
  • Constructor Details

  • Method Details

    • getSocketChannel

      public SocketChannel getSocketChannel()
    • setSocketChannel

      public void setSocketChannel(SocketChannel socketChannel)
    • prepareForReading

      public void prepareForReading() throws IOException
      Throws:
      IOException
    • openInputStream

      public InputStream openInputStream()
    • openOutputStream

      public OutputStream openOutputStream() throws IOException
      Throws:
      IOException
    • flush

      public void flush() throws IOException
      Throws:
      IOException
    • isDirectMode

      public boolean isDirectMode()
    • setDirectMode

      public void setDirectMode(boolean isDirectMode)
    • getChannelId

      public int getChannelId()
      Get channel id
    • setChannelId

      public void setChannelId(int channelId)
      Set channel id
    • getMessageId

      public int getMessageId()
      Get request/response messageId of 1st frame
    • setMessageId

      public void setMessageId(int messageId)
      Set request/response messageId of 1st frame
    • getContentId

      public int getContentId()
      Get request/response contentId
    • setContentId

      public void setContentId(int contentId)
      Set request/response contentId
    • getContentProperties

      public Map<Integer,String> getContentProperties()
      Get request content properties
    • setContentProperty

      public void setContentProperty(int key, String value)
      Set response content properties
    • setInputStreamByteBuffer

      public void setInputStreamByteBuffer(ByteBuffer messageBuffer)
      Set messageBuffer for InputStream some message part could be preread before
    • close

      public void close() throws IOException
      Throws:
      IOException
    • create

      public static Connection create(String host, int port) throws IOException
      Throws:
      IOException
    • finalize

      protected void finalize() throws Throwable
      Overrides:
      finalize in class Object
      Throws:
      Throwable
    • getHost

      public String getHost()
    • getPort

      public int getPort()
    • getLocalHost

      public String getLocalHost()
    • getLocalPort

      public int getLocalPort()
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getHost

      public static String getHost(SocketChannel socketChannel)
    • getPort

      public static int getPort(SocketChannel socketChannel)
    • getLocalHost

      public static String getLocalHost(SocketChannel socketChannel)
    • getLocalPort

      public static int getLocalPort(SocketChannel socketChannel)