|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.commons.digester3.AbstractRulesImpl
public abstract class AbstractRulesImpl
AbstractRuleImpl provides basic services for Rules implementations. Extending this class
should make it easier to create a Rules implementation.
AbstractRuleImpl manages the Digester and namespaceUri properties. If the
subclass overrides registerRule(java.lang.String, org.apache.commons.digester3.Rule) (rather than add(java.lang.String, org.apache.commons.digester3.Rule)), then the Digester and
namespaceURI of the Rule will be set correctly before it is passed to
registerRule. The subclass can then perform whatever it needs to do to register the rule.
| Constructor Summary | |
|---|---|
AbstractRulesImpl()
|
|
| Method Summary | |
|---|---|
void |
add(String pattern,
Rule rule)
Register a new Rule instance matching the specified pattern. |
Digester |
getDigester()
Return the Digester instance with which this Rules instance is associated. |
String |
getNamespaceURI()
Return the namespace URI that will be applied to all subsequently added Rule objects. |
protected abstract void |
registerRule(String pattern,
Rule rule)
Register rule at given pattern. |
void |
setDigester(Digester digester)
Set the Digester instance with which this Rules instance is associated. |
void |
setNamespaceURI(String namespaceURI)
Set the namespace URI that will be applied to all subsequently added Rule objects. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.apache.commons.digester3.Rules |
|---|
clear, match, rules |
| Constructor Detail |
|---|
public AbstractRulesImpl()
| Method Detail |
|---|
public Digester getDigester()
getDigester in interface Rulespublic void setDigester(Digester digester)
setDigester in interface Rulesdigester - The newly associated Digester instancepublic String getNamespaceURI()
Rule objects.
getNamespaceURI in interface RulesRule objects.public void setNamespaceURI(String namespaceURI)
Rule objects.
setNamespaceURI in interface RulesnamespaceURI - Namespace URI that must match on all subsequently added rules, or null for
matching regardless of the current namespace URI
public final void add(String pattern,
Rule rule)
add in interface Rulespattern - Nesting pattern to be matched for this Rulerule - Rule instance to be registered
protected abstract void registerRule(String pattern,
Rule rule)
Rule can
be assumed to have been set properly before this method is called.
pattern - Nesting pattern to be matched for this Rulerule - Rule instance to be registered
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||