com.sun.jersey.wadl.resourcedoc
Class DocProcessorWrapper

java.lang.Object
  extended by com.sun.jersey.wadl.resourcedoc.DocProcessorWrapper
All Implemented Interfaces:
DocProcessor

public class DocProcessorWrapper
extends java.lang.Object
implements DocProcessor

This DocProcessor wraps multiple DocProcessors.
Created on: Jul 27, 2008

Version:
$Id: DocProcessorWrapper.java 1908 2009-02-03 00:20:29Z magrokosmos $
Author:
Martin Grotzke

Constructor Summary
DocProcessorWrapper()
           
 
Method Summary
 java.lang.String[] getCDataElements()
          specify which of your elements you want to be handled as CDATA.
 java.lang.Class<?>[] getRequiredJaxbContextClasses()
          Specify jaxb classes of instances that you add to the resourcedoc model.
 void processClassDoc(com.sun.javadoc.ClassDoc classDoc, ClassDocType classDocType)
          Use this method to extend the provided ClassDocType with the information from the given ClassDoc.
 void processMethodDoc(com.sun.javadoc.MethodDoc methodDoc, MethodDocType methodDocType)
          Process the provided methodDoc and add your custom information to the methodDocType.
Use e.g.
 void processParamTag(com.sun.javadoc.ParamTag paramTag, com.sun.javadoc.Parameter parameter, ParamDocType paramDocType)
          Use this method to extend the provided ParamDocType with the information from the given ParamTag and Parameter.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DocProcessorWrapper

public DocProcessorWrapper()
Method Detail

getRequiredJaxbContextClasses

public java.lang.Class<?>[] getRequiredJaxbContextClasses()
Description copied from interface: DocProcessor
Specify jaxb classes of instances that you add to the resourcedoc model. These classes are added to the list of classes when creating the jaxb context with JAXBContext.newInstance( clazzes );.

Specified by:
getRequiredJaxbContextClasses in interface DocProcessor
Returns:
a list of classes or null

getCDataElements

public java.lang.String[] getCDataElements()
Description copied from interface: DocProcessor
specify which of your elements you want to be handled as CDATA. The use of the '^' between the namespaceURI and the localname seems to be an implementation detail of the xerces code. When processing xml that doesn't use namespaces, simply omit the namespace prefix as shown in the third CDataElement below.

Specified by:
getCDataElements in interface DocProcessor
Returns:
an Array of element descriptors or null

processClassDoc

public void processClassDoc(com.sun.javadoc.ClassDoc classDoc,
                            ClassDocType classDocType)
Description copied from interface: DocProcessor
Use this method to extend the provided ClassDocType with the information from the given ClassDoc.

Specified by:
processClassDoc in interface DocProcessor
Parameters:
classDoc - the class javadoc
classDocType - the ClassDocType to extend. This will later be processed by the WadlGenerators.

processMethodDoc

public void processMethodDoc(com.sun.javadoc.MethodDoc methodDoc,
                             MethodDocType methodDocType)
Description copied from interface: DocProcessor
Process the provided methodDoc and add your custom information to the methodDocType.
Use e.g. MethodDocType.getAny() to store custom elements.

Specified by:
processMethodDoc in interface DocProcessor
Parameters:
methodDoc - the MethodDoc representing the docs of your method.
methodDocType - the related MethodDocType that will later be processed by the WadlGenerators.

processParamTag

public void processParamTag(com.sun.javadoc.ParamTag paramTag,
                            com.sun.javadoc.Parameter parameter,
                            ParamDocType paramDocType)
Description copied from interface: DocProcessor
Use this method to extend the provided ParamDocType with the information from the given ParamTag and Parameter.

Specified by:
processParamTag in interface DocProcessor
Parameters:
paramTag - the parameter javadoc
parameter - the parameter (that is documented or not)
paramDocType - the ParamDocType to extend. This will later be processed by the WadlGenerators.


Copyright © 2011 Sun Microsystems, Inc. All Rights Reserved.