com.trackstudio.app.filter
Class AbstractFilter

java.lang.Object
  extended bycom.trackstudio.app.filter.AbstractFilter
Direct Known Subclasses:
AbstractComparator, MessageFilter, TaskFilter, UserFilter

public abstract class AbstractFilter
extends java.lang.Object


Field Summary
protected static org.apache.commons.logging.Log log
           
 
Constructor Summary
AbstractFilter()
           
 
Method Summary
 int compare(java.lang.Object a, java.lang.Object b)
           
 int compareObject(java.lang.Object value1, java.lang.Object value2)
           
 int compareTreeSet(java.util.TreeSet value1, java.util.TreeSet value2)
           
 boolean passUdf(boolean needAdd, FValue fv, java.util.ArrayList udfToIterate, AbstractBeanWithUdf bean)
           
 boolean testCheckBox(FValue flt, java.lang.String property, boolean databaseValue)
          Test filter condition and CheckBox value set: value "on" unset: no property, no value
 boolean testFloat(FValue flt, java.lang.String property, java.lang.Double databaseValue)
          Returns true when value pass the filter and false otherwise Fvalue coding: <=5: '5' >=5: '_5' <>5: '_ne_5' ==5: '_eq_5'
 boolean testInteger(FValue flt, java.lang.String property, java.lang.Integer databaseValue)
          Returns true when value pass the filter and false otherwise Fvalue coding: <=5: '5' >=5: '_5' <>5: '_ne_5' ==5: '_eq_5'
 boolean testList(FValue flt, java.lang.String property, java.lang.Object databaseValue)
          Test filter condition and List value Fvalue coding: is All: '0' is not All: 0 is new: '1' is not new: '_1' new&processed: '1&2'
 boolean testMultiList(FValue flt, java.lang.String property, java.lang.Object databaseValue)
           
 boolean testString(FValue flt, java.lang.String property, java.lang.String databaseValue)
          Returns true when value pass the filter and false otherwise Fvalue coding: contains TEST: 'TEST' start with TEST: '_TEST' equals TEST: '_eq_TEST' not equals TEST: '_ne_TEST'
 boolean testTimestamp(FValue flt, java.lang.String property, java.util.Calendar databaseValue)
          Test filter condition and Timestamp value
 boolean testURL(FValue flt, java.lang.String property, java.lang.String strValue)
           
 boolean testUser(FValue flt, java.lang.String property, java.lang.String databaseValue, java.lang.String userid)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected static org.apache.commons.logging.Log log
Constructor Detail

AbstractFilter

public AbstractFilter()
Method Detail

passUdf

public boolean passUdf(boolean needAdd,
                       FValue fv,
                       java.util.ArrayList udfToIterate,
                       AbstractBeanWithUdf bean)
                throws GranException
Throws:
GranException

compare

public int compare(java.lang.Object a,
                   java.lang.Object b)

compareTreeSet

public int compareTreeSet(java.util.TreeSet value1,
                          java.util.TreeSet value2)

compareObject

public int compareObject(java.lang.Object value1,
                         java.lang.Object value2)

testInteger

public boolean testInteger(FValue flt,
                           java.lang.String property,
                           java.lang.Integer databaseValue)
Returns true when value pass the filter and false otherwise Fvalue coding: <=5: '5' >=5: '_5' <>5: '_ne_5' ==5: '_eq_5'


testString

public boolean testString(FValue flt,
                          java.lang.String property,
                          java.lang.String databaseValue)
Returns true when value pass the filter and false otherwise Fvalue coding: contains TEST: 'TEST' start with TEST: '_TEST' equals TEST: '_eq_TEST' not equals TEST: '_ne_TEST'


testURL

public boolean testURL(FValue flt,
                       java.lang.String property,
                       java.lang.String strValue)

testFloat

public boolean testFloat(FValue flt,
                         java.lang.String property,
                         java.lang.Double databaseValue)
Returns true when value pass the filter and false otherwise Fvalue coding: <=5: '5' >=5: '_5' <>5: '_ne_5' ==5: '_eq_5'


testCheckBox

public boolean testCheckBox(FValue flt,
                            java.lang.String property,
                            boolean databaseValue)
Test filter condition and CheckBox value set: value "on" unset: no property, no value


testTimestamp

public boolean testTimestamp(FValue flt,
                             java.lang.String property,
                             java.util.Calendar databaseValue)
Test filter condition and Timestamp value


testList

public boolean testList(FValue flt,
                        java.lang.String property,
                        java.lang.Object databaseValue)
Test filter condition and List value Fvalue coding: is All: '0' is not All: 0 is new: '1' is not new: '_1' new&processed: '1&2'


testMultiList

public boolean testMultiList(FValue flt,
                             java.lang.String property,
                             java.lang.Object databaseValue)

testUser

public boolean testUser(FValue flt,
                        java.lang.String property,
                        java.lang.String databaseValue,
                        java.lang.String userid)
                 throws GranException
Throws:
GranException


Copyright © 2002-2005 TrackStudio, Ltd. All Rights Reserved.