|
Openfire 3.7.1 Javadoc | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jivesoftware.openfire.http.HttpConnection
public class HttpConnection
Represents one HTTP connection with a client using the HTTP Binding service. The client will wait
on getResponse()
until the server forwards a message to it or the wait time on the
session timesout.
Constructor Summary | |
---|---|
HttpConnection(long requestId,
boolean isSecure,
X509Certificate[] sslCertificates)
Constructs an HTTP Connection. |
Method Summary | |
---|---|
void |
close()
The connection should be closed without delivering a stanza to the requestor. |
void |
deliverBody(String body)
Delivers content to the client. |
X509Certificate[] |
getPeerCertificates()
Returns the peer certificates for this connection. |
long |
getRequestId()
Returns the ID which uniquely identifies this connection. |
String |
getResponse()
A call that will suspend the request if there is no deliverable currently available. |
HttpSession |
getSession()
Returns the session that this connection belongs to. |
boolean |
isClosed()
Returns true if this connection has been closed, either a response was delivered to the client or the server closed the connection abrubtly. |
boolean |
isDelivered()
|
boolean |
isSecure()
Returns true if this connection is using HTTPS. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public HttpConnection(long requestId, boolean isSecure, X509Certificate[] sslCertificates)
requestId
- the ID which uniquely identifies this request.isSecure
- true if this connection is using HTTPSsslCertificates
- list of certificates presented by the client.Method Detail |
---|
public void close()
public boolean isClosed()
public boolean isSecure()
public boolean isDelivered()
public void deliverBody(String body) throws HttpConnectionClosedException
body
- the XMPP content to be forwarded to the client inside of a body tag.
HttpConnectionClosedException
- when this connection to the client has already recieved
a deliverable to forward to the clientpublic String getResponse() throws org.jivesoftware.openfire.http.HttpBindTimeoutException
HttpBindTimeoutException
- to indicate that the maximum wait time requested by the
client has been surpassed and an empty response should be returned.public long getRequestId()
public HttpSession getSession()
public X509Certificate[] getPeerCertificates()
|
Openfire 3.7.1 Javadoc | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |