com.sun.jersey.server.wadl
Class WadlBuilder

java.lang.Object
  extended by com.sun.jersey.server.wadl.WadlBuilder

public class WadlBuilder
extends java.lang.Object

This class implements the algorithm how the WADL is built for one or more AbstractResource classes. WADL artifacts are created by a WadlGenerator.

Author:
Marc Hadley, Martin Grotzke (martin.grotzke at freiheit.com)

Constructor Summary
WadlBuilder()
          Create default WADL builder.
WadlBuilder(WadlGenerator wadlGenerator)
          Create WADL builder that utilizes given WADL generator.
 
Method Summary
 com.sun.research.ws.wadl.Application generate(Providers providers, FeaturesAndProperties fap, UriInfo info, ApplicationDescription description, AbstractResource resource)
          Generate WADL for a resource.
 com.sun.research.ws.wadl.Application generate(Providers providers, FeaturesAndProperties fap, UriInfo info, ApplicationDescription description, AbstractResource resource, java.lang.String path)
          Generate WADL for a virtual subresource resulting from sub resource methods.
 ApplicationDescription generate(Providers providers, FeaturesAndProperties fap, UriInfo info, java.util.Set<AbstractResource> resources)
          Generate WADL for a set of resources.
 ApplicationDescription generate(UriInfo info, java.util.Set<AbstractResource> resources)
          Generate WADL for a set of resources.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WadlBuilder

public WadlBuilder()
Create default WADL builder.


WadlBuilder

public WadlBuilder(WadlGenerator wadlGenerator)
Create WADL builder that utilizes given WADL generator. The generator is expected to by initialized.

Parameters:
wadlGenerator - initialized WADL generator.
Method Detail

generate

public ApplicationDescription generate(UriInfo info,
                                       java.util.Set<AbstractResource> resources)
Generate WADL for a set of resources.

Parameters:
resources - the set of resources
info - a UriInfo to provide context for the request
Returns:
the JAXB WADL application bean

generate

public ApplicationDescription generate(Providers providers,
                                       FeaturesAndProperties fap,
                                       UriInfo info,
                                       java.util.Set<AbstractResource> resources)
Generate WADL for a set of resources.

Parameters:
resources - the set of resources
info - a UriInfo to provide context for the request
providers - an instance of Providers required for some WADL generators
fap - an instance of FeaturesAndProperties required from some WADL generators
Returns:
the JAXB WADL application bean

generate

public com.sun.research.ws.wadl.Application generate(Providers providers,
                                                     FeaturesAndProperties fap,
                                                     UriInfo info,
                                                     ApplicationDescription description,
                                                     AbstractResource resource)
Generate WADL for a resource.

Parameters:
resource - the resource
description - the overall application description so we can
info - a UriInfo to provide context for the request
providers - an instance of Providers required for some WADL generators
fap - an instance of FeaturesAndProperties required from some WADL generators
Returns:
the JAXB WADL application bean

generate

public com.sun.research.ws.wadl.Application generate(Providers providers,
                                                     FeaturesAndProperties fap,
                                                     UriInfo info,
                                                     ApplicationDescription description,
                                                     AbstractResource resource,
                                                     java.lang.String path)
Generate WADL for a virtual subresource resulting from sub resource methods.

Parameters:
description - the overall application description so we can
resource - the parent resource
path - the value of the methods path annotations
Returns:
the JAXB WADL application bean


Copyright © 2014 Oracle Corporation. All Rights Reserved.