j2eeunit.client
Class AbstractHttpClient

java.lang.Object
  |
  +--j2eeunit.client.AbstractHttpClient
Direct Known Subclasses:
JspHttpClient, ServletHttpClient

public abstract class AbstractHttpClient
extends java.lang.Object

Abstract class that all HTTP clients to the server redirector must extend. It provides a common abstraction of the doTest method and provides the URL to the server redirector servlet or JSP.

Version:
0.9

Constructor Summary
AbstractHttpClient()
           
 
Method Summary
abstract  java.net.HttpURLConnection doTest(ServletTestRequest theRequest)
          Calls the test method indirectly by calling the Redirector servlet and then open a second HTTP connection to retrieve the test results.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractHttpClient

public AbstractHttpClient()
Method Detail

doTest

public abstract java.net.HttpURLConnection doTest(ServletTestRequest theRequest)
                                           throws java.lang.Throwable
Calls the test method indirectly by calling the Redirector servlet and then open a second HTTP connection to retrieve the test results.
Parameters:
theRequest - the request containing all data to pass to the redirector servlet.
Returns:
the HttpURLConnection that contains the HTTP response when the test was called.
Throws:
java.lang.Throwable - if an error occured in the test method or in the redirector servlet.


Copyright © 2000-2001 Vincent Massol.