|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.maven.plugins.enforcer.AbstractStandardEnforcerRule
org.apache.maven.plugins.enforcer.AbstractNonCacheableEnforcerRule
org.apache.maven.plugins.enforcer.AbstractBanDependencies
org.apache.maven.plugins.enforcer.BannedDependencies
public class BannedDependencies
This rule checks that lists of dependencies are not included.
| Field Summary | |
|---|---|
java.util.List |
excludes
Specify the banned dependencies. |
java.util.List |
includes
Specify the allowed dependencies. |
| Fields inherited from class org.apache.maven.plugins.enforcer.AbstractStandardEnforcerRule |
|---|
message |
| Constructor Summary | |
|---|---|
BannedDependencies()
|
|
| Method Summary | |
|---|---|
protected java.util.Set |
checkDependencies(java.util.Set theDependencies,
org.apache.maven.plugin.logging.Log log)
Checks the set of dependencies against the list of excludes. |
protected boolean |
compareDependency(java.lang.String[] pattern,
org.apache.maven.artifact.Artifact artifact)
Compares the parsed array of substrings against the artifact. |
java.util.List |
getExcludes()
Gets the excludes. |
java.util.List |
getIncludes()
Gets the includes. |
void |
setExcludes(java.util.List theExcludes)
Sets the excludes. |
void |
setIncludes(java.util.List theIncludes)
Sets the includes. |
| Methods inherited from class org.apache.maven.plugins.enforcer.AbstractBanDependencies |
|---|
execute, getDependenciesToCheck, getErrorMessage, getMessage, isSearchTransitive, setMessage, setSearchTransitive |
| Methods inherited from class org.apache.maven.plugins.enforcer.AbstractNonCacheableEnforcerRule |
|---|
getCacheId, isCacheable, isResultValid |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public java.util.List excludes
groupId[:artifactId][:version].
Any of the sections can be a wildcard by using '*' (ie group:*:1.0)
public java.util.List includes
groupId[:artifactId][:version].
Any of the sections can be a wildcard by using '*' (ie group:*:1.0)
| Constructor Detail |
|---|
public BannedDependencies()
| Method Detail |
|---|
protected java.util.Set checkDependencies(java.util.Set theDependencies,
org.apache.maven.plugin.logging.Log log)
throws EnforcerRuleException
AbstractBanDependencies
checkDependencies in class AbstractBanDependenciestheDependencies - the dependencieslog - the log
EnforcerRuleException - the enforcer rule exception
protected boolean compareDependency(java.lang.String[] pattern,
org.apache.maven.artifact.Artifact artifact)
throws EnforcerRuleException
pattern - the array of patternsartifact - the artifact
true if the artifact matches one of the patterns
EnforcerRuleException - the enforcer rule exceptionpublic java.util.List getExcludes()
public void setExcludes(java.util.List theExcludes)
theExcludes - the excludes to setpublic java.util.List getIncludes()
public void setIncludes(java.util.List theIncludes)
theIncludes - the includes to set
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||