public class JniServerSocketImpl extends QServerSocket
| Modifier and Type | Method and Description |
|---|---|
boolean |
accept(QSocket socket)
Accepts a new connection from the socket.
|
void |
close()
Closes the socket.
|
static QServerSocket |
create(java.lang.String host,
int port) |
QSocket |
createSocket()
Factory method creating an instance socket.
|
void |
finalize() |
long |
getFd()
Returns the file descriptor to OpenSSLFactory.
|
static java.lang.String |
getInitMessage() |
java.net.InetAddress |
getLocalAddress() |
int |
getLocalPort() |
int |
getSystemFD() |
boolean |
isClosed() |
static boolean |
isEnabled() |
boolean |
isJni()
Returns true if this is a JNI socket, to distinguish between
file-descriptors we have extra control over.
|
boolean |
isJniValid() |
boolean |
isSendfileEnabled() |
static boolean |
isSendfileEnabledStatic() |
boolean |
isTcpCork()
Sets the connection tcp-keepalive delay.
|
static boolean |
isTcpCorkEnabled() |
boolean |
isTcpKeepalive()
Sets the connection tcp-keepalive delay.
|
boolean |
isTcpNoDelay()
Sets the connection tcp-no-delay.
|
void |
listen(int backlog)
Sets the socket's listen backlog.
|
static QServerSocket |
open(int fd,
int port) |
void |
setConnectionSocketTimeout(int ms)
Sets the connection read timeout.
|
boolean |
setSaveOnExec() |
void |
setSSL(boolean isSSL) |
void |
setTcpCork(boolean isEnable)
Sets the connection tcp-keepalive delay.
|
void |
setTcpKeepalive(boolean isEnable)
Sets the connection tcp-keepalive delay.
|
void |
setTcpNoDelay(boolean isEnable)
Sets the connection tcp-no-delay.
|
java.lang.String |
toString() |
getSelectorpublic static boolean isEnabled()
public static java.lang.String getInitMessage()
public static boolean isSendfileEnabledStatic()
public void setSSL(boolean isSSL)
public boolean isSendfileEnabled()
public static boolean isTcpCorkEnabled()
public long getFd()
public boolean isJni()
isJni in class QServerSocketpublic boolean isJniValid()
public boolean setSaveOnExec()
setSaveOnExec in class QServerSocketpublic int getSystemFD()
getSystemFD in class QServerSocketpublic void listen(int backlog)
listen in class QServerSocketpublic static QServerSocket create(java.lang.String host, int port) throws java.io.IOException
java.io.IOExceptionpublic static QServerSocket open(int fd, int port) throws java.io.IOException
java.io.IOExceptionpublic void setConnectionSocketTimeout(int ms)
setConnectionSocketTimeout in class QServerSocketpublic void setTcpNoDelay(boolean isEnable)
setTcpNoDelay in class QServerSocketpublic boolean isTcpNoDelay()
isTcpNoDelay in class QServerSocketpublic void setTcpKeepalive(boolean isEnable)
setTcpKeepalive in class QServerSocketpublic boolean isTcpKeepalive()
isTcpKeepalive in class QServerSocketpublic void setTcpCork(boolean isEnable)
setTcpCork in class QServerSocketpublic boolean isTcpCork()
isTcpCork in class QServerSocketpublic boolean accept(QSocket socket) throws java.io.IOException
accept in class QServerSocketsocket - the socket connection structurejava.io.IOExceptionpublic QSocket createSocket() throws java.io.IOException
createSocket in class QServerSocketjava.io.IOExceptionpublic java.net.InetAddress getLocalAddress()
getLocalAddress in class QServerSocketpublic int getLocalPort()
getLocalPort in class QServerSocketpublic boolean isClosed()
isClosed in class QServerSocketpublic void close()
throws java.io.IOException
close in class QServerSocketjava.io.IOExceptionpublic java.lang.String toString()
toString in class QServerSocketpublic void finalize()
throws java.lang.Throwable
finalize in class java.lang.Objectjava.lang.Throwable