Class UnreliableInputStream

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable

    public class UnreliableInputStream
    extends java.io.InputStream
    • Constructor Detail

      • UnreliableInputStream

        public UnreliableInputStream​(UnreliableSocket socket)
                              throws java.net.SocketException
        Throws:
        java.net.SocketException
    • Method Detail

      • available

        public int available()
                      throws java.io.IOException
        Overrides:
        available in class java.io.InputStream
        Throws:
        java.io.IOException
      • close

        public void close()
                   throws java.io.IOException
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface java.io.Closeable
        Overrides:
        close in class java.io.InputStream
        Throws:
        java.io.IOException
      • read

        public int read()
                 throws java.io.IOException
        Specified by:
        read in class java.io.InputStream
        Throws:
        java.io.IOException
      • getLastContactAddress

        public java.net.InetAddress getLastContactAddress()
      • setLastContactAddress

        public void setLastContactAddress​(java.net.InetAddress address,
                                          int port)
      • getLastContactPort

        public int getLastContactPort()
      • setLastContactPort

        public void setLastContactPort​(int lastContactPort)