org.apache.ivy.plugins.conflict

Class RegexpConflictManager

public class RegexpConflictManager extends AbstractConflictManager

A ConflictManager that can be used to resolve conflicts based on regular expressions of the revision of the module. The conflict manager is added like this:
    <!-- Match all revisions, but ignore the last dot(.) and the character after it.
        Used to match api changes in out milestones. -->
    <conflict-managers>
        <regexp-cm name="regexp" 
                   regexp="(.*)\..$" ignoreNonMatching="true"/>
    </conflict-managers>
 
The regular expression must contain a capturing group. The group will be used to resolve the conflicts by an String.equals() test. If ignoreNonMatching is false non matching modules will result in an exception. If it is true they will be compaired by their full revision.
Constructor Summary
RegexpConflictManager()
Method Summary
CollectionresolveConflicts(IvyNode parent, Collection conflicts)
voidsetIgnoreNonMatching(boolean ignoreNonMatching)
voidsetRegexp(String regexp)

Constructor Detail

RegexpConflictManager

public RegexpConflictManager()

Method Detail

resolveConflicts

public Collection resolveConflicts(IvyNode parent, Collection conflicts)

setIgnoreNonMatching

public void setIgnoreNonMatching(boolean ignoreNonMatching)

setRegexp

public void setRegexp(String regexp)