Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.i2p.util
Class InternalSocket

    java.lang.Object
      java.net.Socket
          net.i2p.util.InternalSocket

    public class InternalSocket

extends Socket

A simple in-JVM Socket using Piped Streams. We use port numbers just like regular sockets. Can only connect to InternalServerSocket.

Since:
  0.7.9

Constructor Summary
`InternalSocket(InputStream is, OutputStream os)` server side
`InternalSocket(int port)` client side

Method Summary
`void` | `bind(SocketAddress endpoint)` Deprecated. unsupported
`void` | `close()`
`void` | `connect(SocketAddress endpoint)` Deprecated. unsupported
`void` | `connect(SocketAddress endpoint, int timeout)` Deprecated. unsupported
`SocketChannel` | `getChannel()` Deprecated. unsupported
`InetAddress` | `getInetAddress()` Deprecated. unsupported
`InputStream` | `getInputStream()`
`boolean` | `getKeepAlive()` Deprecated. unsupported
`InetAddress` | `getLocalAddress()` Deprecated. unsupported
`int` | `getLocalPort()` Deprecated. unsupported
`SocketAddress` | `getLocalSocketAddress()` Deprecated. unsupported
`boolean` | `getOOBInline()` Deprecated. unsupported
`OutputStream` | `getOutputStream()`
`int` | `getPort()` Deprecated. unsupported
`int` | `getReceiveBufferSize()` Deprecated. unsupported
`SocketAddress` | `getRemoteSocketAddress()` Deprecated. unsupported
`boolean` | `getReuseAddress()` Deprecated. unsupported
`int` | `getSendBufferSize()` Deprecated. unsupported
`static Socket` | `getSocket(String host, int port)` Convenience method to return either a Socket or an InternalSocket
`int` | `getSoLinger()` Deprecated. unsupported
`int` | `getSoTimeout()`
`boolean` | `getTcpNoDelay()` Deprecated. unsupported
`int` | `getTrafficClass()` Deprecated. unsupported
`boolean` | `isBound()` Deprecated. unsupported
`boolean` | `isClosed()`
`boolean` | `isConnected()` Deprecated. unsupported
`boolean` | `isInputShutdown()` Deprecated. unsupported
`boolean` | `isOutputShutdown()` Deprecated. unsupported
`void` | `sendUrgentData(int data)` Deprecated. unsupported
`(package private) void` | `setInputStream(InputStream is)`
`void` | `setKeepAlive(boolean on)` Deprecated. unsupported
`void` | `setOOBInline(boolean on)` Deprecated. unsupported
`(package private) void` | `setOutputStream(OutputStream os)`
`void` | `setReceiveBufferSize(int size)` Deprecated. unsupported
`void` | `setReuseAddress(boolean on)` Deprecated. unsupported
`void` | `setSendBufferSize(int size)` Deprecated. unsupported
`void` | `setSoLinger(boolean on, int linger)` Deprecated. unsupported
`void` | `setSoTimeout(int timeout)` warning - unsupported
`void` | `setTcpNoDelay(boolean on)` Deprecated. unsupported
`void` | `setTrafficClass(int cize)` Deprecated. unsupported
`void` | `shutdownInput()` Deprecated. unsupported
`void` | `shutdownOutput()` Deprecated. unsupported
`String` | `toString()`

Methods inherited from class java.net.Socket
`setPerformancePreferences, setSocketImplFactory`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### InternalSocket

    InternalSocket(InputStream is,
                   OutputStream os)

  server side

### InternalSocket

    public InternalSocket(int port)
                   throws IOException

  client side

  Throws:
    `IOException`

Method Detail

### getSocket

    public static Socket getSocket(String host,
                                   int port)
                            throws IOException

  Convenience method to return either a Socket or an InternalSocket

  Throws:
    `IOException`

### getInputStream

    public InputStream getInputStream()

  Overrides:
    `getInputStream` in class `Socket`

### getOutputStream

    public OutputStream getOutputStream()

  Overrides:
    `getOutputStream` in class `Socket`

### setInputStream

    void setInputStream(InputStream is)

### setOutputStream

    void setOutputStream(OutputStream os)

### close

    public void close()

  Overrides:
    `close` in class `Socket`

### isClosed

    public boolean isClosed()

  Overrides:
    `isClosed` in class `Socket`

### toString

    public String toString()

  Overrides:
    `toString` in class `Socket`

### setSoTimeout

    public void setSoTimeout(int timeout)

  warning - unsupported

  Overrides:
    `setSoTimeout` in class `Socket`

### getSoTimeout

    public int getSoTimeout()

  Overrides:
    `getSoTimeout` in class `Socket`

### bind

    public void bind(SocketAddress endpoint)

  Deprecated. unsupported

  Overrides:
    `bind` in class `Socket`

### connect

    public void connect(SocketAddress endpoint)

  Deprecated. unsupported

  Overrides:
    `connect` in class `Socket`

### connect

    public void connect(SocketAddress endpoint,
                        int timeout)

  Deprecated. unsupported

  Overrides:
    `connect` in class `Socket`

### getChannel

    public SocketChannel getChannel()

  Deprecated. unsupported

  Overrides:
    `getChannel` in class `Socket`

### getInetAddress

    public InetAddress getInetAddress()

  Deprecated. unsupported

  Overrides:
    `getInetAddress` in class `Socket`

### getKeepAlive

    public boolean getKeepAlive()

  Deprecated. unsupported

  Overrides:
    `getKeepAlive` in class `Socket`

### getLocalAddress

    public InetAddress getLocalAddress()

  Deprecated. unsupported

  Overrides:
    `getLocalAddress` in class `Socket`

### getLocalPort

    public int getLocalPort()

  Deprecated. unsupported

  Overrides:
    `getLocalPort` in class `Socket`

### getLocalSocketAddress

    public SocketAddress getLocalSocketAddress()

  Deprecated. unsupported

  Overrides:
    `getLocalSocketAddress` in class `Socket`

### getOOBInline

    public boolean getOOBInline()

  Deprecated. unsupported

  Overrides:
    `getOOBInline` in class `Socket`

### getPort

    public int getPort()

  Deprecated. unsupported

  Overrides:
    `getPort` in class `Socket`

### getReceiveBufferSize

    public int getReceiveBufferSize()

  Deprecated. unsupported

  Overrides:
    `getReceiveBufferSize` in class `Socket`

### getRemoteSocketAddress

    public SocketAddress getRemoteSocketAddress()

  Deprecated. unsupported

  Overrides:
    `getRemoteSocketAddress` in class `Socket`

### getReuseAddress

    public boolean getReuseAddress()

  Deprecated. unsupported

  Overrides:
    `getReuseAddress` in class `Socket`

### getSendBufferSize

    public int getSendBufferSize()

  Deprecated. unsupported

  Overrides:
    `getSendBufferSize` in class `Socket`

### getSoLinger

    public int getSoLinger()

  Deprecated. unsupported

  Overrides:
    `getSoLinger` in class `Socket`

### getTcpNoDelay

    public boolean getTcpNoDelay()

  Deprecated. unsupported

  Overrides:
    `getTcpNoDelay` in class `Socket`

### getTrafficClass

    public int getTrafficClass()

  Deprecated. unsupported

  Overrides:
    `getTrafficClass` in class `Socket`

### isBound

    public boolean isBound()

  Deprecated. unsupported

  Overrides:
    `isBound` in class `Socket`

### isConnected

    public boolean isConnected()

  Deprecated. unsupported

  Overrides:
    `isConnected` in class `Socket`

### isInputShutdown

    public boolean isInputShutdown()

  Deprecated. unsupported

  Overrides:
    `isInputShutdown` in class `Socket`

### isOutputShutdown

    public boolean isOutputShutdown()

  Deprecated. unsupported

  Overrides:
    `isOutputShutdown` in class `Socket`

### sendUrgentData

    public void sendUrgentData(int data)

  Deprecated. unsupported

  Overrides:
    `sendUrgentData` in class `Socket`

### setKeepAlive

    public void setKeepAlive(boolean on)

  Deprecated. unsupported

  Overrides:
    `setKeepAlive` in class `Socket`

### setOOBInline

    public void setOOBInline(boolean on)

  Deprecated. unsupported

  Overrides:
    `setOOBInline` in class `Socket`

### setReceiveBufferSize

    public void setReceiveBufferSize(int size)

  Deprecated. unsupported

  Overrides:
    `setReceiveBufferSize` in class `Socket`

### setReuseAddress

    public void setReuseAddress(boolean on)

  Deprecated. unsupported

  Overrides:
    `setReuseAddress` in class `Socket`

### setSendBufferSize

    public void setSendBufferSize(int size)

  Deprecated. unsupported

  Overrides:
    `setSendBufferSize` in class `Socket`

### setSoLinger

    public void setSoLinger(boolean on,
                            int linger)

  Deprecated. unsupported

  Overrides:
    `setSoLinger` in class `Socket`

### setTcpNoDelay

    public void setTcpNoDelay(boolean on)

  Deprecated. unsupported

  Overrides:
    `setTcpNoDelay` in class `Socket`

### setTrafficClass

    public void setTrafficClass(int cize)

  Deprecated. unsupported

  Overrides:
    `setTrafficClass` in class `Socket`

### shutdownInput

    public void shutdownInput()

  Deprecated. unsupported

  Overrides:
    `shutdownInput` in class `Socket`

### shutdownOutput

    public void shutdownOutput()

  Deprecated. unsupported

  Overrides:
    `shutdownOutput` in class `Socket`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD