com.marvelution.maven.components.dependency.resolver.environment.ResolveEnvironment Maven / Gradle / Ivy
/*
* Licensed to Marvelution under one or more contributor license
* agreements. See the NOTICE file distributed with this work
* for additional information regarding copyright ownership.
* Marvelution licenses this file to you under the Apache License,
* Version 2.0 (the "License"); you may not use this file except
* in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package com.marvelution.maven.components.dependency.resolver.environment;
import java.util.List;
import org.apache.maven.artifact.factory.ArtifactFactory;
import org.apache.maven.artifact.repository.ArtifactRepository;
import org.apache.maven.artifact.resolver.ArtifactResolver;
import org.apache.maven.settings.Proxy;
/**
* Resolve Environment
*
* @author Mark Rekveld
*/
public class ResolveEnvironment {
/**
* {@link ArtifactFactory} implementation
*/
private ArtifactFactory artifactFactory;
/**
* {@link ArtifactResolver} implementation
*/
private ArtifactResolver artifactResolver;
/**
* Local {@link ArtifactRepository}
*/
private ArtifactRepository localRepository;
/**
* {@link List} of {@link ArtifactRepository}
*/
private List remoteRepositories;
/**
* Flag for interactive-mode (true
) or batch-mode (false
)
*/
private boolean interactive;
/**
* {@link Proxy} settings
*/
private Proxy proxySettings;
/**
* Gets the {@link ArtifactFactory} implementation
*
* @return the {@link ArtifactFactory} implementation
*/
public ArtifactFactory getArtifactFactory() {
return artifactFactory;
}
/**
* Sets the {@link ArtifactFactory} implementation to use
*
* @param artifactFactory the {@link ArtifactFactory} implementation
*/
public void setArtifactFactory(ArtifactFactory artifactFactory) {
this.artifactFactory = artifactFactory;
}
/**
* Gets the {@link ArtifactResolver} implementation
*
* @return the {@link ArtifactResolver} implementation
*/
public ArtifactResolver getArtifactResolver() {
return artifactResolver;
}
/**
* Sets the {@link ArtifactResolver} implementation to use
*
* @param artifactResolver the {@link ArtifactResolver} implementation
*/
public void setArtifactResolver(ArtifactResolver artifactResolver) {
this.artifactResolver = artifactResolver;
}
/**
* Gets the Local {@link ArtifactRepository}
*
* @return the localRepository
*/
public ArtifactRepository getLocalRepository() {
return localRepository;
}
/**
* Sets the Local {@link ArtifactRepository}
*
* @param localRepository the Local {@link ArtifactRepository}
*/
public void setLocalRepository(ArtifactRepository localRepository) {
this.localRepository = localRepository;
}
/**
* Gets the list of remote ArtifactRepositories
*
* @return {@link List} of {@link ArtifactFactory}
*/
public List getRemoteRepositories() {
return remoteRepositories;
}
/**
* Sets the list of remote ArtifactRepositories
*
* @param remoteRepositories {@link List} of {@link ArtifactFactory}
*/
public void setRemoteRepositories(List remoteRepositories) {
this.remoteRepositories = remoteRepositories;
}
/**
* Gets interactivity state
*
* @return the interactive state true
for interactive, false
for batch-mode
*/
public boolean isInteractive() {
return interactive;
}
/**
* Sets the interactivity state
*
* @param interactive the interactivity state
*/
public void setInteractive(boolean interactive) {
this.interactive = interactive;
}
/**
* Gets the {@link Proxy} settings
*
* @return the {@link Proxy} settings
*/
public Proxy getProxySettings() {
return proxySettings;
}
/**
* Sets the {@link Proxy} settings
*
* @param proxySettings the {@link Proxy} settings
*/
public void setProxySettings(Proxy proxySettings) {
this.proxySettings = proxySettings;
}
}