This is an automated email from the ASF dual-hosted git repository. elharo pushed a commit to branch jd in repository https://gitbox.apache.org/repos/asf/maven-archetype.git
commit 82e8799bf52ac2307d40f02cc35cbaba2e7cb7ce Author: Elliotte Rusty Harold <[email protected]> AuthorDate: Sun Oct 5 16:00:18 2025 -0400 Fix Javadoc issues per Oracle conventions --- .../maven/archetype/ArchetypeCreationRequest.java | 4 +- .../maven/archetype/ArchetypeCreationResult.java | 4 +- .../archetype/ArchetypeGenerationRequest.java | 2 +- .../maven/archetype/ArchetypeGenerationResult.java | 4 +- .../apache/maven/archetype/ArchetypeManager.java | 18 ++- .../archetype/common/ArchetypeArtifactManager.java | 14 -- .../archetype/common/ArchetypeFilesResolver.java | 4 +- .../apache/maven/archetype/common/util/Format.java | 32 ++-- .../maven/archetype/common/util/ListScanner.java | 66 ++++---- .../archetype/common/util/NamespaceStack.java | 14 +- .../maven/archetype/common/util/PathUtils.java | 4 +- .../maven/archetype/common/util/PomUtils.java | 6 +- .../maven/archetype/common/util/XMLOutputter.java | 166 ++++++++++----------- .../archetype/creator/FilesetArchetypeCreator.java | 2 +- .../generator/DefaultArchetypeGenerator.java | 4 +- .../old/descriptor/ArchetypeDescriptorBuilder.java | 20 +-- .../old/descriptor/TemplateDescriptor.java | 10 +- .../DefaultRepositoryCrawler.java | 2 +- .../source/ArchetypeDataSourceException.java | 4 +- .../apache/maven/archetype/mojos/FileLogger.java | 10 +- .../maven/archetype/mojos/IntegrationTestMojo.java | 20 +-- .../archetype/mojos/UpdateLocalCatalogMojo.java | 2 +- .../ui/creation/ArchetypeCreationQueryer.java | 24 +-- .../ui/generation/ArchetypeGenerationQueryer.java | 2 +- .../ui/generation/ArchetypeSelectionQueryer.java | 2 +- .../ui/generation/ArchetypeSelectorUtils.java | 4 +- 26 files changed, 211 insertions(+), 233 deletions(-) diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeCreationRequest.java b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeCreationRequest.java index 3e3f4a28..a0961032 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeCreationRequest.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeCreationRequest.java @@ -25,7 +25,9 @@ import java.util.Properties; import org.apache.maven.project.MavenProject; -/** @author Jason van Zyl */ +/** + * @author Jason van Zyl + */ public class ArchetypeCreationRequest { private File localRepositoryBasedir; diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeCreationResult.java b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeCreationResult.java index cd23cd35..b3acd08c 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeCreationResult.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeCreationResult.java @@ -18,7 +18,9 @@ */ package org.apache.maven.archetype; -/** @author Jason van Zyl */ +/** + * @author Jason van Zyl + */ public class ArchetypeCreationResult { private Exception cause; diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeGenerationRequest.java b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeGenerationRequest.java index e0a113fd..515fc6bd 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeGenerationRequest.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeGenerationRequest.java @@ -71,7 +71,7 @@ public class ArchetypeGenerationRequest { private String archetypeGoals = ""; /** - * The URL to the archetype repository + * The URL to the archetype repository. * * @deprecated see ARCHETYPE-439 */ diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeGenerationResult.java b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeGenerationResult.java index 71488d86..bd7a2f1e 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeGenerationResult.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeGenerationResult.java @@ -18,7 +18,9 @@ */ package org.apache.maven.archetype; -/** @author Jason van Zyl */ +/** + * @author Jason van Zyl + */ public class ArchetypeGenerationResult { private Exception cause; diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeManager.java b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeManager.java index 62c881de..196affe8 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeManager.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/ArchetypeManager.java @@ -28,7 +28,9 @@ import org.apache.maven.artifact.DependencyResolutionRequiredException; import org.eclipse.aether.RepositorySystemSession; import org.eclipse.aether.repository.RemoteRepository; -/** @author Jason van Zyl */ +/** + * @author Jason van Zyl + */ public interface ArchetypeManager { String ROLE = ArchetypeManager.class.getName(); @@ -36,7 +38,7 @@ public interface ArchetypeManager { * A command to create an archetype from an existing Maven project given the supplied creation request. * * @param request - * @return The result of creating the archetype from the existing project. It contains any errors that might have + * @return the result of creating the archetype from the existing project. It contains any errors that might have * occurred. */ ArchetypeCreationResult createArchetypeFromProject(ArchetypeCreationRequest request); @@ -45,7 +47,7 @@ public interface ArchetypeManager { * A command to generate a Maven project from an archetype given the supplied generation request. * * @param request - * @return The result of creating the project from the existing archetype. It contains any errors that might have + * @return the result of creating the project from the existing archetype. It contains any errors that might have * occurred. */ ArchetypeGenerationResult generateProjectFromArchetype(ArchetypeGenerationRequest request); @@ -53,7 +55,7 @@ public interface ArchetypeManager { /** * Gives the catalog of archetypes internal to the plugin. * - * @return the catalog. + * @return the catalog */ ArchetypeCatalog getInternalCatalog(); @@ -63,7 +65,7 @@ public interface ArchetypeManager { * if path is a directory, archetype-catalog.xml is appended to it. * * @param repositorySession - * @return the catalog. + * @return the catalog */ ArchetypeCatalog getLocalCatalog(RepositorySystemSession repositorySession); @@ -73,7 +75,7 @@ public interface ArchetypeManager { * * @param repositorySession * @param remoteRepositories - * @return the catalog. + * @return the catalog */ ArchetypeCatalog getRemoteCatalog( RepositorySystemSession repositorySession, List<RemoteRepository> remoteRepositories); @@ -84,9 +86,9 @@ public interface ArchetypeManager { * @param archetypeDirectory * @param outputDirectory * @param finalName - * @return The File to the generated jar - * @throws org.apache.maven.artifact.DependencyResolutionRequiredException + * @return the File to the generated jar * @throws java.io.IOException + * @throws org.apache.maven.artifact.DependencyResolutionRequiredException * @deprecated replaced by archetype plugin's JarMojo using maven-archiver component for Reproducible Builds */ @Deprecated diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/common/ArchetypeArtifactManager.java b/archetype-common/src/main/java/org/apache/maven/archetype/common/ArchetypeArtifactManager.java index 96b49c26..04099cce 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/common/ArchetypeArtifactManager.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/common/ArchetypeArtifactManager.java @@ -42,20 +42,12 @@ public interface ArchetypeArtifactManager { RepositorySystemSession repositorySystemSession) throws UnknownArchetype; - /** - */ ClassLoader getArchetypeJarLoader(File archetypeFile) throws UnknownArchetype; - /** - */ ZipFile getArchetypeZipFile(File archetypeFile) throws UnknownArchetype; - /** - */ boolean isFileSetArchetype(File archetypeFile); - /** - */ boolean isOldArchetype(File archetypeFile); boolean exists( @@ -75,16 +67,10 @@ public interface ArchetypeArtifactManager { */ String getPostGenerationScript(File archetypeFile) throws UnknownArchetype; - /** - */ ArchetypeDescriptor getFileSetArchetypeDescriptor(File archetypeFile) throws UnknownArchetype; - /** - */ List<String> getFilesetArchetypeResources(File archetypeFile) throws UnknownArchetype; - /** - */ org.apache.maven.archetype.old.descriptor.ArchetypeDescriptor getOldArchetypeDescriptor(File archetypeFile) throws UnknownArchetype; } diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/common/ArchetypeFilesResolver.java b/archetype-common/src/main/java/org/apache/maven/archetype/common/ArchetypeFilesResolver.java index bbbed3f6..d924bd42 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/common/ArchetypeFilesResolver.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/common/ArchetypeFilesResolver.java @@ -24,7 +24,9 @@ import java.util.List; import org.apache.maven.archetype.metadata.FileSet; -/** @author rafale */ +/** + * @author rafale + */ public interface ArchetypeFilesResolver { List<String> getFilesWithExtension(List<String> files, String extension); diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/Format.java b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/Format.java index ec19feed..6b2aa8fc 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/Format.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/Format.java @@ -134,22 +134,22 @@ public class Format implements Cloneable { return f; } - /** standard value to indent by, if we are indenting */ + /** Standard value to indent by, if we are indenting. */ private static final String STANDARD_INDENT = " "; - /** standard string with which to end a line */ + /** Standard string with which to end a line. */ private static final String STANDARD_LINE_SEPARATOR = "\r\n"; - /** standard encoding */ + /** Standard encoding. */ private static final String STANDARD_ENCODING = "UTF-8"; - /** The default indent is no spaces (as original document) */ + /** The default indent is no spaces (as original document). */ String indent = null; - /** New line separator */ + /** New line separator. */ String lineSeparator = STANDARD_LINE_SEPARATOR; - /** The encoding format */ + /** The encoding format. */ String encoding = STANDARD_ENCODING; /** @@ -176,10 +176,10 @@ public class Format implements Cloneable { */ boolean ignoreTrAXEscapingPIs = false; - /** text handling mode */ + /** Text handling mode. */ TextMode mode = TextMode.PRESERVE; - /** entity escape logic */ + /** Entity escape logic. */ EscapeStrategy escapeStrategy = new DefaultEscapeStrategy(encoding); /** Creates a new Format instance with default (raw) behavior. */ @@ -197,7 +197,7 @@ public class Format implements Cloneable { } /** - * Returns the current escape strategy + * Returns the current escape strategy. * * @return the current escape strategy */ @@ -224,7 +224,7 @@ public class Format implements Cloneable { * verbatim, as "\n" which is how parsers normalize them. * </p> * - * @param separator <code>String</code> line separator to use. + * @param separator <code>String</code> line separator to use * @return a pointer to this Format for chaining * @see #setTextMode */ @@ -250,7 +250,7 @@ public class Format implements Cloneable { * this in uses such as WML and other wireless device protocols. * * @param omitEncoding <code>boolean</code> indicating whether or not - * the XML declaration should indicate the document encoding. + * the XML declaration should indicate the document encoding * @return a pointer to this Format for chaining */ public Format setOmitEncoding(boolean omitEncoding) { @@ -274,7 +274,7 @@ public class Format implements Cloneable { * as SOAP and XML-RPC calls. * * @param omitDeclaration <code>boolean</code> indicating whether or not - * the XML declaration should be omitted. + * the XML declaration should be omitted * @return a pointer to this Format for chaining */ public Format setOmitDeclaration(boolean omitDeclaration) { @@ -297,7 +297,7 @@ public class Format implements Cloneable { * <code><tagName></tagName></code>. * * @param expandEmptyElements <code>boolean</code> indicating whether or not - * empty elements should be expanded. + * empty elements should be expanded * @return a pointer to this Format for chaining */ public Format setExpandEmptyElements(boolean expandEmptyElements) { @@ -336,7 +336,7 @@ public class Format implements Cloneable { * Default: <code>false</code>. * * @param ignoreTrAXEscapingPIs <code>boolean</code> indicating - * whether or not TrAX ouput escaping PIs are ignored. + * whether or not TrAX ouput escaping PIs are ignored * @see javax.xml.transform.Result#PI_ENABLE_OUTPUT_ESCAPING * @see javax.xml.transform.Result#PI_DISABLE_OUTPUT_ESCAPING */ @@ -348,7 +348,7 @@ public class Format implements Cloneable { * Returns whether JAXP TrAX processing instructions for * disabling/enabling output escaping are ignored. * - * @return whether or not TrAX ouput escaping PIs are ignored. + * @return whether or not TrAX ouput escaping PIs are ignored */ public boolean getIgnoreTrAXEscapingPIs() { return ignoreTrAXEscapingPIs; @@ -380,7 +380,7 @@ public class Format implements Cloneable { * null, or the empty string (""), then no indentation will * happen. Default: none (null) * - * @param indent <code>String</code> to use for indentation. + * @param indent <code>String</code> to use for indentation * @return a pointer to this Format for chaining */ public Format setIndent(String indent) { diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/ListScanner.java b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/ListScanner.java index 3d26f110..d386fe59 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/ListScanner.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/ListScanner.java @@ -185,13 +185,13 @@ public class ListScanner { * Tests whether or not a string matches against a pattern. The pattern may contain two special * characters:<br> * '*' means zero or more characters<br> - * '?' means one and only one character + * '?' means one and only one character. * - * @param pattern The pattern to match against. Must not be <code>null</code>. - * @param str The string which must be matched against the pattern. Must not be <code> + * @param pattern the pattern to match against. Must not be <code>null</code>. + * @param str the string which must be matched against the pattern. Must not be <code> * null</code>. * @return <code>true</code> if the string matches against the pattern, or <code>false</code> - * otherwise. + * otherwise */ public static boolean match(String pattern, String str) { // default matches the SelectorUtils default @@ -202,14 +202,14 @@ public class ListScanner { * Tests whether or not a string matches against a pattern. The pattern may contain two special * characters:<br> * '*' means zero or more characters<br> - * '?' means one and only one character + * '?' means one and only one character. * - * @param pattern The pattern to match against. Must not be <code>null</code>. - * @param str The string which must be matched against the pattern. Must not be + * @param pattern the pattern to match against. Must not be <code>null</code>. + * @param str the string which must be matched against the pattern. Must not be * <code>null</code>. - * @param isCaseSensitive Whether or not matching should be performed case sensitively. + * @param isCaseSensitive whether or not matching should be performed case sensitively * @return <code>true</code> if the string matches against the pattern, or <code>false</code> - * otherwise. + * otherwise */ protected static boolean match(String pattern, String str, boolean isCaseSensitive) { return SelectorUtils.match(pattern, str, isCaseSensitive); @@ -218,10 +218,10 @@ public class ListScanner { /** * Tests whether or not a given path matches a given pattern. * - * @param pattern The pattern to match against. Must not be <code>null</code>. - * @param str The path to match, as a String. Must not be <code>null</code>. + * @param pattern the pattern to match against. Must not be <code>null</code>. + * @param str the path to match, as a String. Must not be <code>null</code>. * @return <code>true</code> if the pattern matches against the string, or <code>false</code> - * otherwise. + * otherwise */ protected static boolean matchPath(String pattern, String str) { // default matches the SelectorUtils default @@ -231,11 +231,11 @@ public class ListScanner { /** * Tests whether or not a given path matches a given pattern. * - * @param pattern The pattern to match against. Must not be <code>null</code>. - * @param str The path to match, as a String. Must not be <code>null</code>. - * @param isCaseSensitive Whether or not matching should be performed case sensitively. + * @param pattern the pattern to match against. Must not be <code>null</code>. + * @param str the path to match, as a String. Must not be <code>null</code>. + * @param isCaseSensitive whether or not matching should be performed case sensitively * @return <code>true</code> if the pattern matches against the string, or <code>false</code> - * otherwise. + * otherwise */ protected static boolean matchPath(String pattern, String str, boolean isCaseSensitive) { return SelectorUtils.matchPath( @@ -249,10 +249,10 @@ public class ListScanner { * positives. For example, <code>pattern=**\a</code> and <code>str=b</code> will yield <code> * true</code>.</p> * - * @param pattern The pattern to match against. Must not be <code>null</code>. - * @param str The path to match, as a String. Must not be <code>null</code>. + * @param pattern the pattern to match against. Must not be <code>null</code>. + * @param str the path to match, as a String. Must not be <code>null</code>. * @return whether or not a given path matches the start of a given pattern up to the first - * "**". + * "**" */ protected static boolean matchPatternStart(String pattern, String str) { // default matches SelectorUtils default @@ -266,11 +266,11 @@ public class ListScanner { * positives. For example, <code>pattern=**\a</code> and <code>str=b</code> will yield <code> * true</code>.</p> * - * @param pattern The pattern to match against. Must not be <code>null</code>. - * @param str The path to match, as a String. Must not be <code>null</code>. - * @param isCaseSensitive Whether or not matching should be performed case sensitively. + * @param pattern the pattern to match against. Must not be <code>null</code>. + * @param str the path to match, as a String. Must not be <code>null</code>. + * @param isCaseSensitive whether or not matching should be performed case sensitively * @return whether or not a given path matches the start of a given pattern up to the first - * "**". + * "**" */ protected static boolean matchPatternStart(String pattern, String str, boolean isCaseSensitive) { return SelectorUtils.matchPatternStart( @@ -304,9 +304,9 @@ public class ListScanner { /** * Sets the base directory to be scanned. This is the directory which is scanned recursively. * This directory is normalized for multiple os's (all / and \\ are replaced with - * File.separatorChar + * File.separatorChar. * - * @param basedir The base directory for scanning. Should not be <code>null</code>. + * @param basedir the base directory for scanning. Should not be <code>null</code>. */ public void setBasedir(String basedir) { this.basedir = basedir; @@ -329,7 +329,7 @@ public class ListScanner { * * <p>When a pattern ends with a '/' or '\', "**" is appended.</p> * - * @param excludesList A list of exclude patterns. May be <code>null</code>, indicating that no + * @param excludesList a list of exclude patterns. May be <code>null</code>, indicating that no * files should be excluded. If a non-<code>null</code> list is given, all * elements must be non-<code>null</code>. */ @@ -357,7 +357,7 @@ public class ListScanner { * * <p>When a pattern ends with a '/' or '\', "**" is appended.</p> * - * @param includesList A list of include patterns. May be <code>null</code>, indicating that all + * @param includesList a list of include patterns. May be <code>null</code>, indicating that all * files should be included. If a non-<code>null</code> list is given, all * elements must be non-<code>null</code>. */ @@ -412,7 +412,7 @@ public class ListScanner { /** * Tests whether a name matches at least one exclude pattern. * - * @param name The name to match. Must not be <code>null</code> + * @param name the name to match. Must not be <code>null</code> * @return <code>true</code> when the name matches against at least one exclude pattern, or * <code>false</code> otherwise */ @@ -423,9 +423,9 @@ public class ListScanner { /** * Tests whether or not a name matches against at least one include pattern. * - * @param name The name to match. Must not be <code>null</code>. + * @param name the name to match. Must not be <code>null</code>. * @return <code>true</code> when the name matches against at least one include pattern, or - * <code>false</code> otherwise. + * <code>false</code> otherwise */ protected boolean isIncluded(String name) { return matchesPatterns(name, includes); @@ -434,10 +434,10 @@ public class ListScanner { /** * Tests whether or not a name matches against at least one include pattern. * - * @param name The name to match. Must not be <code>null</code>. - * @param patterns The list of patterns to match. + * @param name the name to match. Must not be <code>null</code>. + * @param patterns the list of patterns to match * @return <code>true</code> when the name matches against at least one include pattern, or - * <code>false</code> otherwise. + * <code>false</code> otherwise */ protected boolean matchesPatterns(String name, String[] patterns) { // avoid extra object creation in the loop diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/NamespaceStack.java b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/NamespaceStack.java index 0eea3c59..d4c4e89b 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/NamespaceStack.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/NamespaceStack.java @@ -83,10 +83,10 @@ import org.jdom2.Namespace; * @author Brett McLaughlin */ class NamespaceStack { - /** The prefixes available */ + /** The prefixes available. */ private Stack<String> prefixes; - /** The URIs available */ + /** The URIs available. */ private Stack<String> uris; /** This creates the needed storage. */ @@ -99,7 +99,7 @@ class NamespaceStack { * This will add a new <code>{@link Namespace}</code> * to those currently available. * - * @param ns <code>Namespace</code> to add. + * @param ns <code>Namespace</code> to add */ public void push(Namespace ns) { prefixes.push(ns.getPrefix()); @@ -110,7 +110,7 @@ class NamespaceStack { * This will remove the topmost (most recently added) * <code>{@link Namespace}</code>, and return its prefix. * - * @return <code>String</code> - the popped namespace prefix. + * @return <code>String</code> - the popped namespace prefix */ public String pop() { String prefix = prefixes.pop(); @@ -122,7 +122,7 @@ class NamespaceStack { /** * This returns the number of available namespaces. * - * @return <code>int</code> - size of the namespace stack. + * @return <code>int</code> - size of the namespace stack */ public int size() { return prefixes.size(); @@ -132,8 +132,8 @@ class NamespaceStack { * Given a prefix, this will return the namespace URI most * rencently (topmost) associated with that prefix. * - * @param prefix <code>String</code> namespace prefix. - * @return <code>String</code> - the namespace URI for that prefix. + * @param prefix <code>String</code> namespace prefix + * @return <code>String</code> - the namespace URI for that prefix */ public String getURI(String prefix) { int index = prefixes.lastIndexOf(prefix); diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/PathUtils.java b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/PathUtils.java index 00acaec8..8179341e 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/PathUtils.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/PathUtils.java @@ -24,7 +24,9 @@ import java.util.List; import org.codehaus.plexus.util.StringUtils; -/** @author rafale */ +/** + * @author rafale + */ public class PathUtils { /** * This method converts all \ or / chars to File.separatorChar. diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/PomUtils.java b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/PomUtils.java index 0e2fd956..13e6a9fd 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/PomUtils.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/PomUtils.java @@ -60,10 +60,10 @@ public final class PomUtils { * @param fileReader source POM XML * @param fileWriter target XML * @return {@code true} if modules section in POM is empty or does not exist or {@code artifactId} does not appear - * a module in {@code fileReader} XML. - * @throws IOException if I/O error - * @throws InvalidPackaging if packaging is not "pom" or not exist in POM + * a module in {@code fileReader} XML * @throws ArchetypeTemplateProcessingException if "project" does not exist or "modules" element is duplicated + * @throws InvalidPackaging if packaging is not "pom" or not exist in POM + * @throws IOException if I/O error * @throws ParserConfigurationException if parser error * @throws SAXException if parser error * @throws TransformerException if an error writing to {@code fileWriter} diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/XMLOutputter.java b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/XMLOutputter.java index afcf8e0a..563b83b5 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/common/util/XMLOutputter.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/common/util/XMLOutputter.java @@ -222,9 +222,9 @@ public class XMLOutputter implements Cloneable { * The characters are printed using the encoding specified in the * constructor, or a default of UTF-8. * - * @param doc <code>Document</code> to format. - * @param out <code>OutputStream</code> to use. - * @throws IOException - if there's any problem writing. + * @param doc <code>Document</code> to format + * @param out <code>OutputStream</code> to use + * @throws IOException if there's any problem writing */ public void output(Document doc, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -234,8 +234,8 @@ public class XMLOutputter implements Cloneable { /** * Print out the <code>{@link DocType}</code>. * - * @param doctype <code>DocType</code> to output. - * @param out <code>OutputStream</code> to use. + * @param doctype <code>DocType</code> to output + * @param out <code>OutputStream</code> to use */ public void output(DocType doctype, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -247,8 +247,8 @@ public class XMLOutputter implements Cloneable { * its <code>{@link Attribute}</code>s, and all * contained (child) elements, etc. * - * @param element <code>Element</code> to output. - * @param out <code>Writer</code> to use. + * @param element <code>Element</code> to output + * @param out <code>Writer</code> to use */ public void output(Element element, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -262,8 +262,8 @@ public class XMLOutputter implements Cloneable { * element that contains HTML, like "<description>JDOM is * <b>fun>!</description>". * - * @param element <code>Element</code> to output. - * @param out <code>OutputStream</code> to use. + * @param element <code>Element</code> to output + * @param out <code>OutputStream</code> to use */ public void outputElementContent(Element element, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -276,8 +276,8 @@ public class XMLOutputter implements Cloneable { * contains HTML, like "<description>JDOM is * <b>fun>!</description>". * - * @param list <code>List</code> of nodes. - * @param out <code>OutputStream</code> to use. + * @param list <code>List</code> of nodes + * @param out <code>OutputStream</code> to use */ public void output(List<?> list, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -287,8 +287,8 @@ public class XMLOutputter implements Cloneable { /** * Print out a <code>{@link CDATA}</code> node. * - * @param cdata <code>CDATA</code> to output. - * @param out <code>OutputStream</code> to use. + * @param cdata <code>CDATA</code> to output + * @param out <code>OutputStream</code> to use */ public void output(CDATA cdata, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -299,8 +299,8 @@ public class XMLOutputter implements Cloneable { * Print out a <code>{@link Text}</code> node. Perfoms * the necessary entity escaping and whitespace stripping. * - * @param text <code>Text</code> to output. - * @param out <code>OutputStream</code> to use. + * @param text <code>Text</code> to output + * @param out <code>OutputStream</code> to use */ public void output(Text text, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -310,8 +310,8 @@ public class XMLOutputter implements Cloneable { /** * Print out a <code>{@link Comment}</code>. * - * @param comment <code>Comment</code> to output. - * @param out <code>OutputStream</code> to use. + * @param comment <code>Comment</code> to output + * @param out <code>OutputStream</code> to use */ public void output(Comment comment, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -321,8 +321,8 @@ public class XMLOutputter implements Cloneable { /** * Print out a <code>{@link ProcessingInstruction}</code>. * - * @param pi <code>ProcessingInstruction</code> to output. - * @param out <code>OutputStream</code> to use. + * @param pi <code>ProcessingInstruction</code> to output + * @param out <code>OutputStream</code> to use */ public void output(ProcessingInstruction pi, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -332,8 +332,8 @@ public class XMLOutputter implements Cloneable { /** * Print out a <code>{@link EntityRef}</code>. * - * @param entity <code>EntityRef</code> to output. - * @param out <code>OutputStream</code> to use. + * @param entity <code>EntityRef</code> to output + * @param out <code>OutputStream</code> to use */ public void output(EntityRef entity, OutputStream out) throws IOException { Writer writer = makeWriter(out); @@ -364,9 +364,9 @@ public class XMLOutputter implements Cloneable { * encodings other than UTF-8, we recommend using the method that * takes an OutputStream instead.</p> * - * @param doc <code>Document</code> to format. - * @param out <code>Writer</code> to use. - * @throws IOException - if there's any problem writing. + * @param doc <code>Document</code> to format + * @param out <code>Writer</code> to use + * @throws IOException if there's any problem writing */ public void output(Document doc, Writer out) throws IOException { @@ -408,8 +408,8 @@ public class XMLOutputter implements Cloneable { /** * Print out the <code>{@link DocType}</code>. * - * @param doctype <code>DocType</code> to output. - * @param out <code>Writer</code> to use. + * @param doctype <code>DocType</code> to output + * @param out <code>Writer</code> to use */ public void output(DocType doctype, Writer out) throws IOException { printDocType(out, doctype); @@ -420,8 +420,8 @@ public class XMLOutputter implements Cloneable { * its <code>{@link Attribute}</code>s, and all * contained (child) elements, etc. * - * @param element <code>Element</code> to output. - * @param out <code>Writer</code> to use. + * @param element <code>Element</code> to output + * @param out <code>Writer</code> to use */ public void output(Element element, Writer out) throws IOException { // If this is the root element we could pre-initialize the @@ -436,8 +436,8 @@ public class XMLOutputter implements Cloneable { * element that contains HTML, like "<description>JDOM is * <b>fun>!</description>". * - * @param element <code>Element</code> to output. - * @param out <code>Writer</code> to use. + * @param element <code>Element</code> to output + * @param out <code>Writer</code> to use */ public void outputElementContent(Element element, Writer out) throws IOException { List<?> content = element.getContent(); @@ -450,8 +450,8 @@ public class XMLOutputter implements Cloneable { * contains HTML, like "<description>JDOM is * <b>fun>!</description>". * - * @param list <code>List</code> of nodes. - * @param out <code>Writer</code> to use. + * @param list <code>List</code> of nodes + * @param out <code>Writer</code> to use */ public void output(List<?> list, Writer out) throws IOException { printContentRange(out, list, 0, list.size(), 0, createNamespaceStack()); @@ -460,8 +460,8 @@ public class XMLOutputter implements Cloneable { /** * Print out a <code>{@link CDATA}</code> node. * - * @param cdata <code>CDATA</code> to output. - * @param out <code>Writer</code> to use. + * @param cdata <code>CDATA</code> to output + * @param out <code>Writer</code> to use */ public void output(CDATA cdata, Writer out) throws IOException { printCDATA(out, cdata); @@ -471,8 +471,8 @@ public class XMLOutputter implements Cloneable { * Print out a <code>{@link Text}</code> node. Perfoms * the necessary entity escaping and whitespace stripping. * - * @param text <code>Text</code> to output. - * @param out <code>Writer</code> to use. + * @param text <code>Text</code> to output + * @param out <code>Writer</code> to use */ public void output(Text text, Writer out) throws IOException { printText(out, text); @@ -481,8 +481,8 @@ public class XMLOutputter implements Cloneable { /** * Print out a <code>{@link Comment}</code>. * - * @param comment <code>Comment</code> to output. - * @param out <code>Writer</code> to use. + * @param comment <code>Comment</code> to output + * @param out <code>Writer</code> to use */ public void output(Comment comment, Writer out) throws IOException { printComment(out, comment); @@ -491,8 +491,8 @@ public class XMLOutputter implements Cloneable { /** * Print out a <code>{@link ProcessingInstruction}</code>. * - * @param pi <code>ProcessingInstruction</code> to output. - * @param out <code>Writer</code> to use. + * @param pi <code>ProcessingInstruction</code> to output + * @param out <code>Writer</code> to use */ public void output(ProcessingInstruction pi, Writer out) throws IOException { boolean currentEscapingPolicy = currentFormat.ignoreTrAXEscapingPIs; @@ -506,8 +506,8 @@ public class XMLOutputter implements Cloneable { /** * Print out a <code>{@link EntityRef}</code>. * - * @param entity <code>EntityRef</code> to output. - * @param out <code>Writer</code> to use. + * @param entity <code>EntityRef</code> to output + * @param out <code>Writer</code> to use */ public void output(EntityRef entity, Writer out) throws IOException { printEntityRef(out, entity); @@ -521,7 +521,7 @@ public class XMLOutputter implements Cloneable { * StringWriter. Warning: a String is Unicode, which may not match * the outputter's specified encoding. * - * @param doc <code>Document</code> to format. + * @param doc <code>Document</code> to format */ public String outputString(Document doc) { StringWriter out = new StringWriter(); @@ -537,7 +537,7 @@ public class XMLOutputter implements Cloneable { * Unicode, which may not match the outputter's specified * encoding. * - * @param doctype <code>DocType</code> to format. + * @param doctype <code>DocType</code> to format */ public String outputString(DocType doctype) { StringWriter out = new StringWriter(); @@ -553,7 +553,7 @@ public class XMLOutputter implements Cloneable { * Unicode, which may not match the outputter's specified * encoding. * - * @param element <code>Element</code> to format. + * @param element <code>Element</code> to format */ public String outputString(Element element) { StringWriter out = new StringWriter(); @@ -568,7 +568,7 @@ public class XMLOutputter implements Cloneable { * Return a string representing a list of nodes. The list is * assumed to contain legal JDOM nodes. * - * @param list <code>List</code> to format. + * @param list <code>List</code> to format */ public String outputString(List<?> list) { StringWriter out = new StringWriter(); @@ -584,7 +584,7 @@ public class XMLOutputter implements Cloneable { * Unicode, which may not match the outputter's specified * encoding. * - * @param cdata <code>CDATA</code> to format. + * @param cdata <code>CDATA</code> to format */ public String outputString(CDATA cdata) { StringWriter out = new StringWriter(); @@ -600,7 +600,7 @@ public class XMLOutputter implements Cloneable { * Unicode, which may not match the outputter's specified * encoding. * - * @param text <code>Text</code> to format. + * @param text <code>Text</code> to format */ public String outputString(Text text) { StringWriter out = new StringWriter(); @@ -616,7 +616,7 @@ public class XMLOutputter implements Cloneable { * Unicode, which may not match the outputter's specified * encoding. * - * @param comment <code>Comment</code> to format. + * @param comment <code>Comment</code> to format */ public String outputString(Comment comment) { StringWriter out = new StringWriter(); @@ -632,7 +632,7 @@ public class XMLOutputter implements Cloneable { * Unicode, which may not match the outputter's specified * encoding. * - * @param pi <code>ProcessingInstruction</code> to format. + * @param pi <code>ProcessingInstruction</code> to format */ public String outputString(ProcessingInstruction pi) { StringWriter out = new StringWriter(); @@ -648,7 +648,7 @@ public class XMLOutputter implements Cloneable { * Unicode, which may not match the outputter's specified * encoding. * - * @param entity <code>EntityRef</code> to format. + * @param entity <code>EntityRef</code> to format */ public String outputString(EntityRef entity) { StringWriter out = new StringWriter(); @@ -666,9 +666,9 @@ public class XMLOutputter implements Cloneable { * This will handle printing of the declaration. * Assumes XML version 1.0 since we don't directly know. * - * @param doc <code>Document</code> whose declaration to write. - * @param out <code>Writer</code> to use. - * @param encoding The encoding to add to the declaration + * @param doc <code>Document</code> whose declaration to write + * @param out <code>Writer</code> to use + * @param encoding the encoding to add to the declaration */ protected void printDeclaration(Writer out, Document doc, String encoding) throws IOException { @@ -691,8 +691,8 @@ public class XMLOutputter implements Cloneable { /** * This handle printing the DOCTYPE declaration if one exists. * - * @param docType <code>Document</code> whose declaration to write. - * @param out <code>Writer</code> to use. + * @param docType <code>Document</code> whose declaration to write + * @param out <code>Writer</code> to use */ protected void printDocType(Writer out, DocType docType) throws IOException { @@ -729,8 +729,8 @@ public class XMLOutputter implements Cloneable { /** * This will handle printing of comments. * - * @param comment <code>Comment</code> to write. - * @param out <code>Writer</code> to use. + * @param comment <code>Comment</code> to write + * @param out <code>Writer</code> to use */ protected void printComment(Writer out, Comment comment) throws IOException { out.write("<!--"); @@ -741,8 +741,8 @@ public class XMLOutputter implements Cloneable { /** * This will handle printing of processing instructions. * - * @param pi <code>ProcessingInstruction</code> to write. - * @param out <code>Writer</code> to use. + * @param pi <code>ProcessingInstruction</code> to write + * @param out <code>Writer</code> to use */ protected void printProcessingInstruction(Writer out, ProcessingInstruction pi) throws IOException { String target = pi.getTarget(); @@ -781,8 +781,8 @@ public class XMLOutputter implements Cloneable { * will be printed. However, subclasses are free to override * this method to print the contents of the entity instead. * - * @param entity <code>EntityRef</code> to output. - * @param out <code>Writer</code> to use. + * @param entity <code>EntityRef</code> to output + * @param out <code>Writer</code> to use */ protected void printEntityRef(Writer out, EntityRef entity) throws IOException { out.write("&"); @@ -793,8 +793,8 @@ public class XMLOutputter implements Cloneable { /** * This will handle printing of <code>{@link CDATA}</code> text. * - * @param cdata <code>CDATA</code> to output. - * @param out <code>Writer</code> to use. + * @param cdata <code>CDATA</code> to output + * @param out <code>Writer</code> to use */ protected void printCDATA(Writer out, CDATA cdata) throws IOException { String str = (currentFormat.mode == Format.TextMode.NORMALIZE) @@ -810,8 +810,8 @@ public class XMLOutputter implements Cloneable { /** * This will handle printing of <code>{@link Text}</code> strings. * - * @param text <code>Text</code> to write. - * @param out <code>Writer</code> to use. + * @param text <code>Text</code> to write + * @param out <code>Writer</code> to use */ protected void printText(Writer out, Text text) throws IOException { String str = (currentFormat.mode == Format.TextMode.NORMALIZE) @@ -838,10 +838,10 @@ public class XMLOutputter implements Cloneable { * its <code>{@link Attribute}</code>s, and all contained (child) * elements, etc. * - * @param element <code>Element</code> to output. - * @param out <code>Writer</code> to use. - * @param level <code>int</code> level of indention. - * @param namespaces <code>List</code> stack of Namespaces in scope. + * @param element <code>Element</code> to output + * @param out <code>Writer</code> to use + * @param level <code>int</code> level of indention + * @param namespaces <code>List</code> stack of Namespaces in scope */ protected void printElement(Writer out, Element element, int level, NamespaceStack namespaces) throws IOException { @@ -935,11 +935,11 @@ public class XMLOutputter implements Cloneable { * exclusive. * * @param content <code>List</code> of content to output - * @param start index of first content node (inclusive. - * @param end index of last content node (exclusive). - * @param out <code>Writer</code> to use. - * @param level <code>int</code> level of indentation. - * @param namespaces <code>List</code> stack of Namespaces in scope. + * @param start index of first content node (inclusive + * @param end index of last content node (exclusive) + * @param out <code>Writer</code> to use + * @param level <code>int</code> level of indentation + * @param namespaces <code>List</code> stack of Namespaces in scope */ private void printContentRange( Writer out, List<?> content, int start, int end, int level, NamespaceStack namespaces) throws IOException { @@ -1002,9 +1002,9 @@ public class XMLOutputter implements Cloneable { * pass this method any other type of node. * * @param content <code>List</code> of content to output - * @param start index of first content node (inclusive). - * @param end index of last content node (exclusive). - * @param out <code>Writer</code> to use. + * @param start index of first content node (inclusive) + * @param end index of last content node (exclusive) + * @param out <code>Writer</code> to use */ private void printTextRange(Writer out, List<?> content, int start, int end) throws IOException { String previous; // Previous text printed @@ -1070,7 +1070,7 @@ public class XMLOutputter implements Cloneable { * declarations. * * @param ns <code>Namespace</code> to print definition of - * @param out <code>Writer</code> to use. + * @param out <code>Writer</code> to use */ private void printNamespace(Writer out, Namespace ns, NamespaceStack namespaces) throws IOException { String prefix = ns.getPrefix(); @@ -1291,8 +1291,8 @@ public class XMLOutputter implements Cloneable { * the single quote (') because it's not necessary as the outputter * writes attributes surrounded by double-quotes. * - * @param str <code>String</code> input to escape. - * @return <code>String</code> with escaped content. + * @param str <code>String</code> input to escape + * @return <code>String</code> with escaped content */ public String escapeAttributeEntities(String str) { StringBuilder buffer; @@ -1369,8 +1369,8 @@ public class XMLOutputter implements Cloneable { * representation to the appropriate entity reference, suitable for * XML element content. * - * @param str <code>String</code> input to escape. - * @return <code>String</code> with escaped content. + * @param str <code>String</code> input to escape + * @return <code>String</code> with escaped content */ public String escapeElementEntities(String str) { if (!escapeOutput) { diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/creator/FilesetArchetypeCreator.java b/archetype-common/src/main/java/org/apache/maven/archetype/creator/FilesetArchetypeCreator.java index 6a691794..a9107445 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/creator/FilesetArchetypeCreator.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/creator/FilesetArchetypeCreator.java @@ -1561,7 +1561,7 @@ public class FilesetArchetypeCreator implements ArchetypeCreator { } } - /**/ + /** /. */ if (!files.isEmpty()) { LOGGER.info("Ignored files: " + files); } diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultArchetypeGenerator.java b/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultArchetypeGenerator.java index 5d31008f..9ba8ae42 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultArchetypeGenerator.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultArchetypeGenerator.java @@ -109,7 +109,7 @@ public class DefaultArchetypeGenerator implements ArchetypeGenerator { } } - /** Common */ + /** Common. */ public String getPackageAsDirectory(String packageName) { return StringUtils.replace(packageName, ".", "/"); } @@ -120,7 +120,7 @@ public class DefaultArchetypeGenerator implements ArchetypeGenerator { && StringUtils.isNotEmpty(request.getArchetypeVersion()); } - /** FileSetArchetype */ + /** FileSetArchetype. */ private void processFileSetArchetype(ArchetypeGenerationRequest request, File archetypeFile) throws ArchetypeException { filesetGenerator.generateArchetype(request, archetypeFile); diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/old/descriptor/ArchetypeDescriptorBuilder.java b/archetype-common/src/main/java/org/apache/maven/archetype/old/descriptor/ArchetypeDescriptorBuilder.java index 4bc931a0..f3282cda 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/old/descriptor/ArchetypeDescriptorBuilder.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/old/descriptor/ArchetypeDescriptorBuilder.java @@ -121,8 +121,8 @@ public class ArchetypeDescriptorBuilder { * attribute or the Java virtual machine's default if it is not defined. * * @param source a <code><source></code> element from the <code><sources></code> - * @param descriptor the <code>ArchetypeDescriptor</code> to add the source template to. - * @throws XmlPullParserException if the encoding specified is not valid or supported. + * @param descriptor the <code>ArchetypeDescriptor</code> to add the source template to + * @throws XmlPullParserException if the encoding specified is not valid or supported */ private static void addSourceToDescriptor(Xpp3Dom source, ArchetypeDescriptor descriptor) throws XmlPullParserException { @@ -155,9 +155,9 @@ public class ArchetypeDescriptorBuilder { * even if some other encoding is specified in the attribute. * * @param resource a <code><resource></code> element from the <code><resources></code> - * @param descriptor the <code>ArchetypeDescriptor</code> to add the resource template to. + * @param descriptor the <code>ArchetypeDescriptor</code> to add the resource template to * @throws XmlPullParserException if the encoding specified is not valid or supported or if the - * value of the attribute <code>filtered</code> is no valid. + * value of the attribute <code>filtered</code> is no valid */ private static void addResourceToDescriptor(Xpp3Dom resource, ArchetypeDescriptor descriptor) throws XmlPullParserException { @@ -199,8 +199,8 @@ public class ArchetypeDescriptorBuilder { * attribute or the Java virtual machine's default if it is not defined. * * @param testSource a <code><source></code> element from the <code><testSources></code> - * @param descriptor the <code>ArchetypeDescriptor</code> to add the test-source template to. - * @throws XmlPullParserException if the encoding specified is not valid or supported. + * @param descriptor the <code>ArchetypeDescriptor</code> to add the test-source template to + * @throws XmlPullParserException if the encoding specified is not valid or supported */ private static void addTestSourceToDescriptor(Xpp3Dom testSource, ArchetypeDescriptor descriptor) throws XmlPullParserException { @@ -230,9 +230,9 @@ public class ArchetypeDescriptorBuilder { * even if some other encoding is specified in the attribute. * * @param testResource a <code><resource></code> element from the <code><testResources></code> - * @param descriptor the <code>ArchetypeDescriptor</code> to add the test-resource template to. + * @param descriptor the <code>ArchetypeDescriptor</code> to add the test-resource template to * @throws XmlPullParserException if the encoding specified is not valid or supported or if the - * value of the attribute <code>filtered</code> is no valid. + * value of the attribute <code>filtered</code> is no valid */ private static void addTestResourceToDescriptor(Xpp3Dom testResource, ArchetypeDescriptor descriptor) throws XmlPullParserException { @@ -281,9 +281,9 @@ public class ArchetypeDescriptorBuilder { * even if some other encoding is specified in the attribute. * * @param siteResource a <code><resource></code> element from the <code><siteResources></code> - * @param descriptor the <code>ArchetypeDescriptor</code> to add the site-resource template to. + * @param descriptor the <code>ArchetypeDescriptor</code> to add the site-resource template to * @throws XmlPullParserException if the encoding specified is not valid or supported or if the - * value of the attribute <code>filtered</code> is no valid. + * value of the attribute <code>filtered</code> is no valid */ private static void addSiteResourceToDescriptor(Xpp3Dom siteResource, ArchetypeDescriptor descriptor) throws XmlPullParserException { diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/old/descriptor/TemplateDescriptor.java b/archetype-common/src/main/java/org/apache/maven/archetype/old/descriptor/TemplateDescriptor.java index 3b3dac44..298fdc14 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/old/descriptor/TemplateDescriptor.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/old/descriptor/TemplateDescriptor.java @@ -53,7 +53,7 @@ public class TemplateDescriptor { * Returns the canonical name of the default character encoding of this Java * virtual machine. * - * @return the name of the default character encoding. + * @return the name of the default character encoding */ private static String getDefaultEncoding() { String name = System.getProperty("file.encoding"); @@ -74,7 +74,7 @@ public class TemplateDescriptor { * <code>false</code> otherwise. * * @return <code>true</code> if the template should be filtered and - * <code>false</code> otherwise. + * <code>false</code> otherwise */ public boolean isFiltered() { return this.filtered; @@ -85,7 +85,7 @@ public class TemplateDescriptor { * or not. * * @param filtered <code>true</code> if it should be processed by Velocity and - * <code>fales</code> otherwise. + * <code>fales</code> otherwise */ public void setFiltered(boolean filtered) { this.filtered = filtered; @@ -95,7 +95,7 @@ public class TemplateDescriptor { * Returns the name of the encoding of the template file (e.g. * <code>us-ascci</code>, <code>utf-8</code>, <code>iso-8859-1</code>). * - * @return the name of the encoding of the template file. + * @return the name of the encoding of the template file */ public String getEncoding() { return this.encoding; @@ -104,7 +104,7 @@ public class TemplateDescriptor { /** * Sets the name of the encoding of the template file. * - * @param encoding New value of property encoding. + * @param encoding new value of property encoding * @throws IllegalCharsetNameException if the given charset name is illegal * @throws UnsupportedCharsetException if no support for the named encoding * is available in this instance of the Java virtual machine diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/repositorycrawler/DefaultRepositoryCrawler.java b/archetype-common/src/main/java/org/apache/maven/archetype/repositorycrawler/DefaultRepositoryCrawler.java index e7f350ce..7bc3ed80 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/repositorycrawler/DefaultRepositoryCrawler.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/repositorycrawler/DefaultRepositoryCrawler.java @@ -41,7 +41,7 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; /** - * @author rafale + * @author rafale */ @Named @Singleton diff --git a/archetype-common/src/main/java/org/apache/maven/archetype/source/ArchetypeDataSourceException.java b/archetype-common/src/main/java/org/apache/maven/archetype/source/ArchetypeDataSourceException.java index 688f26f2..6d18629c 100644 --- a/archetype-common/src/main/java/org/apache/maven/archetype/source/ArchetypeDataSourceException.java +++ b/archetype-common/src/main/java/org/apache/maven/archetype/source/ArchetypeDataSourceException.java @@ -18,7 +18,9 @@ */ package org.apache.maven.archetype.source; -/** @author Jason van Zyl */ +/** + * @author Jason van Zyl + */ public class ArchetypeDataSourceException extends Exception { public ArchetypeDataSourceException(String message) { super(message); diff --git a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/FileLogger.java b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/FileLogger.java index a02ec3e0..1a976246 100644 --- a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/FileLogger.java +++ b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/FileLogger.java @@ -51,8 +51,8 @@ class FileLogger extends org.apache.maven.shared.scriptinterpreter.FileLogger im /** * Creates a new logger that writes to the specified file. * - * @param outputFile The path to the output file, must not be <code>null</code>. - * @throws java.io.IOException If the output file could not be created. + * @param outputFile the path to the output file, must not be <code>null</code> + * @throws java.io.IOException if the output file could not be created */ FileLogger(File outputFile) throws IOException { super(outputFile, null); @@ -61,9 +61,9 @@ class FileLogger extends org.apache.maven.shared.scriptinterpreter.FileLogger im /** * Creates a new logger that writes to the specified file and optionally mirrors messages to the given mojo logger. * - * @param outputFile The path to the output file, must not be <code>null</code>. - * @param log The mojo logger to additionally output messages to, may be <code>null</code> if not used. - * @throws java.io.IOException If the output file could not be created. + * @param outputFile the path to the output file, must not be <code>null</code> + * @param log the mojo logger to additionally output messages to, may be <code>null</code> if not used + * @throws java.io.IOException if the output file could not be created */ FileLogger(File outputFile, Log log) throws IOException { super(outputFile, log::info); diff --git a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/IntegrationTestMojo.java b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/IntegrationTestMojo.java index d840f822..9da72e06 100644 --- a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/IntegrationTestMojo.java +++ b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/IntegrationTestMojo.java @@ -168,7 +168,7 @@ public class IntegrationTestMojo extends AbstractMojo { private boolean skip = false; /** - * Directory of test projects + * Directory of test projects. * * @since 2.2 */ @@ -226,7 +226,7 @@ public class IntegrationTestMojo extends AbstractMojo { private File localRepositoryPath; /** - * flag to enable show mvn version used for running its (cli option : -V,--show-version ) + * Flag to enable show mvn version used for running its (cli option : -V,--show-version ) * * @since 2.2 */ @@ -250,7 +250,7 @@ public class IntegrationTestMojo extends AbstractMojo { private boolean debug; /** - * A list of additional properties which will be used to filter tokens in settings.xml + * A list of additional properties which will be used to filter tokens in settings.xml. * * @since 2.2 */ @@ -710,7 +710,7 @@ public class IntegrationTestMojo extends AbstractMojo { /** * Returns the map-based value source used to interpolate settings and other stuff. * - * @return The map-based value source for interpolation, never <code>null</code>. + * @return the map-based value source for interpolation, never <code>null</code> */ private Map<String, Object> getInterpolationValueSource() { Map<String, Object> props = new HashMap<>(); @@ -768,10 +768,10 @@ public class IntegrationTestMojo extends AbstractMojo { /** * Creates a new interpolation source backed by the specified Maven project and some user-specified properties. * - * @param mavenProject The Maven project from which to extract interpolated values, must not be - * <code>null</code>. - * @param properties The set of additional properties from which to extract interpolated values, may be - * <code>null</code>. + * @param mavenProject the Maven project from which to extract interpolated values, must not be + * <code>null</code> + * @param properties the set of additional properties from which to extract interpolated values, may be + * <code>null</code> */ protected CompositeMap(MavenProject mavenProject, Map<String, Object> properties) { if (mavenProject == null) { @@ -942,8 +942,8 @@ public class IntegrationTestMojo extends AbstractMojo { * Converts the specified filesystem path to a URL. The resulting URL has no trailing slash regardless whether the * path denotes a file or a directory. * - * @param filename The filesystem path to convert, must not be <code>null</code>. - * @return The <code>file:</code> URL for the specified path, never <code>null</code>. + * @param filename the filesystem path to convert, must not be <code>null</code> + * @return the <code>file:</code> URL for the specified path, never <code>null</code> */ private static String toUrl(String filename) { /* diff --git a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/UpdateLocalCatalogMojo.java b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/UpdateLocalCatalogMojo.java index c2bbf74c..ced19de3 100644 --- a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/UpdateLocalCatalogMojo.java +++ b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/mojos/UpdateLocalCatalogMojo.java @@ -35,7 +35,7 @@ import org.apache.maven.project.MavenProject; import org.codehaus.plexus.util.StringUtils; /** - * Updates the local catalog + * Updates the local catalog. * * @author rafale */ diff --git a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/creation/ArchetypeCreationQueryer.java b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/creation/ArchetypeCreationQueryer.java index ead9f987..b02d44d7 100644 --- a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/creation/ArchetypeCreationQueryer.java +++ b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/creation/ArchetypeCreationQueryer.java @@ -24,51 +24,29 @@ import org.codehaus.plexus.components.interactivity.PrompterException; /** * <p>User interaction component to query informations necessary for an archetype creation from a project.</p> * - * TODO this interface is bound to its implementation through the prompter exception + * TODO this interface is bound to its implementation through the prompter exception. */ public interface ArchetypeCreationQueryer { - /** - */ String getArchetypeArtifactId(String defaultValue) throws PrompterException; - /** - */ String getArchetypeGroupId(String defaultValue) throws PrompterException; - /** - */ String getArchetypeVersion(String defaultValue) throws PrompterException; - /** - */ String getArtifactId(String defaultValue) throws PrompterException; - /** - */ boolean askAddAnotherProperty() throws PrompterException; - /** - */ String askNewPropertyKey() throws PrompterException; - /** - */ String askReplacementValue(String propertyKey, String defaultValue) throws PrompterException; - /** - */ boolean confirmConfiguration(ArchetypeConfiguration archetypeConfiguration) throws PrompterException; - /** - */ String getGroupId(String defaultValue) throws PrompterException; - /** - */ String getPackage(String defaultValue) throws PrompterException; - /** - */ String getVersion(String defaultValue) throws PrompterException; } diff --git a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeGenerationQueryer.java b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeGenerationQueryer.java index cc5b4a81..ba1c7db5 100644 --- a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeGenerationQueryer.java +++ b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeGenerationQueryer.java @@ -26,7 +26,7 @@ import org.codehaus.plexus.components.interactivity.PrompterException; /** * <p>User interaction component to query informations necessary for a project generation from an archetype.</p> * - * TODO this interface is bound to its implementation through the prompter exception + * TODO this interface is bound to its implementation through the prompter exception. */ public interface ArchetypeGenerationQueryer { boolean confirmConfiguration(ArchetypeConfiguration archetypeConfiguration) throws PrompterException; diff --git a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeSelectionQueryer.java b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeSelectionQueryer.java index c419c815..551c7326 100644 --- a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeSelectionQueryer.java +++ b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeSelectionQueryer.java @@ -28,7 +28,7 @@ import org.codehaus.plexus.components.interactivity.PrompterException; /** * <p>User interaction component for archetype selection.</p> * - * TODO this interface is bound to its implementation through the prompter exception + * TODO this interface is bound to its implementation through the prompter exception. */ public interface ArchetypeSelectionQueryer { diff --git a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeSelectorUtils.java b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeSelectorUtils.java index ed57819d..17756840 100644 --- a/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeSelectorUtils.java +++ b/maven-archetype-plugin/src/main/java/org/apache/maven/archetype/ui/generation/ArchetypeSelectorUtils.java @@ -46,8 +46,8 @@ public class ArchetypeSelectorUtils { } /** - * apply some filtering on archetypes. - * currently only on artifactId contains filter + * Apply some filtering on archetypes. + * currently only on artifactId contains filter. * * @param archetypesPerCatalog * @return
