org.apache.maven.artifact.resolver
Class DebugResolutionListener

java.lang.Object
  extended by org.apache.maven.artifact.resolver.DebugResolutionListener
All Implemented Interfaces:
org.apache.maven.artifact.resolver.ResolutionListener, org.apache.maven.artifact.resolver.ResolutionListenerForDepMgmt

public class DebugResolutionListener
extends java.lang.Object
implements org.apache.maven.artifact.resolver.ResolutionListener, org.apache.maven.artifact.resolver.ResolutionListenerForDepMgmt

Send resolution events to the debug log.

Version:
$Id: DebugResolutionListener.java 568219 2007-08-21 17:59:28Z carlos $
Author:
Brett Porter

Field Summary
 
Fields inherited from interface org.apache.maven.artifact.resolver.ResolutionListener
FINISH_PROCESSING_CHILDREN, INCLUDE_ARTIFACT, MANAGE_ARTIFACT, MANAGE_ARTIFACT_SCOPE, MANAGE_ARTIFACT_VERSION, OMIT_FOR_CYCLE, OMIT_FOR_NEARER, PROCESS_CHILDREN, RESTRICT_RANGE, ROLE, SELECT_VERSION_FROM_RANGE, TEST_ARTIFACT, UPDATE_SCOPE, UPDATE_SCOPE_CURRENT_POM
 
Constructor Summary
DebugResolutionListener(org.codehaus.plexus.logging.Logger logger)
           
 
Method Summary
 void endProcessChildren(org.apache.maven.artifact.Artifact artifact)
           
 void includeArtifact(org.apache.maven.artifact.Artifact artifact)
           
 void manageArtifact(org.apache.maven.artifact.Artifact artifact, org.apache.maven.artifact.Artifact replacement)
          The logic used here used to be a copy of the logic used in the DefaultArtifactCollector, and this method was called right before the actual version/scope changes were done.
 void manageArtifactScope(org.apache.maven.artifact.Artifact artifact, org.apache.maven.artifact.Artifact replacement)
           
 void manageArtifactVersion(org.apache.maven.artifact.Artifact artifact, org.apache.maven.artifact.Artifact replacement)
           
 void omitForCycle(org.apache.maven.artifact.Artifact omitted)
           
 void omitForNearer(org.apache.maven.artifact.Artifact omitted, org.apache.maven.artifact.Artifact kept)
           
 void restrictRange(org.apache.maven.artifact.Artifact artifact, org.apache.maven.artifact.Artifact replacement, org.apache.maven.artifact.versioning.VersionRange newRange)
           
 void selectVersionFromRange(org.apache.maven.artifact.Artifact artifact)
           
 void startProcessChildren(org.apache.maven.artifact.Artifact artifact)
           
 void testArtifact(org.apache.maven.artifact.Artifact node)
           
 void updateScope(org.apache.maven.artifact.Artifact artifact, java.lang.String scope)
           
 void updateScopeCurrentPom(org.apache.maven.artifact.Artifact artifact, java.lang.String ignoredScope)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DebugResolutionListener

public DebugResolutionListener(org.codehaus.plexus.logging.Logger logger)
Method Detail

testArtifact

public void testArtifact(org.apache.maven.artifact.Artifact node)
Specified by:
testArtifact in interface org.apache.maven.artifact.resolver.ResolutionListener

startProcessChildren

public void startProcessChildren(org.apache.maven.artifact.Artifact artifact)
Specified by:
startProcessChildren in interface org.apache.maven.artifact.resolver.ResolutionListener

endProcessChildren

public void endProcessChildren(org.apache.maven.artifact.Artifact artifact)
Specified by:
endProcessChildren in interface org.apache.maven.artifact.resolver.ResolutionListener

includeArtifact

public void includeArtifact(org.apache.maven.artifact.Artifact artifact)
Specified by:
includeArtifact in interface org.apache.maven.artifact.resolver.ResolutionListener

omitForNearer

public void omitForNearer(org.apache.maven.artifact.Artifact omitted,
                          org.apache.maven.artifact.Artifact kept)
Specified by:
omitForNearer in interface org.apache.maven.artifact.resolver.ResolutionListener

omitForCycle

public void omitForCycle(org.apache.maven.artifact.Artifact omitted)
Specified by:
omitForCycle in interface org.apache.maven.artifact.resolver.ResolutionListener

updateScopeCurrentPom

public void updateScopeCurrentPom(org.apache.maven.artifact.Artifact artifact,
                                  java.lang.String ignoredScope)
Specified by:
updateScopeCurrentPom in interface org.apache.maven.artifact.resolver.ResolutionListener

updateScope

public void updateScope(org.apache.maven.artifact.Artifact artifact,
                        java.lang.String scope)
Specified by:
updateScope in interface org.apache.maven.artifact.resolver.ResolutionListener

selectVersionFromRange

public void selectVersionFromRange(org.apache.maven.artifact.Artifact artifact)
Specified by:
selectVersionFromRange in interface org.apache.maven.artifact.resolver.ResolutionListener

restrictRange

public void restrictRange(org.apache.maven.artifact.Artifact artifact,
                          org.apache.maven.artifact.Artifact replacement,
                          org.apache.maven.artifact.versioning.VersionRange newRange)
Specified by:
restrictRange in interface org.apache.maven.artifact.resolver.ResolutionListener

manageArtifact

public void manageArtifact(org.apache.maven.artifact.Artifact artifact,
                           org.apache.maven.artifact.Artifact replacement)
The logic used here used to be a copy of the logic used in the DefaultArtifactCollector, and this method was called right before the actual version/scope changes were done. However, a different set of conditionals (and more information) is needed to be able to determine when and if the version and/or scope changes. See the two added methods, manageArtifactVersion and manageArtifactScope.

Specified by:
manageArtifact in interface org.apache.maven.artifact.resolver.ResolutionListener

manageArtifactVersion

public void manageArtifactVersion(org.apache.maven.artifact.Artifact artifact,
                                  org.apache.maven.artifact.Artifact replacement)
Specified by:
manageArtifactVersion in interface org.apache.maven.artifact.resolver.ResolutionListenerForDepMgmt

manageArtifactScope

public void manageArtifactScope(org.apache.maven.artifact.Artifact artifact,
                                org.apache.maven.artifact.Artifact replacement)
Specified by:
manageArtifactScope in interface org.apache.maven.artifact.resolver.ResolutionListenerForDepMgmt


Copyright © 2001-2011 Apache Software Foundation. All Rights Reserved.