com.vgrs.xcode.idna.contextualrule
Class AbstractContextualRule

java.lang.Object
  extended by com.vgrs.xcode.idna.contextualrule.AbstractContextualRule
All Implemented Interfaces:
ContextualRule
Direct Known Subclasses:
AbstractAllCodePointsEvaluated, AbstractAllCodePointsNotEvaluated

public abstract class AbstractContextualRule
extends java.lang.Object
implements ContextualRule

Parent class to be inherited by all class that implement the ContextualRule interface. This class has the ruleName of the contextual rule.

Version:
1.0 May 5, 2010
Author:
nchigurupati

Field Summary
 
Fields inherited from interface com.vgrs.xcode.idna.contextualrule.ContextualRule
ALL_CODE_POINTS_EVALUATED_FALSE, ALL_CODE_POINTS_EVALUATED_TRUE
 
Constructor Summary
AbstractContextualRule()
           
 
Method Summary
 int getCodePointToWhichRuleApplies()
           
 java.lang.String getRuleName()
           
 boolean ruleAppliesToCodepoint(int aCodePoint)
          Checks if the specified code point satisfies the condition for executing the rule
 void setCodePointToWhichRuleApplies(int aCodePoint)
           
 void setRuleName(java.lang.String aRuleName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.vgrs.xcode.idna.contextualrule.ContextualRule
allCodePointsEvaluated, executeRule
 

Constructor Detail

AbstractContextualRule

public AbstractContextualRule()
Method Detail

getRuleName

public java.lang.String getRuleName()
Specified by:
getRuleName in interface ContextualRule
Returns:
the name of the rule specified in ContextualRule.properties

setRuleName

public void setRuleName(java.lang.String aRuleName)
Specified by:
setRuleName in interface ContextualRule
Parameters:
aRuleName - set the name of the rule as specified in ContextualRule.properties

ruleAppliesToCodepoint

public boolean ruleAppliesToCodepoint(int aCodePoint)
Description copied from interface: ContextualRule
Checks if the specified code point satisfies the condition for executing the rule

Specified by:
ruleAppliesToCodepoint in interface ContextualRule
Returns:
boolean indicating if the contextual rule needs to be executed

getCodePointToWhichRuleApplies

public int getCodePointToWhichRuleApplies()
Returns:
the code point associated with this contextual rule

setCodePointToWhichRuleApplies

public void setCodePointToWhichRuleApplies(int aCodePoint)
Parameters:
aCodePoint - set the code point for this contextual rule


Copyright © 2000-2010 VeriSign Inc. All Rights Reserved