Class WebUtil

java.lang.Object
com.sun.ts.tests.common.web.WebUtil

public class WebUtil extends Object
Factorize code used by JSP and Servlets.
See Also:
  • Field Details

    • RESULT_PROP

      public static final String RESULT_PROP
      Name of property used to send back test result to client
      See Also:
    • TEST_NAME_PROP

      public static final String TEST_NAME_PROP
      Name of the property used to get the test method name
      See Also:
  • Constructor Details

    • WebUtil

      public WebUtil()
  • Method Details

    • logMsg

      public static void logMsg(String msg)
    • logTrace

      public static void logTrace(String msg)
    • logErr

      public static void logErr(String msg)
    • logErr

      public static void logErr(String msg, Exception e)
    • executeTest

      public static Properties executeTest(Object testDriver, jakarta.servlet.http.HttpServletRequest req) throws jakarta.servlet.ServletException
      Use information provided in a HTTPRequest to execute a test method on a testDriver object. The test method is "discovered" at runtime using the reflection API. The testDriver could be any java object.
      Throws:
      jakarta.servlet.ServletException
    • propsToString

      public static String propsToString(Properties props)
      Convert Java Properties to a String, as expected by on the client side (WebServer)