|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.caucho.vfs.QSocket
com.caucho.vfs.QSocketChannelWrapper
@Module public class QSocketChannelWrapper
Abstract socket to handle both normal sockets and bin/resin sockets.
| Constructor Summary | |
|---|---|
QSocketChannelWrapper()
|
|
QSocketChannelWrapper(java.nio.channels.SocketChannel s)
|
|
| Method Summary | |
|---|---|
void |
close()
Closes the underlying socket. |
int |
getCipherBits()
Returns the bits in the socket. |
java.lang.String |
getCipherSuite()
Returns the secure cipher algorithm. |
java.security.cert.X509Certificate |
getClientCertificate()
Returns the client certificate. |
java.security.cert.X509Certificate[] |
getClientCertificates()
Returns the client certificate. |
java.net.InetAddress |
getLocalAddress()
Returns the server inet address that accepted the request. |
int |
getLocalPort()
Returns the server port that accepted the request. |
java.net.InetAddress |
getRemoteAddress()
Returns the remote client's inet address. |
int |
getRemotePort()
Returns the remote client's port. |
java.nio.channels.SelectableChannel |
getSelectableChannel()
Returns the selectable channel. |
java.net.Socket |
getSocket()
|
StreamImpl |
getStream()
Returns the socket's input stream. |
long |
getTotalReadBytes()
Returns the total number of bytes read from the socket connection. |
long |
getTotalWriteBytes()
Returns the total number of bytes written to the socket connection. |
void |
init(java.nio.channels.SocketChannel channel)
|
boolean |
isClosed()
Returns true for closes. |
boolean |
isSecure()
Returns true if the connection is secure. |
void |
resetTotalBytes()
|
void |
setReadTimeout(int ms)
Sets the socket timeout. |
java.lang.String |
toString()
|
| Methods inherited from class com.caucho.vfs.QSocket |
|---|
forceShutdown, getLocalHost, getRemoteAddress, getRemoteHost, getRemoteIP, isEof, setRequestExpireTime |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public QSocketChannelWrapper()
public QSocketChannelWrapper(java.nio.channels.SocketChannel s)
| Method Detail |
|---|
public void init(java.nio.channels.SocketChannel channel)
public java.net.Socket getSocket()
public void setReadTimeout(int ms)
throws java.io.IOException
java.io.IOExceptionpublic java.net.InetAddress getLocalAddress()
getLocalAddress in class QSocketpublic int getLocalPort()
getLocalPort in class QSocketpublic java.net.InetAddress getRemoteAddress()
getRemoteAddress in class QSocketpublic int getRemotePort()
getRemotePort in class QSocketpublic boolean isSecure()
isSecure in class QSocketpublic java.lang.String getCipherSuite()
getCipherSuite in class QSocketpublic int getCipherBits()
getCipherBits in class QSocket
public java.security.cert.X509Certificate getClientCertificate()
throws java.security.cert.CertificateException
getClientCertificate in class QSocketjava.security.cert.CertificateException
public java.security.cert.X509Certificate[] getClientCertificates()
throws java.security.cert.CertificateException
getClientCertificates in class QSocketjava.security.cert.CertificateExceptionpublic java.nio.channels.SelectableChannel getSelectableChannel()
getSelectableChannel in class QSocket
public StreamImpl getStream()
throws java.io.IOException
getStream in class QSocketjava.io.IOExceptionpublic void resetTotalBytes()
public long getTotalReadBytes()
QSocket
getTotalReadBytes in class QSocketpublic long getTotalWriteBytes()
QSocket
getTotalWriteBytes in class QSocketpublic boolean isClosed()
isClosed in class QSocket
public void close()
throws java.io.IOException
close in class QSocketjava.io.IOExceptionpublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||