public class RejectDependenciesStrategy extends Object implements MavenResolutionStrategy
MavenResolutionStrategy implementation where specified MavenDependencys may be selectively rejected| Constructor and Description |
|---|
RejectDependenciesStrategy(boolean rejectTransitives,
String... coordinates)
Bans all dependencies specified by coordinates possibly including all transitive dependencies that might be fetched by
resolving coordinates.
|
RejectDependenciesStrategy(String... coordinates)
Bans all dependencies specified by coordinates including all transitive dependencies that might be fetched by resolving
coordinates.
|
| Modifier and Type | Method and Description |
|---|---|
MavenResolutionFilter[] |
getResolutionFilters()
Returns a
MavenResolutionFilter chain blocking MavenDependencys with coordinates supplied at
instance construction |
TransitiveExclusionPolicy |
getTransitiveExclusionPolicy()
Defines how transitive dependencies are filtered during the resolution request.
|
public RejectDependenciesStrategy(String... coordinates) throws IllegalArgumentException, CoordinateParseException
coordinates - Coordinates to be bannedIllegalArgumentException - If no coordinates are specifiedCoordinateParseException - If coordinates does not follow required formatpublic RejectDependenciesStrategy(boolean rejectTransitives,
String... coordinates)
throws IllegalArgumentException,
CoordinateParseException
rejectTransitives - Flag to allow rejecting transitive dependencies of specified coordinatescoordinates - Coordinates to be bannedIllegalArgumentException - If no coordinates are specifiedCoordinateParseException - If coordinates does not follow required formatpublic MavenResolutionFilter[] getResolutionFilters()
MavenResolutionFilter chain blocking MavenDependencys with coordinates supplied at
instance constructiongetResolutionFilters in interface MavenResolutionStrategyorg.jboss.shrinkwrap.resolver.api.maven.strategy.MavenResolutionStrategy#getPreResolutionFilters()public TransitiveExclusionPolicy getTransitiveExclusionPolicy()
DefaultTransitiveExclusionPolicy.INSTANCE implementation.getTransitiveExclusionPolicy in interface MavenResolutionStrategyTransitiveExclusionPolicy, never nullMavenResolutionStrategy.getTransitiveExclusionPolicy()Copyright © 2014 JBoss by Red Hat. All rights reserved.