net.sourceforge.openutils.mgnlcriteria.jcr.query.criterion
Class Junction

java.lang.Object
  extended by net.sourceforge.openutils.mgnlcriteria.jcr.query.criterion.Junction
All Implemented Interfaces:
Serializable, Criterion
Direct Known Subclasses:
Conjunction, Disjunction

public class Junction
extends Object
implements Criterion

A sequence of a logical expressions combined by some associative logical operator

Version:
$Id: Junction.java 2927 2010-08-29 15:31:09Z fgiust $
Author:
Federico Grilli
See Also:
Serialized Form

Field Summary
 
Fields inherited from interface net.sourceforge.openutils.mgnlcriteria.jcr.query.criterion.Criterion
ALL_ELEMENTS, ATTRIBUTE_SELECTOR, JCR_PREFIX, JCR_PRIMARYTYPE, JCR_ROOT, NT_BASE, XS_DATETIME_FUNCTION
 
Constructor Summary
protected Junction(String op)
           
 
Method Summary
 Junction add(Criterion criterion)
          Adds a criterion to this Junction
 String getOp()
           
 boolean isEmpty()
           
 String toString()
          
 String toXPathString(Criteria crit)
          Render the XPath fragment
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Junction

protected Junction(String op)
Method Detail

add

public Junction add(Criterion criterion)
Adds a criterion to this Junction

Parameters:
criterion - Criterion to add
Returns:
Junction

getOp

public String getOp()

toXPathString

public String toXPathString(Criteria crit)
                     throws JCRQueryException
Render the XPath fragment

Specified by:
toXPathString in interface Criterion
Parameters:
crit - input criteria
Returns:
converted XPATH expression
Throws:
JCRQueryException - if there is a problem converting the input criteria to a valid xpath expression

toString

public String toString()

Overrides:
toString in class Object

isEmpty

public boolean isEmpty()
Returns:
true if this Criterion contains at least one expression, false otherwise


Copyright © 2009-2010 Openmind. All Rights Reserved.