public abstract class AbstractBanDependencies extends AbstractNonCacheableEnforcerRule
| Modifier and Type | Field and Description |
|---|---|
private org.apache.maven.shared.dependency.graph.DependencyGraphBuilder |
graphBuilder |
private boolean |
searchTransitive
Specify if transitive dependencies should be searched (default) or only look at direct dependencies.
|
| Constructor and Description |
|---|
AbstractBanDependencies() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract java.util.Set<org.apache.maven.artifact.Artifact> |
checkDependencies(java.util.Set<org.apache.maven.artifact.Artifact> dependencies,
org.apache.maven.plugin.logging.Log log)
Checks the set of dependencies against the list of excludes.
|
void |
execute(EnforcerRuleHelper helper)
Execute the rule.
|
private java.util.Set<org.apache.maven.artifact.Artifact> |
getAllDescendants(org.apache.maven.shared.dependency.graph.DependencyNode node) |
protected java.util.Set<org.apache.maven.artifact.Artifact> |
getDependenciesToCheck(org.apache.maven.project.ProjectBuildingRequest projectBuildingRequest) |
protected java.lang.CharSequence |
getErrorMessage(org.apache.maven.artifact.Artifact artifact) |
boolean |
isSearchTransitive()
Checks if is search transitive.
|
void |
setSearchTransitive(boolean theSearchTransitive)
Sets the search transitive.
|
getCacheId, isCacheable, isResultValidgetLevel, getMessage, setLevel, setMessageprivate boolean searchTransitive
private transient org.apache.maven.shared.dependency.graph.DependencyGraphBuilder graphBuilder
public void execute(EnforcerRuleHelper helper) throws EnforcerRuleException
helper - the helperEnforcerRuleException - the enforcer rule exceptionprotected java.lang.CharSequence getErrorMessage(org.apache.maven.artifact.Artifact artifact)
protected java.util.Set<org.apache.maven.artifact.Artifact> getDependenciesToCheck(org.apache.maven.project.ProjectBuildingRequest projectBuildingRequest)
private java.util.Set<org.apache.maven.artifact.Artifact> getAllDescendants(org.apache.maven.shared.dependency.graph.DependencyNode node)
protected abstract java.util.Set<org.apache.maven.artifact.Artifact> checkDependencies(java.util.Set<org.apache.maven.artifact.Artifact> dependencies,
org.apache.maven.plugin.logging.Log log)
throws EnforcerRuleException
dependencies - the dependencieslog - the logEnforcerRuleException - the enforcer rule exceptionpublic boolean isSearchTransitive()
public void setSearchTransitive(boolean theSearchTransitive)
theSearchTransitive - the searchTransitive to set