org.glassfish.jersey.server.wadl.internal
Class WadlApplicationContextImpl

java.lang.Object
  extended by org.glassfish.jersey.server.wadl.internal.WadlApplicationContextImpl
All Implemented Interfaces:
WadlApplicationContext

public class WadlApplicationContextImpl
extends Object
implements WadlApplicationContext

WADL application context implementation.

Author:
Paul Sandoz (paul.sandoz at oracle.com)

Field Summary
static JAXBElement extendedElement
           
 
Constructor Summary
WadlApplicationContextImpl(javax.ws.rs.core.Configuration configuration, org.glassfish.hk2.api.ServiceLocator serviceLocator)
           
 
Method Summary
 ApplicationDescription getApplication(javax.ws.rs.core.UriInfo uriInfo, boolean detailedWadl)
          Get a new instance of a ApplicationDescription corresponding to all the root resource classes, and configure the base URI.
 Application getApplication(javax.ws.rs.core.UriInfo info, Resource resource, boolean detailedWadl)
          Get a new instance of Application for a particular resource.
 JAXBContext getJAXBContext()
          Get the default JAXB context associated with the WadlGenerator for the Web application.
 boolean isWadlGenerationEnabled()
          Get WADL generation status.
 void setWadlGenerationEnabled(boolean wadlGenerationEnabled)
          Enable/disable WADL generation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

extendedElement

public static final JAXBElement extendedElement
Constructor Detail

WadlApplicationContextImpl

public WadlApplicationContextImpl(@Context
                                  javax.ws.rs.core.Configuration configuration,
                                  @Context
                                  org.glassfish.hk2.api.ServiceLocator serviceLocator)
Method Detail

getApplication

public ApplicationDescription getApplication(javax.ws.rs.core.UriInfo uriInfo,
                                             boolean detailedWadl)
Description copied from interface: WadlApplicationContext
Get a new instance of a ApplicationDescription corresponding to all the root resource classes, and configure the base URI.

Specified by:
getApplication in interface WadlApplicationContext
Parameters:
uriInfo - the URI information from which the base URI is set on the WADL application.
Returns:
the application description, the contents may be modified.

getApplication

public Application getApplication(javax.ws.rs.core.UriInfo info,
                                  Resource resource,
                                  boolean detailedWadl)
Description copied from interface: WadlApplicationContext
Get a new instance of Application for a particular resource.

Specified by:
getApplication in interface WadlApplicationContext
Parameters:
info - the URI information from which the base URI is set on the WADL application.
resource - the resource to build the Application for
Returns:
the application for this resource

getJAXBContext

public JAXBContext getJAXBContext()
Description copied from interface: WadlApplicationContext
Get the default JAXB context associated with the WadlGenerator for the Web application.

Specified by:
getJAXBContext in interface WadlApplicationContext
Returns:
the default JAXB context.

setWadlGenerationEnabled

public void setWadlGenerationEnabled(boolean wadlGenerationEnabled)
Description copied from interface: WadlApplicationContext
Enable/disable WADL generation.

Specified by:
setWadlGenerationEnabled in interface WadlApplicationContext
Parameters:
wadlGenerationEnabled - if wadlGenerationEnabled is true and ServerProperties.WADL_FEATURE_DISABLE is false, WADL generation is enabled. In all other cases is disabled.

isWadlGenerationEnabled

public boolean isWadlGenerationEnabled()
Description copied from interface: WadlApplicationContext
Get WADL generation status.

Specified by:
isWadlGenerationEnabled in interface WadlApplicationContext
Returns:
true when WADL generation is enabled. Does not take ServerProperties.WADL_FEATURE_DISABLE


Copyright © 2007-2014, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.