Class PluginDescriptorStaxWriter
java.lang.Object
org.apache.maven.plugin.descriptor.io.PluginDescriptorStaxWriter
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static interface(package private) static class -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidsetFileComment(String fileComment) Method setFileComment.voidsetNamespace(String namespace) Method setNamespace.voidsetSchemaLocation(String schemaLocation) Method setSchemaLocation.voidwrite(OutputStream stream, PluginDescriptor pluginDescriptor) Method write.voidwrite(Writer writer, PluginDescriptor pluginDescriptor) Method write.private voidwriteAttr(String attrName, String value, XMLStreamWriter serializer) private voidwriteDependency(String tagName, Dependency dependency, XMLStreamWriter serializer) private voidwriteDom(XmlNode dom, XMLStreamWriter serializer) private <T> voidwriteList(String tagName, boolean flat, List<T> list, XMLStreamWriter serializer, PluginDescriptorStaxWriter.ElementWriter<T> writer) private <T> voidwriteList(String tagName, List<T> list, XMLStreamWriter serializer, PluginDescriptorStaxWriter.ElementWriter<T> writer) private voidwriteMojoDescriptor(String tagName, MojoDescriptor mojoDescriptor, XMLStreamWriter serializer) private voidwriteParameter(String tagName, Parameter parameter, XMLStreamWriter serializer) private voidwritePluginDescriptor(String tagName, PluginDescriptor pluginDescriptor, XMLStreamWriter serializer) private <T> voidwriteProperties(String tagName, Map<String, String> props, XMLStreamWriter serializer) private voidwriteRequirement(String tagName, Requirement requirement, XMLStreamWriter serializer) private voidwriteResolution(String tagName, Resolution resolution, XMLStreamWriter serializer) private voidwriteTag(String tagName, String defaultValue, String value, XMLStreamWriter serializer)
-
Field Details
-
NAMESPACE
Default namespace.- See Also:
-
SCHEMA_LOCATION
Default schemaLocation.- See Also:
-
namespace
Field namespace. -
schemaLocation
Field schemaLocation. -
fileComment
Field fileComment.
-
-
Constructor Details
-
PluginDescriptorStaxWriter
public PluginDescriptorStaxWriter()
-
-
Method Details
-
setNamespace
Method setNamespace.- Parameters:
namespace- the namespace to use.
-
setSchemaLocation
Method setSchemaLocation.- Parameters:
schemaLocation- the schema location to use.
-
setFileComment
Method setFileComment.- Parameters:
fileComment- a fileComment object.
-
write
public void write(Writer writer, PluginDescriptor pluginDescriptor) throws IOException, XMLStreamException Method write.- Parameters:
writer- a writer objectpluginDescriptor- a PluginDescriptor object- Throws:
IOException- IOException if anyXMLStreamException
-
write
public void write(OutputStream stream, PluginDescriptor pluginDescriptor) throws IOException, XMLStreamException Method write.- Parameters:
stream- a stream objectpluginDescriptor- a PluginDescriptor object- Throws:
IOException- IOException if anyXMLStreamException
-
writePluginDescriptor
private void writePluginDescriptor(String tagName, PluginDescriptor pluginDescriptor, XMLStreamWriter serializer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeMojoDescriptor
private void writeMojoDescriptor(String tagName, MojoDescriptor mojoDescriptor, XMLStreamWriter serializer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeParameter
private void writeParameter(String tagName, Parameter parameter, XMLStreamWriter serializer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeRequirement
private void writeRequirement(String tagName, Requirement requirement, XMLStreamWriter serializer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeDependency
private void writeDependency(String tagName, Dependency dependency, XMLStreamWriter serializer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeResolution
private void writeResolution(String tagName, Resolution resolution, XMLStreamWriter serializer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeList
private <T> void writeList(String tagName, List<T> list, XMLStreamWriter serializer, PluginDescriptorStaxWriter.ElementWriter<T> writer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeList
private <T> void writeList(String tagName, boolean flat, List<T> list, XMLStreamWriter serializer, PluginDescriptorStaxWriter.ElementWriter<T> writer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeProperties
private <T> void writeProperties(String tagName, Map<String, String> props, XMLStreamWriter serializer) throws IOException, XMLStreamException- Throws:
IOExceptionXMLStreamException
-
writeDom
private void writeDom(XmlNode dom, XMLStreamWriter serializer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeTag
private void writeTag(String tagName, String defaultValue, String value, XMLStreamWriter serializer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-
writeAttr
private void writeAttr(String attrName, String value, XMLStreamWriter serializer) throws IOException, XMLStreamException - Throws:
IOExceptionXMLStreamException
-