JAC project
AOPSYS
CEDRIC & LIP6 labs

org.objectweb.jac.aspects.gui.web
Interface JacRequest

All Known Implementing Classes:
AbstractJacRequest, MultiMapJacRequest, MultiPartJacRequest

public interface JacRequest

This interface represents an HttpRequest.


Method Summary
 String getHeader(String name)
          Gets the value of a header.
 Object getParameter(String name)
          Returns a parameter.
 Object[] getParameters(String name)
          Returns a parameter.
 String getUserAgent()
          Returns the user agent of this request
 boolean isIEUserAgent()
          Tells if the user agent of the request is Internet Explorer
 void setResponse()
          Unblock a thread that was blocked by a waitForResult call.
 boolean waitForResponse()
          Makes the current requesting thread block and wait until the response is available.
 

Method Detail

getParameter

public Object getParameter(String name)
Returns a parameter. The result can be a String or a FileParameter object.

Parameters:
name - the name of the parameter
Returns:
the value of the parameter (a String a or FileParameter) if the parameter exists in the request, null otherwise.

getParameters

public Object[] getParameters(String name)
Returns a parameter. The result can be a String or a FileParameter object.

Parameters:
name - the name of the parameter
Returns:
the value of the parameter (a String a or FileParameter) if the parameter exists in the request, null otherwise.

isIEUserAgent

public boolean isIEUserAgent()
Tells if the user agent of the request is Internet Explorer

Returns:
true if the user agent is Internet Explorer, false otherwise

getUserAgent

public String getUserAgent()
Returns the user agent of this request

Returns:
the user agent of this request

getHeader

public String getHeader(String name)
Gets the value of a header.

Parameters:
name - name of the header
Returns:
the value of the header

waitForResponse

public boolean waitForResponse()
Makes the current requesting thread block and wait until the response is available.

The thread that call this method waits until a call to setResponse occurs or a timeout occurs.

Returns:
false if a timeout occured, true otherwise.
See Also:
setResponse()

setResponse

public void setResponse()
Unblock a thread that was blocked by a waitForResult call.

See Also:
waitForResponse()

Contact JAC development team:
Renaud Pawlak
Lionel Seinturier
Laurent Martelli