mirror of https://github.com/apache/maven.git
fixed new issues reported by Checkstyle 6.18
This commit is contained in:
parent
e2bc17b508
commit
cf7b0a3ec0
|
@ -98,7 +98,7 @@ public class ComparableVersion
|
||||||
this.value = BIG_INTEGER_ZERO;
|
this.value = BIG_INTEGER_ZERO;
|
||||||
}
|
}
|
||||||
|
|
||||||
public IntegerItem( String str )
|
IntegerItem( String str )
|
||||||
{
|
{
|
||||||
this.value = new BigInteger( str );
|
this.value = new BigInteger( str );
|
||||||
}
|
}
|
||||||
|
@ -169,7 +169,7 @@ public class ComparableVersion
|
||||||
|
|
||||||
private String value;
|
private String value;
|
||||||
|
|
||||||
public StringItem( String value, boolean followedByDigit )
|
StringItem( String value, boolean followedByDigit )
|
||||||
{
|
{
|
||||||
if ( followedByDigit && value.length() == 1 )
|
if ( followedByDigit && value.length() == 1 )
|
||||||
{
|
{
|
||||||
|
|
|
@ -55,7 +55,7 @@ class DefaultProblem
|
||||||
* @param columnNumber The one-based index of the column containing the problem or {@code -1} if unknown.
|
* @param columnNumber The one-based index of the column containing the problem or {@code -1} if unknown.
|
||||||
* @param exception The exception that caused this problem, may be {@code null}.
|
* @param exception The exception that caused this problem, may be {@code null}.
|
||||||
*/
|
*/
|
||||||
public DefaultProblem( String message, Severity severity, String source, int lineNumber, int columnNumber,
|
DefaultProblem( String message, Severity severity, String source, int lineNumber, int columnNumber,
|
||||||
Exception exception )
|
Exception exception )
|
||||||
{
|
{
|
||||||
this.message = message;
|
this.message = message;
|
||||||
|
|
|
@ -36,7 +36,7 @@ class DefaultProblemCollector
|
||||||
|
|
||||||
private String source;
|
private String source;
|
||||||
|
|
||||||
public DefaultProblemCollector( List<Problem> problems )
|
DefaultProblemCollector( List<Problem> problems )
|
||||||
{
|
{
|
||||||
this.problems = ( problems != null ) ? problems : new ArrayList<Problem>();
|
this.problems = ( problems != null ) ? problems : new ArrayList<Problem>();
|
||||||
}
|
}
|
||||||
|
|
|
@ -64,7 +64,7 @@ class ReactorReader
|
||||||
private WorkspaceRepository repository;
|
private WorkspaceRepository repository;
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
public ReactorReader( MavenSession session )
|
ReactorReader( MavenSession session )
|
||||||
{
|
{
|
||||||
projectsByGAV = session.getProjectMap();
|
projectsByGAV = session.getProjectMap();
|
||||||
|
|
||||||
|
|
|
@ -347,7 +347,7 @@ public class RepositoryUtils
|
||||||
|
|
||||||
private final ArtifactHandlerManager handlerManager;
|
private final ArtifactHandlerManager handlerManager;
|
||||||
|
|
||||||
public MavenArtifactTypeRegistry( ArtifactHandlerManager handlerManager )
|
MavenArtifactTypeRegistry( ArtifactHandlerManager handlerManager )
|
||||||
{
|
{
|
||||||
this.handlerManager = handlerManager;
|
this.handlerManager = handlerManager;
|
||||||
}
|
}
|
||||||
|
|
|
@ -197,7 +197,7 @@ public class LegacyLocalRepositoryManager
|
||||||
|
|
||||||
private final Metadata metadata;
|
private final Metadata metadata;
|
||||||
|
|
||||||
public ArtifactMetadataAdapter( Metadata metadata )
|
ArtifactMetadataAdapter( Metadata metadata )
|
||||||
{
|
{
|
||||||
this.metadata = metadata;
|
this.metadata = metadata;
|
||||||
}
|
}
|
||||||
|
@ -291,7 +291,7 @@ public class LegacyLocalRepositoryManager
|
||||||
|
|
||||||
private final RemoteRepository repository;
|
private final RemoteRepository repository;
|
||||||
|
|
||||||
public ArtifactRepositoryAdapter( RemoteRepository repository )
|
ArtifactRepositoryAdapter( RemoteRepository repository )
|
||||||
{
|
{
|
||||||
this.repository = repository;
|
this.repository = repository;
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,7 +32,7 @@ class ArtifactClassRealmConstituent
|
||||||
|
|
||||||
private final Artifact artifact;
|
private final Artifact artifact;
|
||||||
|
|
||||||
public ArtifactClassRealmConstituent( Artifact artifact )
|
ArtifactClassRealmConstituent( Artifact artifact )
|
||||||
{
|
{
|
||||||
this.artifact = artifact;
|
this.artifact = artifact;
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,7 +39,7 @@ class DefaultClassRealmRequest
|
||||||
|
|
||||||
private final List<ClassRealmConstituent> constituents;
|
private final List<ClassRealmConstituent> constituents;
|
||||||
|
|
||||||
public DefaultClassRealmRequest( RealmType type, ClassLoader parent, List<String> parentImports,
|
DefaultClassRealmRequest( RealmType type, ClassLoader parent, List<String> parentImports,
|
||||||
Map<String, ClassLoader> foreignImports, List<ClassRealmConstituent> constituents )
|
Map<String, ClassLoader> foreignImports, List<ClassRealmConstituent> constituents )
|
||||||
{
|
{
|
||||||
this.type = type;
|
this.type = type;
|
||||||
|
|
|
@ -111,7 +111,7 @@ public class DefaultBeanConfigurator
|
||||||
|
|
||||||
private final BeanConfigurationPathTranslator translator;
|
private final BeanConfigurationPathTranslator translator;
|
||||||
|
|
||||||
public BeanExpressionEvaluator( BeanConfigurationRequest request )
|
BeanExpressionEvaluator( BeanConfigurationRequest request )
|
||||||
{
|
{
|
||||||
preprocessor = request.getValuePreprocessor();
|
preprocessor = request.getValuePreprocessor();
|
||||||
translator = request.getPathTranslator();
|
translator = request.getPathTranslator();
|
||||||
|
|
|
@ -35,7 +35,7 @@ class EventSpyExecutionListener
|
||||||
|
|
||||||
private final ExecutionListener delegate;
|
private final ExecutionListener delegate;
|
||||||
|
|
||||||
public EventSpyExecutionListener( EventSpyDispatcher dispatcher, ExecutionListener delegate )
|
EventSpyExecutionListener( EventSpyDispatcher dispatcher, ExecutionListener delegate )
|
||||||
{
|
{
|
||||||
this.dispatcher = dispatcher;
|
this.dispatcher = dispatcher;
|
||||||
this.delegate = delegate;
|
this.delegate = delegate;
|
||||||
|
|
|
@ -34,7 +34,7 @@ class EventSpyRepositoryListener
|
||||||
|
|
||||||
private final RepositoryListener delegate;
|
private final RepositoryListener delegate;
|
||||||
|
|
||||||
public EventSpyRepositoryListener( EventSpyDispatcher dispatcher, RepositoryListener delegate )
|
EventSpyRepositoryListener( EventSpyDispatcher dispatcher, RepositoryListener delegate )
|
||||||
{
|
{
|
||||||
this.dispatcher = dispatcher;
|
this.dispatcher = dispatcher;
|
||||||
this.delegate = delegate;
|
this.delegate = delegate;
|
||||||
|
|
|
@ -47,7 +47,7 @@ class SettingsAdapter
|
||||||
|
|
||||||
private RuntimeInfo runtimeInfo;
|
private RuntimeInfo runtimeInfo;
|
||||||
|
|
||||||
public SettingsAdapter( MavenExecutionRequest request )
|
SettingsAdapter( MavenExecutionRequest request )
|
||||||
{
|
{
|
||||||
this.request = request;
|
this.request = request;
|
||||||
|
|
||||||
|
|
|
@ -50,7 +50,7 @@ class FilteredProjectDependencyGraph
|
||||||
* @param projectDependencyGraph The project dependency graph to create a sub view from, must not be {@code null}.
|
* @param projectDependencyGraph The project dependency graph to create a sub view from, must not be {@code null}.
|
||||||
* @param whiteList The projects on which the dependency view should focus, must not be {@code null}.
|
* @param whiteList The projects on which the dependency view should focus, must not be {@code null}.
|
||||||
*/
|
*/
|
||||||
public FilteredProjectDependencyGraph( ProjectDependencyGraph projectDependencyGraph,
|
FilteredProjectDependencyGraph( ProjectDependencyGraph projectDependencyGraph,
|
||||||
Collection<? extends MavenProject> whiteList )
|
Collection<? extends MavenProject> whiteList )
|
||||||
{
|
{
|
||||||
this.projectDependencyGraph =
|
this.projectDependencyGraph =
|
||||||
|
|
|
@ -35,7 +35,7 @@ class LoggingRepositoryListener
|
||||||
|
|
||||||
private final Logger logger;
|
private final Logger logger;
|
||||||
|
|
||||||
public LoggingRepositoryListener( Logger logger )
|
LoggingRepositoryListener( Logger logger )
|
||||||
{
|
{
|
||||||
this.logger = logger;
|
this.logger = logger;
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,7 +30,7 @@ class CompoundProjectExecutionListener
|
||||||
{
|
{
|
||||||
private final Collection<ProjectExecutionListener> listeners;
|
private final Collection<ProjectExecutionListener> listeners;
|
||||||
|
|
||||||
public CompoundProjectExecutionListener( Collection<ProjectExecutionListener> listeners )
|
CompoundProjectExecutionListener( Collection<ProjectExecutionListener> listeners )
|
||||||
{
|
{
|
||||||
this.listeners = listeners; // NB this is live injected collection
|
this.listeners = listeners; // NB this is live injected collection
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,7 +41,7 @@ class DefaultExecutionEvent
|
||||||
|
|
||||||
private final Exception exception;
|
private final Exception exception;
|
||||||
|
|
||||||
public DefaultExecutionEvent( Type type, MavenSession session, MojoExecution mojoExecution, Exception exception )
|
DefaultExecutionEvent( Type type, MavenSession session, MojoExecution mojoExecution, Exception exception )
|
||||||
{
|
{
|
||||||
this.type = type;
|
this.type = type;
|
||||||
this.session = session;
|
this.session = session;
|
||||||
|
|
|
@ -356,7 +356,7 @@ public class LifecycleDependencyResolver
|
||||||
|
|
||||||
private Set<String> keys = new HashSet<>();
|
private Set<String> keys = new HashSet<>();
|
||||||
|
|
||||||
public ReactorDependencyFilter( Collection<Artifact> artifacts )
|
ReactorDependencyFilter( Collection<Artifact> artifacts )
|
||||||
{
|
{
|
||||||
for ( Artifact artifact : artifacts )
|
for ( Artifact artifact : artifacts )
|
||||||
{
|
{
|
||||||
|
|
|
@ -209,7 +209,7 @@ public class ThreadOutputMuxer
|
||||||
extends PrintStream
|
extends PrintStream
|
||||||
{
|
{
|
||||||
|
|
||||||
public ThreadBoundPrintStream( PrintStream systemOutStream )
|
ThreadBoundPrintStream( PrintStream systemOutStream )
|
||||||
{
|
{
|
||||||
super( systemOutStream );
|
super( systemOutStream );
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,7 +30,7 @@ class CompoundMojoExecutionListener
|
||||||
|
|
||||||
private final Collection<MojoExecutionListener> listeners;
|
private final Collection<MojoExecutionListener> listeners;
|
||||||
|
|
||||||
public CompoundMojoExecutionListener( Collection<MojoExecutionListener> listeners )
|
CompoundMojoExecutionListener( Collection<MojoExecutionListener> listeners )
|
||||||
{
|
{
|
||||||
this.listeners = listeners; // NB this is live injected collection
|
this.listeners = listeners; // NB this is live injected collection
|
||||||
}
|
}
|
||||||
|
|
|
@ -141,7 +141,7 @@ public class DefaultPluginDescriptorCache
|
||||||
|
|
||||||
private final int hashCode;
|
private final int hashCode;
|
||||||
|
|
||||||
public CacheKey( Plugin plugin, List<RemoteRepository> repositories, RepositorySystemSession session )
|
CacheKey( Plugin plugin, List<RemoteRepository> repositories, RepositorySystemSession session )
|
||||||
{
|
{
|
||||||
groupId = plugin.getGroupId();
|
groupId = plugin.getGroupId();
|
||||||
artifactId = plugin.getArtifactId();
|
artifactId = plugin.getArtifactId();
|
||||||
|
|
|
@ -44,7 +44,7 @@ public interface ExtensionRealmCache
|
||||||
// marker interface for cache keys
|
// marker interface for cache keys
|
||||||
}
|
}
|
||||||
|
|
||||||
static class CacheRecord
|
class CacheRecord
|
||||||
{
|
{
|
||||||
|
|
||||||
public final ClassRealm realm;
|
public final ClassRealm realm;
|
||||||
|
@ -53,7 +53,7 @@ public interface ExtensionRealmCache
|
||||||
|
|
||||||
public final List<Artifact> artifacts;
|
public final List<Artifact> artifacts;
|
||||||
|
|
||||||
public CacheRecord( ClassRealm realm, ExtensionDescriptor descriptor, List<Artifact> artifacts )
|
CacheRecord( ClassRealm realm, ExtensionDescriptor descriptor, List<Artifact> artifacts )
|
||||||
{
|
{
|
||||||
this.realm = realm;
|
this.realm = realm;
|
||||||
this.descriptor = descriptor;
|
this.descriptor = descriptor;
|
||||||
|
|
|
@ -47,14 +47,14 @@ public interface PluginArtifactsCache
|
||||||
// marker interface for cache keys
|
// marker interface for cache keys
|
||||||
}
|
}
|
||||||
|
|
||||||
static class CacheRecord
|
class CacheRecord
|
||||||
{
|
{
|
||||||
|
|
||||||
public final List<Artifact> artifacts;
|
public final List<Artifact> artifacts;
|
||||||
|
|
||||||
public final PluginResolutionException exception;
|
public final PluginResolutionException exception;
|
||||||
|
|
||||||
public CacheRecord( List<Artifact> artifacts )
|
CacheRecord( List<Artifact> artifacts )
|
||||||
{
|
{
|
||||||
this.artifacts = artifacts;
|
this.artifacts = artifacts;
|
||||||
this.exception = null;
|
this.exception = null;
|
||||||
|
|
|
@ -41,13 +41,13 @@ import org.eclipse.aether.repository.RemoteRepository;
|
||||||
public interface PluginRealmCache
|
public interface PluginRealmCache
|
||||||
{
|
{
|
||||||
|
|
||||||
static class CacheRecord
|
class CacheRecord
|
||||||
{
|
{
|
||||||
public final ClassRealm realm;
|
public final ClassRealm realm;
|
||||||
|
|
||||||
public final List<Artifact> artifacts;
|
public final List<Artifact> artifacts;
|
||||||
|
|
||||||
public CacheRecord( ClassRealm realm, List<Artifact> artifacts )
|
CacheRecord( ClassRealm realm, List<Artifact> artifacts )
|
||||||
{
|
{
|
||||||
this.realm = realm;
|
this.realm = realm;
|
||||||
this.artifacts = artifacts;
|
this.artifacts = artifacts;
|
||||||
|
|
|
@ -52,7 +52,7 @@ class PluginDependencyResolutionListener
|
||||||
|
|
||||||
private Map<Artifact, Object> bannedArtifacts = new IdentityHashMap<>();
|
private Map<Artifact, Object> bannedArtifacts = new IdentityHashMap<>();
|
||||||
|
|
||||||
public PluginDependencyResolutionListener( ArtifactFilter coreFilter )
|
PluginDependencyResolutionListener( ArtifactFilter coreFilter )
|
||||||
{
|
{
|
||||||
this.coreFilter = coreFilter;
|
this.coreFilter = coreFilter;
|
||||||
}
|
}
|
||||||
|
|
|
@ -43,7 +43,7 @@ class ValidatingConfigurationListener
|
||||||
|
|
||||||
private final Map<String, Parameter> missingParameters;
|
private final Map<String, Parameter> missingParameters;
|
||||||
|
|
||||||
public ValidatingConfigurationListener( Object mojo, MojoDescriptor mojoDescriptor, ConfigurationListener delegate )
|
ValidatingConfigurationListener( Object mojo, MojoDescriptor mojoDescriptor, ConfigurationListener delegate )
|
||||||
{
|
{
|
||||||
this.mojo = mojo;
|
this.mojo = mojo;
|
||||||
this.delegate = delegate;
|
this.delegate = delegate;
|
||||||
|
|
|
@ -39,7 +39,7 @@ class WagonExcluder
|
||||||
|
|
||||||
private final boolean coreArtifact;
|
private final boolean coreArtifact;
|
||||||
|
|
||||||
public WagonExcluder()
|
WagonExcluder()
|
||||||
{
|
{
|
||||||
this( false );
|
this( false );
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,18 +39,18 @@ class DefaultPluginPrefixResult
|
||||||
|
|
||||||
private ArtifactRepository repository;
|
private ArtifactRepository repository;
|
||||||
|
|
||||||
public DefaultPluginPrefixResult()
|
DefaultPluginPrefixResult()
|
||||||
{
|
{
|
||||||
// does nothing
|
// does nothing
|
||||||
}
|
}
|
||||||
|
|
||||||
public DefaultPluginPrefixResult( Plugin plugin )
|
DefaultPluginPrefixResult( Plugin plugin )
|
||||||
{
|
{
|
||||||
groupId = plugin.getGroupId();
|
groupId = plugin.getGroupId();
|
||||||
artifactId = plugin.getArtifactId();
|
artifactId = plugin.getArtifactId();
|
||||||
}
|
}
|
||||||
|
|
||||||
public DefaultPluginPrefixResult( String groupId, String artifactId, ArtifactRepository repository )
|
DefaultPluginPrefixResult( String groupId, String artifactId, ArtifactRepository repository )
|
||||||
{
|
{
|
||||||
this.groupId = groupId;
|
this.groupId = groupId;
|
||||||
this.artifactId = artifactId;
|
this.artifactId = artifactId;
|
||||||
|
|
|
@ -36,12 +36,12 @@ class DefaultPluginVersionResult
|
||||||
|
|
||||||
private ArtifactRepository repository;
|
private ArtifactRepository repository;
|
||||||
|
|
||||||
public DefaultPluginVersionResult()
|
DefaultPluginVersionResult()
|
||||||
{
|
{
|
||||||
// does nothing
|
// does nothing
|
||||||
}
|
}
|
||||||
|
|
||||||
public DefaultPluginVersionResult( String version )
|
DefaultPluginVersionResult( String version )
|
||||||
{
|
{
|
||||||
this.version = version;
|
this.version = version;
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,7 +51,7 @@ class DefaultProjectBuildingResult
|
||||||
* @param problems The problems that were encountered, may be {@code null}.
|
* @param problems The problems that were encountered, may be {@code null}.
|
||||||
* @param dependencyResolutionResult The result of the resolution for the project dependencies, may be {@code null}.
|
* @param dependencyResolutionResult The result of the resolution for the project dependencies, may be {@code null}.
|
||||||
*/
|
*/
|
||||||
public DefaultProjectBuildingResult( MavenProject project, List<ModelProblem> problems,
|
DefaultProjectBuildingResult( MavenProject project, List<ModelProblem> problems,
|
||||||
DependencyResolutionResult dependencyResolutionResult )
|
DependencyResolutionResult dependencyResolutionResult )
|
||||||
{
|
{
|
||||||
this.projectId =
|
this.projectId =
|
||||||
|
@ -70,7 +70,7 @@ class DefaultProjectBuildingResult
|
||||||
* @param pomFile The POM file from which the project was built, may be {@code null}.
|
* @param pomFile The POM file from which the project was built, may be {@code null}.
|
||||||
* @param problems The problems that were encountered, may be {@code null}.
|
* @param problems The problems that were encountered, may be {@code null}.
|
||||||
*/
|
*/
|
||||||
public DefaultProjectBuildingResult( String projectId, File pomFile, List<ModelProblem> problems )
|
DefaultProjectBuildingResult( String projectId, File pomFile, List<ModelProblem> problems )
|
||||||
{
|
{
|
||||||
this.projectId = ( projectId != null ) ? projectId : "";
|
this.projectId = ( projectId != null ) ? projectId : "";
|
||||||
this.pomFile = pomFile;
|
this.pomFile = pomFile;
|
||||||
|
|
|
@ -236,7 +236,7 @@ public class DefaultProjectDependenciesResolver
|
||||||
|
|
||||||
private String indent = "";
|
private String indent = "";
|
||||||
|
|
||||||
public GraphLogger( MavenProject project )
|
GraphLogger( MavenProject project )
|
||||||
{
|
{
|
||||||
this.project = project;
|
this.project = project;
|
||||||
}
|
}
|
||||||
|
|
|
@ -43,14 +43,14 @@ public interface ProjectRealmCache
|
||||||
// marker interface for cache keys
|
// marker interface for cache keys
|
||||||
}
|
}
|
||||||
|
|
||||||
static class CacheRecord
|
class CacheRecord
|
||||||
{
|
{
|
||||||
|
|
||||||
public final ClassRealm realm;
|
public final ClassRealm realm;
|
||||||
|
|
||||||
public final DependencyFilter extensionArtifactFilter;
|
public final DependencyFilter extensionArtifactFilter;
|
||||||
|
|
||||||
public CacheRecord( ClassRealm realm, DependencyFilter extensionArtifactFilter )
|
CacheRecord( ClassRealm realm, DependencyFilter extensionArtifactFilter )
|
||||||
{
|
{
|
||||||
this.realm = realm;
|
this.realm = realm;
|
||||||
this.extensionArtifactFilter = extensionArtifactFilter;
|
this.extensionArtifactFilter = extensionArtifactFilter;
|
||||||
|
|
|
@ -58,7 +58,7 @@ class ReactorModelCache
|
||||||
|
|
||||||
private final int hashCode;
|
private final int hashCode;
|
||||||
|
|
||||||
public CacheKey( String groupId, String artifactId, String version, String tag )
|
CacheKey( String groupId, String artifactId, String version, String tag )
|
||||||
{
|
{
|
||||||
this.groupId = ( groupId != null ) ? groupId : "";
|
this.groupId = ( groupId != null ) ? groupId : "";
|
||||||
this.artifactId = ( artifactId != null ) ? artifactId : "";
|
this.artifactId = ( artifactId != null ) ? artifactId : "";
|
||||||
|
|
|
@ -55,7 +55,7 @@ class ReactorModelPool
|
||||||
|
|
||||||
private final int hashCode;
|
private final int hashCode;
|
||||||
|
|
||||||
public CacheKey( String groupId, String artifactId, String version )
|
CacheKey( String groupId, String artifactId, String version )
|
||||||
{
|
{
|
||||||
this.groupId = ( groupId != null ) ? groupId : "";
|
this.groupId = ( groupId != null ) ? groupId : "";
|
||||||
this.artifactId = ( artifactId != null ) ? artifactId : "";
|
this.artifactId = ( artifactId != null ) ? artifactId : "";
|
||||||
|
|
|
@ -46,20 +46,20 @@ public interface ProjectArtifactsCache
|
||||||
// marker interface for cache keys
|
// marker interface for cache keys
|
||||||
}
|
}
|
||||||
|
|
||||||
static class CacheRecord
|
class CacheRecord
|
||||||
{
|
{
|
||||||
|
|
||||||
public final Set<Artifact> artifacts;
|
public final Set<Artifact> artifacts;
|
||||||
|
|
||||||
public final LifecycleExecutionException exception;
|
public final LifecycleExecutionException exception;
|
||||||
|
|
||||||
public CacheRecord( Set<Artifact> artifacts )
|
CacheRecord( Set<Artifact> artifacts )
|
||||||
{
|
{
|
||||||
this.artifacts = artifacts;
|
this.artifacts = artifacts;
|
||||||
this.exception = null;
|
this.exception = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
public CacheRecord( LifecycleExecutionException exception )
|
CacheRecord( LifecycleExecutionException exception )
|
||||||
{
|
{
|
||||||
this.artifacts = null;
|
this.artifacts = null;
|
||||||
this.exception = exception;
|
this.exception = exception;
|
||||||
|
|
|
@ -41,7 +41,7 @@ class JavaToolchainImpl
|
||||||
|
|
||||||
public static final String KEY_JAVAHOME = "jdkHome"; //NOI18N
|
public static final String KEY_JAVAHOME = "jdkHome"; //NOI18N
|
||||||
|
|
||||||
public JavaToolchainImpl( ToolchainModel model, Logger logger )
|
JavaToolchainImpl( ToolchainModel model, Logger logger )
|
||||||
{
|
{
|
||||||
super( model, "jdk", logger );
|
super( model, "jdk", logger );
|
||||||
}
|
}
|
||||||
|
|
|
@ -1684,7 +1684,7 @@ public class MavenCli
|
||||||
@SuppressWarnings( "checkstyle:visibilitymodifier" )
|
@SuppressWarnings( "checkstyle:visibilitymodifier" )
|
||||||
public int exitCode;
|
public int exitCode;
|
||||||
|
|
||||||
public ExitException( int exitCode )
|
ExitException( int exitCode )
|
||||||
{
|
{
|
||||||
this.exitCode = exitCode;
|
this.exitCode = exitCode;
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,7 +28,7 @@ package org.apache.maven.cli.logging;
|
||||||
*/
|
*/
|
||||||
public interface Slf4jConfiguration
|
public interface Slf4jConfiguration
|
||||||
{
|
{
|
||||||
public static enum Level
|
enum Level
|
||||||
{
|
{
|
||||||
DEBUG, INFO, ERROR
|
DEBUG, INFO, ERROR
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,7 +49,7 @@ public abstract class AbstractMavenTransferListener
|
||||||
// TODO Move me to Maven Shared Utils
|
// TODO Move me to Maven Shared Utils
|
||||||
static class FileSizeFormat
|
static class FileSizeFormat
|
||||||
{
|
{
|
||||||
static enum ScaleUnit
|
enum ScaleUnit
|
||||||
{
|
{
|
||||||
BYTE
|
BYTE
|
||||||
{
|
{
|
||||||
|
@ -137,7 +137,7 @@ public abstract class AbstractMavenTransferListener
|
||||||
private DecimalFormat smallFormat;
|
private DecimalFormat smallFormat;
|
||||||
private DecimalFormat largeFormat;
|
private DecimalFormat largeFormat;
|
||||||
|
|
||||||
public FileSizeFormat( Locale locale )
|
FileSizeFormat( Locale locale )
|
||||||
{
|
{
|
||||||
smallFormat = new DecimalFormat( "#0.0", new DecimalFormatSymbols( locale ) );
|
smallFormat = new DecimalFormat( "#0.0", new DecimalFormatSymbols( locale ) );
|
||||||
largeFormat = new DecimalFormat( "###0", new DecimalFormatSymbols( locale ) );
|
largeFormat = new DecimalFormat( "###0", new DecimalFormatSymbols( locale ) );
|
||||||
|
|
|
@ -36,7 +36,7 @@ class DefaultModelBuildingEvent
|
||||||
|
|
||||||
private final ModelProblemCollector problems;
|
private final ModelProblemCollector problems;
|
||||||
|
|
||||||
public DefaultModelBuildingEvent( Model model, ModelBuildingRequest request, ModelProblemCollector problems )
|
DefaultModelBuildingEvent( Model model, ModelBuildingRequest request, ModelProblemCollector problems )
|
||||||
{
|
{
|
||||||
this.model = model;
|
this.model = model;
|
||||||
this.request = request;
|
this.request = request;
|
||||||
|
|
|
@ -49,7 +49,7 @@ class DefaultModelBuildingResult
|
||||||
|
|
||||||
private List<ModelProblem> problems;
|
private List<ModelProblem> problems;
|
||||||
|
|
||||||
public DefaultModelBuildingResult()
|
DefaultModelBuildingResult()
|
||||||
{
|
{
|
||||||
modelIds = new ArrayList<>();
|
modelIds = new ArrayList<>();
|
||||||
rawModels = new HashMap<>();
|
rawModels = new HashMap<>();
|
||||||
|
|
|
@ -51,7 +51,7 @@ class DefaultModelProblemCollector
|
||||||
|
|
||||||
private Set<ModelProblem.Severity> severities = EnumSet.noneOf( ModelProblem.Severity.class );
|
private Set<ModelProblem.Severity> severities = EnumSet.noneOf( ModelProblem.Severity.class );
|
||||||
|
|
||||||
public DefaultModelProblemCollector( ModelBuildingResult result )
|
DefaultModelProblemCollector( ModelBuildingResult result )
|
||||||
{
|
{
|
||||||
this.result = result;
|
this.result = result;
|
||||||
this.problems = result.getProblems();
|
this.problems = result.getProblems();
|
||||||
|
|
|
@ -41,7 +41,7 @@ class FilterModelBuildingRequest
|
||||||
|
|
||||||
protected ModelBuildingRequest request;
|
protected ModelBuildingRequest request;
|
||||||
|
|
||||||
public FilterModelBuildingRequest( ModelBuildingRequest request )
|
FilterModelBuildingRequest( ModelBuildingRequest request )
|
||||||
{
|
{
|
||||||
this.request = request;
|
this.request = request;
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,7 +51,7 @@ class ModelData
|
||||||
*
|
*
|
||||||
* @param model The model to wrap, may be {@code null}.
|
* @param model The model to wrap, may be {@code null}.
|
||||||
*/
|
*/
|
||||||
public ModelData( ModelSource source, Model model )
|
ModelData( ModelSource source, Model model )
|
||||||
{
|
{
|
||||||
this.source = source;
|
this.source = source;
|
||||||
this.model = model;
|
this.model = model;
|
||||||
|
@ -65,7 +65,7 @@ class ModelData
|
||||||
* @param artifactId The effective artifact identifier of the model, may be {@code null}.
|
* @param artifactId The effective artifact identifier of the model, may be {@code null}.
|
||||||
* @param version The effective version of the model, may be {@code null}.
|
* @param version The effective version of the model, may be {@code null}.
|
||||||
*/
|
*/
|
||||||
public ModelData( ModelSource source, Model model, String groupId, String artifactId, String version )
|
ModelData( ModelSource source, Model model, String groupId, String artifactId, String version )
|
||||||
{
|
{
|
||||||
this.source = source;
|
this.source = source;
|
||||||
this.model = model;
|
this.model = model;
|
||||||
|
|
|
@ -29,7 +29,7 @@ class BuildTimestampValueSource
|
||||||
{
|
{
|
||||||
private final MavenBuildTimestamp mavenBuildTimestamp;
|
private final MavenBuildTimestamp mavenBuildTimestamp;
|
||||||
|
|
||||||
public BuildTimestampValueSource( Date startTime, Properties properties )
|
BuildTimestampValueSource( Date startTime, Properties properties )
|
||||||
{
|
{
|
||||||
super( false );
|
super( false );
|
||||||
this.mavenBuildTimestamp = new MavenBuildTimestamp( startTime, properties );
|
this.mavenBuildTimestamp = new MavenBuildTimestamp( startTime, properties );
|
||||||
|
|
|
@ -39,7 +39,7 @@ class PathTranslatingPostProcessor
|
||||||
private final PathTranslator pathTranslator;
|
private final PathTranslator pathTranslator;
|
||||||
private final List<String> expressionPrefixes;
|
private final List<String> expressionPrefixes;
|
||||||
|
|
||||||
public PathTranslatingPostProcessor( List<String> expressionPrefixes, Collection<String> unprefixedPathKeys,
|
PathTranslatingPostProcessor( List<String> expressionPrefixes, Collection<String> unprefixedPathKeys,
|
||||||
File projectDir, PathTranslator pathTranslator )
|
File projectDir, PathTranslator pathTranslator )
|
||||||
{
|
{
|
||||||
this.expressionPrefixes = expressionPrefixes;
|
this.expressionPrefixes = expressionPrefixes;
|
||||||
|
|
|
@ -44,7 +44,7 @@ class ProblemDetectingValueSource
|
||||||
|
|
||||||
private final ModelProblemCollector problems;
|
private final ModelProblemCollector problems;
|
||||||
|
|
||||||
public ProblemDetectingValueSource( ValueSource valueSource, String bannedPrefix, String newPrefix,
|
ProblemDetectingValueSource( ValueSource valueSource, String bannedPrefix, String newPrefix,
|
||||||
ModelProblemCollector problems )
|
ModelProblemCollector problems )
|
||||||
{
|
{
|
||||||
this.valueSource = valueSource;
|
this.valueSource = valueSource;
|
||||||
|
|
|
@ -106,10 +106,9 @@ public class StringSearchModelInterpolator
|
||||||
|
|
||||||
private final ModelProblemCollector problems;
|
private final ModelProblemCollector problems;
|
||||||
|
|
||||||
public InterpolateObjectAction( Object target, List<? extends ValueSource> valueSources,
|
InterpolateObjectAction( Object target, List<? extends ValueSource> valueSources,
|
||||||
List<? extends InterpolationPostProcessor> postProcessors,
|
List<? extends InterpolationPostProcessor> postProcessors,
|
||||||
StringSearchModelInterpolator modelInterpolator,
|
StringSearchModelInterpolator modelInterpolator, ModelProblemCollector problems )
|
||||||
ModelProblemCollector problems )
|
|
||||||
{
|
{
|
||||||
this.valueSources = valueSources;
|
this.valueSources = valueSources;
|
||||||
this.postProcessors = postProcessors;
|
this.postProcessors = postProcessors;
|
||||||
|
|
|
@ -50,7 +50,7 @@ class UrlNormalizingPostProcessor
|
||||||
|
|
||||||
private UrlNormalizer normalizer;
|
private UrlNormalizer normalizer;
|
||||||
|
|
||||||
public UrlNormalizingPostProcessor( UrlNormalizer normalizer )
|
UrlNormalizingPostProcessor( UrlNormalizer normalizer )
|
||||||
{
|
{
|
||||||
this.normalizer = normalizer;
|
this.normalizer = normalizer;
|
||||||
}
|
}
|
||||||
|
|
|
@ -77,7 +77,7 @@ class DefaultModelCache
|
||||||
|
|
||||||
private final int hash;
|
private final int hash;
|
||||||
|
|
||||||
public Key( String groupId, String artifactId, String version, String tag )
|
Key( String groupId, String artifactId, String version, String tag )
|
||||||
{
|
{
|
||||||
this.groupId = groupId;
|
this.groupId = groupId;
|
||||||
this.artifactId = artifactId;
|
this.artifactId = artifactId;
|
||||||
|
|
|
@ -78,7 +78,7 @@ class DefaultModelResolver
|
||||||
|
|
||||||
private final Set<String> repositoryIds;
|
private final Set<String> repositoryIds;
|
||||||
|
|
||||||
public DefaultModelResolver( RepositorySystemSession session, RequestTrace trace, String context,
|
DefaultModelResolver( RepositorySystemSession session, RequestTrace trace, String context,
|
||||||
ArtifactResolver resolver, VersionRangeResolver versionRangeResolver,
|
ArtifactResolver resolver, VersionRangeResolver versionRangeResolver,
|
||||||
RemoteRepositoryManager remoteRepositoryManager, List<RemoteRepository> repositories )
|
RemoteRepositoryManager remoteRepositoryManager, List<RemoteRepository> repositories )
|
||||||
{
|
{
|
||||||
|
|
|
@ -475,7 +475,7 @@ public class DefaultVersionResolver
|
||||||
|
|
||||||
ArtifactRepository repository;
|
ArtifactRepository repository;
|
||||||
|
|
||||||
public VersionInfo( String timestamp, String version, ArtifactRepository repository )
|
VersionInfo( String timestamp, String version, ArtifactRepository repository )
|
||||||
{
|
{
|
||||||
this.timestamp = ( timestamp != null ) ? timestamp : "";
|
this.timestamp = ( timestamp != null ) ? timestamp : "";
|
||||||
this.version = version;
|
this.version = version;
|
||||||
|
@ -512,7 +512,7 @@ public class DefaultVersionResolver
|
||||||
|
|
||||||
private final int hashCode;
|
private final int hashCode;
|
||||||
|
|
||||||
public Key( RepositorySystemSession session, VersionRequest request )
|
Key( RepositorySystemSession session, VersionRequest request )
|
||||||
{
|
{
|
||||||
Artifact artifact = request.getArtifact();
|
Artifact artifact = request.getArtifact();
|
||||||
groupId = artifact.getGroupId();
|
groupId = artifact.getGroupId();
|
||||||
|
@ -585,7 +585,7 @@ public class DefaultVersionResolver
|
||||||
|
|
||||||
final Class<?> repoClass;
|
final Class<?> repoClass;
|
||||||
|
|
||||||
public Record( String version, ArtifactRepository repository )
|
Record( String version, ArtifactRepository repository )
|
||||||
{
|
{
|
||||||
this.version = version;
|
this.version = version;
|
||||||
if ( repository != null )
|
if ( repository != null )
|
||||||
|
|
|
@ -42,13 +42,13 @@ final class LocalSnapshotMetadata
|
||||||
|
|
||||||
private final boolean legacyFormat;
|
private final boolean legacyFormat;
|
||||||
|
|
||||||
public LocalSnapshotMetadata( Artifact artifact, boolean legacyFormat )
|
LocalSnapshotMetadata( Artifact artifact, boolean legacyFormat )
|
||||||
{
|
{
|
||||||
super( createMetadata( artifact, legacyFormat ), null );
|
super( createMetadata( artifact, legacyFormat ), null );
|
||||||
this.legacyFormat = legacyFormat;
|
this.legacyFormat = legacyFormat;
|
||||||
}
|
}
|
||||||
|
|
||||||
public LocalSnapshotMetadata( Metadata metadata, File file, boolean legacyFormat )
|
LocalSnapshotMetadata( Metadata metadata, File file, boolean legacyFormat )
|
||||||
{
|
{
|
||||||
super( metadata, file );
|
super( metadata, file );
|
||||||
this.legacyFormat = legacyFormat;
|
this.legacyFormat = legacyFormat;
|
||||||
|
|
|
@ -42,7 +42,7 @@ class LocalSnapshotMetadataGenerator
|
||||||
|
|
||||||
private final boolean legacyFormat;
|
private final boolean legacyFormat;
|
||||||
|
|
||||||
public LocalSnapshotMetadataGenerator( RepositorySystemSession session, InstallRequest request )
|
LocalSnapshotMetadataGenerator( RepositorySystemSession session, InstallRequest request )
|
||||||
{
|
{
|
||||||
legacyFormat = ConfigUtils.getBoolean( session.getConfigProperties(), false, "maven.metadata.legacy" );
|
legacyFormat = ConfigUtils.getBoolean( session.getConfigProperties(), false, "maven.metadata.legacy" );
|
||||||
|
|
||||||
|
|
|
@ -41,7 +41,7 @@ final class RelocatedArtifact
|
||||||
|
|
||||||
private final String version;
|
private final String version;
|
||||||
|
|
||||||
public RelocatedArtifact( Artifact artifact, String groupId, String artifactId, String version )
|
RelocatedArtifact( Artifact artifact, String groupId, String artifactId, String version )
|
||||||
{
|
{
|
||||||
this.artifact = Validate.notNull( artifact, "artifact cannot be null" );
|
this.artifact = Validate.notNull( artifact, "artifact cannot be null" );
|
||||||
// TODO Use StringUtils here
|
// TODO Use StringUtils here
|
||||||
|
|
|
@ -47,7 +47,7 @@ final class RemoteSnapshotMetadata
|
||||||
|
|
||||||
private final Map<String, SnapshotVersion> versions = new LinkedHashMap<>();
|
private final Map<String, SnapshotVersion> versions = new LinkedHashMap<>();
|
||||||
|
|
||||||
public RemoteSnapshotMetadata( Artifact artifact, boolean legacyFormat )
|
RemoteSnapshotMetadata( Artifact artifact, boolean legacyFormat )
|
||||||
{
|
{
|
||||||
super( createRepositoryMetadata( artifact, legacyFormat ), null, legacyFormat );
|
super( createRepositoryMetadata( artifact, legacyFormat ), null, legacyFormat );
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,7 +42,7 @@ class RemoteSnapshotMetadataGenerator
|
||||||
|
|
||||||
private final boolean legacyFormat;
|
private final boolean legacyFormat;
|
||||||
|
|
||||||
public RemoteSnapshotMetadataGenerator( RepositorySystemSession session, DeployRequest request )
|
RemoteSnapshotMetadataGenerator( RepositorySystemSession session, DeployRequest request )
|
||||||
{
|
{
|
||||||
legacyFormat = ConfigUtils.getBoolean( session.getConfigProperties(), false, "maven.metadata.legacy" );
|
legacyFormat = ConfigUtils.getBoolean( session.getConfigProperties(), false, "maven.metadata.legacy" );
|
||||||
|
|
||||||
|
|
|
@ -38,13 +38,13 @@ final class VersionsMetadata
|
||||||
|
|
||||||
private final Artifact artifact;
|
private final Artifact artifact;
|
||||||
|
|
||||||
public VersionsMetadata( Artifact artifact )
|
VersionsMetadata( Artifact artifact )
|
||||||
{
|
{
|
||||||
super( createRepositoryMetadata( artifact ), null );
|
super( createRepositoryMetadata( artifact ), null );
|
||||||
this.artifact = artifact;
|
this.artifact = artifact;
|
||||||
}
|
}
|
||||||
|
|
||||||
public VersionsMetadata( Artifact artifact, File file )
|
VersionsMetadata( Artifact artifact, File file )
|
||||||
{
|
{
|
||||||
super( createRepositoryMetadata( artifact ), file );
|
super( createRepositoryMetadata( artifact ), file );
|
||||||
this.artifact = artifact;
|
this.artifact = artifact;
|
||||||
|
|
|
@ -43,12 +43,12 @@ class VersionsMetadataGenerator
|
||||||
|
|
||||||
private Map<Object, VersionsMetadata> processedVersions;
|
private Map<Object, VersionsMetadata> processedVersions;
|
||||||
|
|
||||||
public VersionsMetadataGenerator( RepositorySystemSession session, InstallRequest request )
|
VersionsMetadataGenerator( RepositorySystemSession session, InstallRequest request )
|
||||||
{
|
{
|
||||||
this( session, request.getMetadata() );
|
this( session, request.getMetadata() );
|
||||||
}
|
}
|
||||||
|
|
||||||
public VersionsMetadataGenerator( RepositorySystemSession session, DeployRequest request )
|
VersionsMetadataGenerator( RepositorySystemSession session, DeployRequest request )
|
||||||
{
|
{
|
||||||
this( session, request.getMetadata() );
|
this( session, request.getMetadata() );
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,7 +37,7 @@ class DefaultSettingsBuildingResult
|
||||||
|
|
||||||
private List<SettingsProblem> problems;
|
private List<SettingsProblem> problems;
|
||||||
|
|
||||||
public DefaultSettingsBuildingResult( Settings effectiveSettings, List<SettingsProblem> problems )
|
DefaultSettingsBuildingResult( Settings effectiveSettings, List<SettingsProblem> problems )
|
||||||
{
|
{
|
||||||
this.effectiveSettings = effectiveSettings;
|
this.effectiveSettings = effectiveSettings;
|
||||||
this.problems = ( problems != null ) ? problems : new ArrayList<SettingsProblem>();
|
this.problems = ( problems != null ) ? problems : new ArrayList<SettingsProblem>();
|
||||||
|
|
|
@ -37,7 +37,7 @@ class DefaultSettingsProblemCollector
|
||||||
|
|
||||||
private String source;
|
private String source;
|
||||||
|
|
||||||
public DefaultSettingsProblemCollector( List<SettingsProblem> problems )
|
DefaultSettingsProblemCollector( List<SettingsProblem> problems )
|
||||||
{
|
{
|
||||||
this.problems = ( problems != null ) ? problems : new ArrayList<SettingsProblem>();
|
this.problems = ( problems != null ) ? problems : new ArrayList<SettingsProblem>();
|
||||||
}
|
}
|
||||||
|
|
|
@ -41,7 +41,7 @@ class DefaultSettingsDecryptionResult
|
||||||
|
|
||||||
private List<SettingsProblem> problems;
|
private List<SettingsProblem> problems;
|
||||||
|
|
||||||
public DefaultSettingsDecryptionResult( List<Server> servers, List<Proxy> proxies, List<SettingsProblem> problems )
|
DefaultSettingsDecryptionResult( List<Server> servers, List<Proxy> proxies, List<SettingsProblem> problems )
|
||||||
{
|
{
|
||||||
this.servers = ( servers != null ) ? servers : new ArrayList<Server>();
|
this.servers = ( servers != null ) ? servers : new ArrayList<Server>();
|
||||||
this.proxies = ( proxies != null ) ? proxies : new ArrayList<Proxy>();
|
this.proxies = ( proxies != null ) ? proxies : new ArrayList<Proxy>();
|
||||||
|
|
Loading…
Reference in New Issue