com.noelios.restlet.ext.jetty
Class JettyCall

java.lang.Object
  extended by com.noelios.restlet.http.HttpCall
      extended by com.noelios.restlet.http.HttpServerCall
          extended by com.noelios.restlet.ext.jetty.JettyCall

public class JettyCall
extends HttpServerCall

Call that is used by the Jetty 6 HTTP server connector.

Author:
Jerome Louvel

Constructor Summary
JettyCall(Server server, org.mortbay.jetty.HttpConnection connection)
          Constructor.
 
Method Summary
 void complete()
           
 java.lang.String getClientAddress()
           
 int getClientPort()
           
 org.mortbay.jetty.HttpConnection getConnection()
          Returns the wrapped Jetty HTTP connection.
 java.lang.String getMethod()
          Returns the request method.
 java.nio.channels.ReadableByteChannel getRequestEntityChannel(long size)
           
 java.io.InputStream getRequestEntityStream(long size)
           
 java.nio.channels.ReadableByteChannel getRequestHeadChannel()
           
 Series<Parameter> getRequestHeaders()
          Returns the list of request headers.
 java.io.InputStream getRequestHeadStream()
           
 java.lang.String getRequestUri()
          Returns the URI on the request line (most like a relative reference, but not necessarily).
 java.nio.channels.WritableByteChannel getResponseEntityChannel()
          Returns the response channel if it exists.
 java.io.OutputStream getResponseEntityStream()
          Returns the response stream if it exists.
 java.lang.String getServerAddress()
          Returns the response address.
Corresponds to the IP address of the responding server.
 java.lang.String getSslCipherSuite()
           
 java.util.List<java.security.cert.Certificate> getSslClientCertificates()
           
 java.lang.Integer getSslKeySize()
           
 boolean isConfidential()
          Indicates if the request was made using a confidential mean.
 boolean isConnectionBroken(java.lang.Exception exception)
           
 void sendResponse(Response response)
           
 
Methods inherited from class com.noelios.restlet.http.HttpServerCall
formatContentDisposition, getContentLength, getHostDomain, getHostPort, getRequestEntity, isClientKeepAlive, isServerKeepAlive, readRequestHead, shouldResponseBeChunked, writeResponseBody, writeResponseHead, writeResponseHead
 
Methods inherited from class com.noelios.restlet.http.HttpCall
formatDate, getConnectorService, getContentLength, getLogger, getProtocol, getReasonPhrase, getResponseHeaders, getServerPort, getStatusCode, getVersion, isKeepAlive, isRequestChunked, isResponseChunked, parseDate, setClientAddress, setClientPort, setConfidential, setHostDomain, setHostPort, setMethod, setProtocol, setReasonPhrase, setRequestUri, setServerAddress, setServerPort, setStatusCode, setVersion
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JettyCall

public JettyCall(Server server,
                 org.mortbay.jetty.HttpConnection connection)
Constructor.

Parameters:
server - The parent server.
connection - The wrapped Jetty HTTP connection.
Method Detail

complete

public void complete()
Overrides:
complete in class HttpServerCall

getClientAddress

public java.lang.String getClientAddress()
Overrides:
getClientAddress in class HttpCall

getClientPort

public int getClientPort()
Overrides:
getClientPort in class HttpCall

getConnection

public org.mortbay.jetty.HttpConnection getConnection()
Returns the wrapped Jetty HTTP connection.

Returns:
The wrapped Jetty HTTP connection.

getMethod

public java.lang.String getMethod()
Returns the request method.

Overrides:
getMethod in class HttpCall
Returns:
The request method.

getRequestEntityChannel

public java.nio.channels.ReadableByteChannel getRequestEntityChannel(long size)
Specified by:
getRequestEntityChannel in class HttpServerCall

getRequestEntityStream

public java.io.InputStream getRequestEntityStream(long size)
Specified by:
getRequestEntityStream in class HttpServerCall

getRequestHeadChannel

public java.nio.channels.ReadableByteChannel getRequestHeadChannel()
Specified by:
getRequestHeadChannel in class HttpServerCall

getRequestHeaders

public Series<Parameter> getRequestHeaders()
Returns the list of request headers.

Overrides:
getRequestHeaders in class HttpCall
Returns:
The list of request headers.

getRequestHeadStream

public java.io.InputStream getRequestHeadStream()
Specified by:
getRequestHeadStream in class HttpServerCall

getRequestUri

public java.lang.String getRequestUri()
Returns the URI on the request line (most like a relative reference, but not necessarily).

Overrides:
getRequestUri in class HttpCall
Returns:
The URI on the request line.

getResponseEntityChannel

public java.nio.channels.WritableByteChannel getResponseEntityChannel()
Returns the response channel if it exists.

Specified by:
getResponseEntityChannel in class HttpServerCall
Returns:
The response channel if it exists.

getResponseEntityStream

public java.io.OutputStream getResponseEntityStream()
Returns the response stream if it exists.

Specified by:
getResponseEntityStream in class HttpServerCall
Returns:
The response stream if it exists.

getServerAddress

public java.lang.String getServerAddress()
Returns the response address.
Corresponds to the IP address of the responding server.

Overrides:
getServerAddress in class HttpCall
Returns:
The response address.

getSslCipherSuite

public java.lang.String getSslCipherSuite()
Overrides:
getSslCipherSuite in class HttpServerCall

getSslClientCertificates

public java.util.List<java.security.cert.Certificate> getSslClientCertificates()
Overrides:
getSslClientCertificates in class HttpServerCall

getSslKeySize

public java.lang.Integer getSslKeySize()
Overrides:
getSslKeySize in class HttpServerCall

isConfidential

public boolean isConfidential()
Indicates if the request was made using a confidential mean.

Overrides:
isConfidential in class HttpCall
Returns:
True if the request was made using a confidential mean.

isConnectionBroken

public boolean isConnectionBroken(java.lang.Exception exception)
Overrides:
isConnectionBroken in class HttpCall

sendResponse

public void sendResponse(Response response)
                  throws java.io.IOException
Overrides:
sendResponse in class HttpServerCall
Throws:
java.io.IOException


Copyright © 2005-2008 Noelios Technologies.