com.samskivert.jdbc.depot.operator
Class Conditionals.FullTextMatch

java.lang.Object
  extended by com.samskivert.jdbc.depot.operator.Conditionals.FullTextMatch
All Implemented Interfaces:
SQLExpression, SQLOperator
Enclosing class:
Conditionals

public static class Conditionals.FullTextMatch
extends Object
implements SQLOperator

An attempt at a dialect-agnostic full-text search condition, such as MySQL's MATCH() and PostgreSQL's @@ TO_TSQUERY(...) abilities.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.samskivert.jdbc.depot.operator.SQLOperator
SQLOperator.BinaryOperator, SQLOperator.MultiOperator
 
Field Summary
protected  String _name
           
protected  Class<? extends PersistentRecord> _pClass
           
protected  String _query
           
 
Constructor Summary
Conditionals.FullTextMatch(Class<? extends PersistentRecord> pClass, String name, String query)
           
 
Method Summary
 void accept(ExpressionVisitor builder)
          Most uses of this class have been implemented with a visitor pattern.
 void addClasses(Collection<Class<? extends PersistentRecord>> classSet)
          Adds all persistent classes that are brought into the SQL context by this clause: FROM clauses, JOINs, UPDATEs, anything that could create a new table abbreviation.
 String getName()
           
 Class<? extends PersistentRecord> getPersistentRecord()
           
 String getQuery()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_pClass

protected Class<? extends PersistentRecord> _pClass

_name

protected String _name

_query

protected String _query
Constructor Detail

Conditionals.FullTextMatch

public Conditionals.FullTextMatch(Class<? extends PersistentRecord> pClass,
                                  String name,
                                  String query)
Method Detail

getPersistentRecord

public Class<? extends PersistentRecord> getPersistentRecord()

getQuery

public String getQuery()

getName

public String getName()

accept

public void accept(ExpressionVisitor builder)
            throws Exception
Description copied from interface: SQLExpression
Most uses of this class have been implemented with a visitor pattern. Create your own ExpressionVisitor and call this method with it.

Specified by:
accept in interface SQLExpression
Throws:
Exception
See Also:
SQLBuilder

addClasses

public void addClasses(Collection<Class<? extends PersistentRecord>> classSet)
Description copied from interface: SQLExpression
Adds all persistent classes that are brought into the SQL context by this clause: FROM clauses, JOINs, UPDATEs, anything that could create a new table abbreviation. This method should recurse into any subordinate state that may in turn bring in new classes so that sub-queries work correctly.

Specified by:
addClasses in interface SQLExpression


Copyright © 2000-2008 Michael Bayne. All Rights Reserved.