|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--org.writersforge.catalan.transform.rule.QueryRule
Starting point for all Rule implementations which rely on a Bellows query to select which Datum objects to operate on. All QueryRule implementations must expect to operate on zero, one, or many targets, depending on the query results on the particular Datum tree passed into the process() method.
| Constructor Summary | |
QueryRule(java.lang.String query,
java.lang.String propertyName)
Creates a new instance of QueryRule for Datum or Datum property operations. |
|
| Method Summary | |
java.lang.String |
getPropertyName()
Getter for property propertyName, the optional Datum property name inside the content. |
java.lang.String |
getQuery()
Getter for property query, the Bellows query for selecting target content. |
boolean |
isPropertyRule()
Determines if this Rule affects Datum objects or Datum properties. |
protected void |
postProcessTargets(org.writersforge.bellows.Datum[] targets)
Performs any cleanup or deletion on the source Datum objects after all normal processing is finished. |
org.writersforge.bellows.Datum |
process(org.writersforge.bellows.Datum content)
Applies changes to the supplied content. |
protected abstract org.writersforge.bellows.Datum |
processDatum(org.writersforge.bellows.Datum content,
org.writersforge.bellows.Datum target)
Applies changes to Datum objects in the supplied content. |
protected abstract org.writersforge.bellows.Datum |
processProperty(org.writersforge.bellows.Datum content,
org.writersforge.bellows.Datum target)
Applies changes to Datum properties in the supplied content. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public QueryRule(java.lang.String query,
java.lang.String propertyName)
query - the Bellows query to select target contentpropertyName - the name of the Datum property to transform,
or null for Datum transforms| Method Detail |
public java.lang.String getQuery()
public java.lang.String getPropertyName()
public boolean isPropertyRule()
public org.writersforge.bellows.Datum process(org.writersforge.bellows.Datum content)
process in interface Rulecontent - a Datum object to apply the Rule to
protected abstract org.writersforge.bellows.Datum processDatum(org.writersforge.bellows.Datum content,
org.writersforge.bellows.Datum target)
content - the root of the processing treetarget - a Datum object to apply the Rule to
protected abstract org.writersforge.bellows.Datum processProperty(org.writersforge.bellows.Datum content,
org.writersforge.bellows.Datum target)
content - the root of the processing treetarget - a Datum object to apply the Rule to
protected void postProcessTargets(org.writersforge.bellows.Datum[] targets)
targets - an array of individual Datum objects to
post-process
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||