org.apache.maven.plugins.enforcer
Class MockEnforcerRule

java.lang.Object
  extended by org.apache.maven.plugins.enforcer.MockEnforcerRule
All Implemented Interfaces:
org.apache.maven.enforcer.rule.api.EnforcerRule

public class MockEnforcerRule
extends Object
implements org.apache.maven.enforcer.rule.api.EnforcerRule

Author:
Brian Fox

Field Summary
 String cacheId
           
 boolean executed
           
 boolean failRule
           
 boolean isCacheable
           
 boolean isResultValid
           
 
Constructor Summary
MockEnforcerRule(boolean fail)
           
MockEnforcerRule(boolean fail, String cacheId, boolean isCacheable, boolean isResultValid)
           
 
Method Summary
 void execute(org.apache.maven.enforcer.rule.api.EnforcerRuleHelper helper)
           
 String getCacheId()
           
 boolean isCacheable()
           
 boolean isFailRule()
           
 boolean isResultValid()
           
 boolean isResultValid(org.apache.maven.enforcer.rule.api.EnforcerRule theCachedRule)
           
 void setCacheable(boolean theIsCacheable)
           
 void setCacheId(String theCacheId)
           
 void setFailRule(boolean theFailRule)
           
 void setResultValid(boolean theIsResultValid)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

failRule

public boolean failRule

cacheId

public String cacheId

isCacheable

public boolean isCacheable

isResultValid

public boolean isResultValid

executed

public boolean executed
Constructor Detail

MockEnforcerRule

public MockEnforcerRule(boolean fail)

MockEnforcerRule

public MockEnforcerRule(boolean fail,
                        String cacheId,
                        boolean isCacheable,
                        boolean isResultValid)
Method Detail

execute

public void execute(org.apache.maven.enforcer.rule.api.EnforcerRuleHelper helper)
             throws org.apache.maven.enforcer.rule.api.EnforcerRuleException
Specified by:
execute in interface org.apache.maven.enforcer.rule.api.EnforcerRule
Throws:
org.apache.maven.enforcer.rule.api.EnforcerRuleException

isFailRule

public boolean isFailRule()
Returns:
the failRule

setFailRule

public void setFailRule(boolean theFailRule)
Parameters:
theFailRule - the failRule to set

isResultValid

public boolean isResultValid()
Returns:
the isResultValid

setResultValid

public void setResultValid(boolean theIsResultValid)
Parameters:
theIsResultValid - the isResultValid to set

setCacheId

public void setCacheId(String theCacheId)
Parameters:
theCacheId - the cacheId to set

setCacheable

public void setCacheable(boolean theIsCacheable)
Parameters:
theIsCacheable - the isCacheable to set

getCacheId

public String getCacheId()
Specified by:
getCacheId in interface org.apache.maven.enforcer.rule.api.EnforcerRule

isCacheable

public boolean isCacheable()
Specified by:
isCacheable in interface org.apache.maven.enforcer.rule.api.EnforcerRule

isResultValid

public boolean isResultValid(org.apache.maven.enforcer.rule.api.EnforcerRule theCachedRule)
Specified by:
isResultValid in interface org.apache.maven.enforcer.rule.api.EnforcerRule


Copyright © 2007-2011 The Apache Software Foundation. All Rights Reserved.