Package org.meeuw.jaxbdocumentation
Class DocumentationAdder
- java.lang.Object
-
- org.meeuw.jaxbdocumentation.DocumentationAdder
-
- All Implemented Interfaces:
Supplier<Transformer>
public class DocumentationAdder extends Object implements Supplier<Transformer>
Supplies aTransformerthat adds xs:documentation tags to an existing XSD. The contents of the documentation tags is determined by introspecting while looking forXmlDocumentationtags. The transformer is an actual XSLT `add-documentation.xslt`, which combines the information collected via introspection with the original XSD XML.- Since:
- 0.1
- Author:
- Michiel Meeuwissen
-
-
Constructor Summary
Constructors Constructor Description DocumentationAdder(Class<?>... classes)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Map<String,String>createDocumentations(Class<?>... classes)Transformerget()Class<?>[]getClasses()voidtransform(Source source, Result out)Stringwrite()voidwrite(Writer writer)
-
-
-
Constructor Detail
-
DocumentationAdder
public DocumentationAdder(Class<?>... classes)
-
-
Method Detail
-
transform
public void transform(Source source, Result out) throws TransformerException
- Throws:
TransformerException
-
get
public Transformer get()
- Specified by:
getin interfaceSupplier<Transformer>
-
getClasses
public Class<?>[] getClasses()
-
write
public void write(Writer writer) throws jakarta.xml.bind.JAXBException, IOException, TransformerException
- Throws:
jakarta.xml.bind.JAXBExceptionIOExceptionTransformerException
-
write
public String write() throws jakarta.xml.bind.JAXBException, IOException, TransformerException
- Throws:
jakarta.xml.bind.JAXBExceptionIOExceptionTransformerException
-
-