public class WebAppDescriptor extends AppDescriptor
An instance of this class is created by creating an instance of
WebAppDescriptor.Builder
, invoking methods to add/modify state, and finally invoking
the WebAppDescriptor.Builder.build()
method.
This application descriptor is compatible with web-based test containers that support Servlets. The following Web-based test container factories are provided:
GrizzlyWebTestContainerFactory
for testing with the Grizzly
Web container and Servlet support.EmbeddedGlassFishTestContainerFactory
for testing with
embedded GlassFish.ExternalTestContainerFactory
for testing when the Web
application is independently deployed in a separate JVM to that of the
tests. For example, the application may be deployed to the
Glassfish v2 or v3 application server.Modifier and Type | Class and Description |
---|---|
static class |
WebAppDescriptor.Builder
The builder for building a Web-based application descriptor.
|
static class |
WebAppDescriptor.FilterDescriptor |
AppDescriptor.AppDescriptorBuilder<T extends AppDescriptor.AppDescriptorBuilder,V extends AppDescriptor>
Modifier and Type | Method and Description |
---|---|
Map<String,String> |
getContextParams()
Get the context parameters.
|
String |
getContextPath()
Get the context path.
|
List<WebAppDescriptor.FilterDescriptor> |
getFilters()
Get the filter class.
|
Map<String,String> |
getInitParams()
Get the initialization parameters.
|
List<Class<? extends EventListener>> |
getListeners()
Get all the registered Listener classes
|
Class<? extends javax.servlet.http.HttpServlet> |
getServletClass()
Get the servlet class.
|
String |
getServletPath()
Get the servlet path.
|
getClientConfig
public Map<String,String> getInitParams()
public Map<String,String> getContextParams()
public Class<? extends javax.servlet.http.HttpServlet> getServletClass()
public List<WebAppDescriptor.FilterDescriptor> getFilters()
public String getContextPath()
public String getServletPath()
public List<Class<? extends EventListener>> getListeners()
null
if none is registered.Copyright © 2013 Oracle Corporation. All rights reserved.