/** * {@inheritDoc} */ public void manageArtifactVersion( Artifact artifact, Artifact replacement ) { log( "manageArtifactVersion: artifact=" + artifact + ", replacement=" + replacement ); /* * DefaultArtifactCollector calls manageArtifact twice: first with the change; then subsequently with no change. * We ignore the second call when the versions are equal. */ if ( isCurrentNodeIncluded() && !replacement.getVersion().equals( artifact.getVersion() ) ) { /* * Cache management information and apply in includeArtifact, since DefaultArtifactCollector mutates the * artifact and then calls includeArtifact after manageArtifact. */ managedVersions.put( replacement.getId(), artifact.getVersion() ); } }
/** * {@inheritDoc} */ public void manageArtifactVersion( Artifact artifact, Artifact replacement ) { log( "manageArtifactVersion: artifact=" + artifact + ", replacement=" + replacement ); /* * DefaultArtifactCollector calls manageArtifact twice: first with the change; then subsequently with no change. * We ignore the second call when the versions are equal. */ if ( isCurrentNodeIncluded() && !replacement.getVersion().equals( artifact.getVersion() ) ) { /* * Cache management information and apply in includeArtifact, since DefaultArtifactCollector mutates the * artifact and then calls includeArtifact after manageArtifact. */ managedVersions.put( getRangeId( replacement ), artifact.getVersion() ); } }
/** * {@inheritDoc} */ public void omitForCycle( Artifact artifact ) { log( "omitForCycle: artifact=" + artifact ); if ( isCurrentNodeIncluded() ) { DependencyNode node = createNode( artifact ); node.omitForCycle(); } }
/** * {@inheritDoc} */ public void omitForCycle( Artifact artifact ) { log( "omitForCycle: artifact=" + artifact ); if ( isCurrentNodeIncluded() ) { DependencyNode node = createNode( artifact ); node.omitForCycle(); } }
/** * {@inheritDoc} */ public void manageArtifactScope( Artifact artifact, Artifact replacement ) { log( "manageArtifactScope: artifact=" + artifact + ", replacement=" + replacement ); /* * DefaultArtifactCollector calls manageArtifact twice: first with the change; then subsequently with no change. * We ignore the second call when the scopes are equal. */ if ( isCurrentNodeIncluded() && !replacement.getScope().equals( artifact.getScope() ) ) { /* * Cache management information and apply in includeArtifact, since DefaultArtifactCollector mutates the * artifact and then calls includeArtifact after manageArtifact. */ managedScopes.put( getRangeId( replacement ), artifact.getScope() ); } }
/** * {@inheritDoc} */ public void manageArtifactScope( Artifact artifact, Artifact replacement ) { log( "manageArtifactScope: artifact=" + artifact + ", replacement=" + replacement ); /* * DefaultArtifactCollector calls manageArtifact twice: first with the change; then subsequently with no change. * We ignore the second call when the scopes are equal. */ if ( isCurrentNodeIncluded() && !replacement.getScope().equals( artifact.getScope() ) ) { /* * Cache management information and apply in includeArtifact, since DefaultArtifactCollector mutates the * artifact and then calls includeArtifact after manageArtifact. */ managedScopes.put( replacement.getId(), artifact.getScope() ); } }
/** * {@inheritDoc} */ public void includeArtifact( Artifact artifact ) { log( "includeArtifact: artifact=" + artifact ); DependencyNode existingNode = getNode( artifact ); /* * Ignore duplicate includeArtifact calls since omitForNearer can be called prior to includeArtifact on the same * artifact, and we don't wish to include it twice. */ if ( existingNode == null && isCurrentNodeIncluded() ) { DependencyNode node = addNode( artifact ); /* * Add the dependency management information cached in any prior manageArtifact calls, since includeArtifact * is always called after manageArtifact. */ flushDependencyManagement( node ); } }
/** * {@inheritDoc} */ public void includeArtifact( Artifact artifact ) { log( "includeArtifact: artifact=" + artifact ); DependencyNode existingNode = getNode( artifact ); /* * Ignore duplicate includeArtifact calls since omitForNearer can be called prior to includeArtifact on the same * artifact, and we don't wish to include it twice. */ if ( existingNode == null && isCurrentNodeIncluded() ) { DependencyNode node = addNode( artifact ); /* * Add the dependency management information cached in any prior manageArtifact calls, since includeArtifact * is always called after manageArtifact. */ flushDependencyManagement( node ); } }
/** * {@inheritDoc} */ public void selectVersionFromRange( Artifact artifact ) { log( "selectVersionFromRange: artifact=" + artifact ); DependencyNode node = getNode( artifact ); /* * selectVersionFromRange is called before includeArtifact */ if ( node == null && isCurrentNodeIncluded() ) { node = addNode( artifact ); } node.setVersionSelectedFromRange( artifact.getVersionRange() ); node.setAvailableVersions( artifact.getAvailableVersions() ); }
/** * {@inheritDoc} */ public void selectVersionFromRange( Artifact artifact ) { log( "selectVersionFromRange: artifact=" + artifact ); DependencyNode node = getNode( artifact ); /* * selectVersionFromRange is called before includeArtifact */ if ( node == null && isCurrentNodeIncluded() ) { node = addNode( artifact ); } node.setVersionSelectedFromRange( artifact.getVersionRange() ); node.setAvailableVersions( artifact.getAvailableVersions() ); }