Save This Page
Home » openjdk-7 » java » net » [javadoc | source]
java.net
abstract class: AbstractPlainSocketImpl [javadoc | source]
java.lang.Object
   java.net.SocketImpl
      java.net.AbstractPlainSocketImpl

All Implemented Interfaces:
    SocketOptions

Direct Known Subclasses:
    SocksSocketImpl, SdpSocketImpl, DualStackPlainSocketImpl, TwoStacksPlainSocketImpl, ZSocketImpl, PlainSocketImpl

Default Socket Implementation. This implementation does not implement any security checks. Note this class should NOT be public.
Field Summary
 int timeout     
protected  int fdUseCount     
protected final  Object fdLock     
protected  boolean closePending     
public static final  int SHUT_RD     
public static final  int SHUT_WR     
Fields inherited from java.net.SocketImpl:
socket,  serverSocket,  fd,  address,  port,  localport
Method from java.net.AbstractPlainSocketImpl Summary:
accept,   acquireFD,   available,   bind,   close,   connect,   connect,   connect,   create,   doConnect,   finalize,   getInputStream,   getOption,   getOutputStream,   getTimeout,   isClosedOrPending,   isConnectionReset,   isConnectionResetPending,   listen,   releaseFD,   reset,   sendUrgentData,   setAddress,   setConnectionReset,   setConnectionResetPending,   setFileDescriptor,   setInputStream,   setLocalPort,   setOption,   setPort,   shutdownInput,   shutdownOutput,   socketAccept,   socketAvailable,   socketBind,   socketClose,   socketClose0,   socketConnect,   socketCreate,   socketGetOption,   socketListen,   socketSendUrgentData,   socketSetOption,   socketShutdown,   supportsUrgentData
Methods from java.net.SocketImpl:
accept,   available,   bind,   close,   connect,   connect,   connect,   create,   getFileDescriptor,   getInetAddress,   getInputStream,   getLocalPort,   getOutputStream,   getPort,   getServerSocket,   getSocket,   listen,   reset,   sendUrgentData,   setPerformancePreferences,   setServerSocket,   setSocket,   shutdownInput,   shutdownOutput,   supportsUrgentData,   toString
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from java.net.AbstractPlainSocketImpl Detail:
 protected  void accept(SocketImpl s) throws IOException 
    Accepts connections.
 FileDescriptor acquireFD() 
 protected synchronized int available() throws IOException 
    Returns the number of bytes that can be read without blocking.
 protected synchronized  void bind(InetAddress address,
    int lport) throws IOException 
    Binds the socket to the specified address of the specified local port.
 protected  void close() throws IOException 
    Closes the socket.
 protected  void connect(String host,
    int port) throws UnknownHostException, IOException 
    Creates a socket and connects it to the specified port on the specified host.
 protected  void connect(InetAddress address,
    int port) throws IOException 
    Creates a socket and connects it to the specified address on the specified port.
 protected  void connect(SocketAddress address,
    int timeout) throws IOException 
    Creates a socket and connects it to the specified address on the specified port.
 protected synchronized  void create(boolean stream) throws IOException 
    Creates a socket with a boolean that specifies whether this is a stream socket (true) or an unconnected UDP socket (false).
 synchronized  void doConnect(InetAddress address,
    int port,
    int timeout) throws IOException 
    The workhorse of the connection operation. Tries several times to establish a connection to the given . If unsuccessful, throws an IOException indicating what went wrong.
 protected  void finalize() throws IOException 
    Cleans up if the user forgets to close it.
 protected synchronized InputStream getInputStream() throws IOException 
    Gets an InputStream for this socket.
 public Object getOption(int opt) throws SocketException 
 protected synchronized OutputStream getOutputStream() throws IOException 
    Gets an OutputStream for this socket.
 public int getTimeout() 
 public boolean isClosedOrPending() 
 public boolean isConnectionReset() 
 public boolean isConnectionResetPending() 
 protected synchronized  void listen(int count) throws IOException 
    Listens, for a specified amount of time, for connections.
  void releaseFD() 
  void reset() throws IOException 
 protected  void sendUrgentData(int data) throws IOException 
  void setAddress(InetAddress address) 
 public  void setConnectionReset() 
 public  void setConnectionResetPending() 
  void setFileDescriptor(FileDescriptor fd) 
  void setInputStream(SocketInputStream in) 
  void setLocalPort(int localport) 
 public  void setOption(int opt,
    Object val) throws SocketException 
  void setPort(int port) 
 protected  void shutdownInput() throws IOException 
    Shutdown read-half of the socket connection;
 protected  void shutdownOutput() throws IOException 
    Shutdown write-half of the socket connection;
 abstract  void socketAccept(SocketImpl s) throws IOException
 abstract int socketAvailable() throws IOException
 abstract  void socketBind(InetAddress address,
    int port) throws IOException
 protected  void socketClose() throws IOException 
 abstract  void socketClose0(boolean useDeferredClose) throws IOException
 abstract  void socketConnect(InetAddress address,
    int port,
    int timeout) throws IOException
 abstract  void socketCreate(boolean isServer) throws IOException
 abstract int socketGetOption(int opt,
    Object iaContainerObj) throws SocketException
 abstract  void socketListen(int count) throws IOException
 abstract  void socketSendUrgentData(int data) throws IOException
 abstract  void socketSetOption(int cmd,
    boolean on,
    Object value) throws SocketException
 abstract  void socketShutdown(int howto) throws IOException
 protected boolean supportsUrgentData()