org.melati.poem
Class CachedExists

Package class diagram package CachedExists
java.lang.Object
  extended by org.melati.poem.CachedQuery
      extended by org.melati.poem.CachedCount
          extended by org.melati.poem.CachedExists

public class CachedExists
extends CachedCount

A cached instance of an SQL count > 0 query.


Field Summary
 
Fields inherited from class org.melati.poem.CachedQuery
rows, statements, table
 
Constructor Summary
CachedExists(Table table, String whereClause)
           
CachedExists(Table table, String whereClause, Table[] otherTables)
          Constructor.
 
Method Summary
 boolean exists()
           
 
Methods inherited from class org.melati.poem.CachedCount
count
 
Methods inherited from class org.melati.poem.CachedQuery
compute, extract, getTable, setQuery, statements, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CachedExists

public CachedExists(Table table,
                    String whereClause,
                    Table[] otherTables)
Constructor.

Parameters:
table - the Table we are dealing with
whereClause - SQL snippet
otherTables - Array of other tables referred to in whereClause, if any

CachedExists

public CachedExists(Table table,
                    String whereClause)
Parameters:
table - the Table we are dealing with
whereClause - SQL snippet
Method Detail

exists

public boolean exists()
Returns:
whether any record match the criteria or not


Copyright © 2000-2010 PanEris. All Rights Reserved.