org.wfmc.wapi
Class WMFilter

java.lang.Object
  extended byorg.wfmc.wapi.WMFilter
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
OBEFilter

public class WMFilter
extends java.lang.Object
implements java.io.Serializable

See Also:
Serialized Form

Field Summary
static int EQ
           
static int GE
           
static int GT
           
static int LE
           
static int LT
           
static int NE
           
static int NO
           
static int SIMPLE_TYPE
           
static int SQL_TYPE
           
 
Constructor Summary
WMFilter(java.lang.String sqlString)
          Construct a new filter based on an SQL query predicate.
WMFilter(java.lang.String attributeName, int comparison, boolean attributeValue)
          Construct a new filter based on the value of a single attribute.
WMFilter(java.lang.String attributeName, int comparison, java.lang.Boolean attributeValue)
          Construct a new filter based on the value of a single attribute.
WMFilter(java.lang.String attributeName, int comparison, java.util.Date attributeValue)
          Construct a new filter based on the value of a single attribute.
WMFilter(java.lang.String attributeName, int comparison, double attributeValue)
          Construct a new filter based on the value of a single attribute.
WMFilter(java.lang.String attributeName, int comparison, java.lang.Double attributeValue)
          Construct a new filter based on the value of a single attribute.
WMFilter(java.lang.String attributeName, int comparison, int attributeValue)
          Construct a new filter based on the value of a single attribute.
WMFilter(java.lang.String attributeName, int comparison, java.lang.Integer attributeValue)
          Construct a new filter based on the value of a single attribute.
WMFilter(java.lang.String attributeName, int comparison, java.lang.String attributeValue)
          Construct a new filter based on the value of a single attribute.
 
Method Summary
 java.lang.String getAttributeName()
           
 int getAttributeType()
           
 int getComparison()
           
 java.lang.String getFilterString()
           
 int getFilterType()
           
 java.lang.Object getFilterValue()
           
 java.lang.String getSQLComparison()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

SIMPLE_TYPE

public static final int SIMPLE_TYPE
See Also:
Constant Field Values

SQL_TYPE

public static final int SQL_TYPE
See Also:
Constant Field Values

NO

public static final int NO
See Also:
Constant Field Values

LT

public static final int LT
See Also:
Constant Field Values

LE

public static final int LE
See Also:
Constant Field Values

EQ

public static final int EQ
See Also:
Constant Field Values

NE

public static final int NE
See Also:
Constant Field Values

GE

public static final int GE
See Also:
Constant Field Values

GT

public static final int GT
See Also:
Constant Field Values
Constructor Detail

WMFilter

public WMFilter(java.lang.String attributeName,
                int comparison,
                java.lang.Boolean attributeValue)
Construct a new filter based on the value of a single attribute. The attribute must be of type WMAttribute.BOOLEAN_TYPE.

Parameters:
attributeName - The name of the attribute to test.
comparison - The comparison to use, either EQ or NE.
attributeValue - The boolean value to test.

WMFilter

public WMFilter(java.lang.String attributeName,
                int comparison,
                boolean attributeValue)
Construct a new filter based on the value of a single attribute. The attribute must be of type WMAttribute.BOOLEAN_TYPE.

Parameters:
attributeName - The name of the attribute to test.
comparison - The comparison to use, either EQ or NE.
attributeValue - The boolean value to test.

WMFilter

public WMFilter(java.lang.String attributeName,
                int comparison,
                java.util.Date attributeValue)
Construct a new filter based on the value of a single attribute. The attribute must be of type WMAttribute.DATETIME_TYPE.

Parameters:
attributeName - The name of the attribute to test.
comparison - The comparison to use, one of: LT, LE, EQ, NE, GE, GT.
attributeValue - The date value to test.

WMFilter

public WMFilter(java.lang.String attributeName,
                int comparison,
                java.lang.Double attributeValue)
Construct a new filter based on the value of a single attribute. The attribute must be of type WMAttribute.FLOAT_TYPE.

Parameters:
attributeName - The name of the attribute to test.
comparison - The comparison to use, one of: LT, LE, EQ, NE, GE, GT.
attributeValue - The floating point value to test.

WMFilter

public WMFilter(java.lang.String attributeName,
                int comparison,
                double attributeValue)
Construct a new filter based on the value of a single attribute. The attribute must be of type WMAttribute.FLOAT_TYPE.

Parameters:
attributeName - The name of the attribute to test.
comparison - The comparison to use, one of: LT, LE, EQ, NE, GE, GT.
attributeValue - The floating point value to test.

WMFilter

public WMFilter(java.lang.String attributeName,
                int comparison,
                java.lang.Integer attributeValue)
Construct a new filter based on the value of a single attribute. The attribute must be of type WMAttribute.INTEGER_TYPE.

Parameters:
attributeName - The name of the attribute to test.
comparison - The comparison to use, one of: LT, LE, EQ, NE, GE, GT.
attributeValue - The integer value to test.

WMFilter

public WMFilter(java.lang.String attributeName,
                int comparison,
                int attributeValue)
Construct a new filter based on the value of a single attribute. The attribute must be of type WMAttribute.INTEGER_TYPE.

Parameters:
attributeName - The name of the attribute to test.
comparison - The comparison to use, one of: LT, LE, EQ, NE, GE, GT.
attributeValue - The integer value to test.

WMFilter

public WMFilter(java.lang.String attributeName,
                int comparison,
                java.lang.String attributeValue)
Construct a new filter based on the value of a single attribute. The attribute must be of type WMAttribute.STRING_TYPE or WMAttribute.PERFORMER_TYPE.

Parameters:
attributeName - The name of the attribute to test.
comparison - The comparison to use, one of: LT, LE, EQ, NE, GE, GT.
attributeValue - The string value to test.

WMFilter

public WMFilter(java.lang.String sqlString)
Construct a new filter based on an SQL query predicate. The predicate must only reference fields defined for the entity type to be queried.

Parameters:
sqlString - A standard SQL-92 WHERE clause predicate. Joins are not supported.
Method Detail

getAttributeName

public java.lang.String getAttributeName()

getAttributeType

public int getAttributeType()

getComparison

public int getComparison()

getFilterString

public java.lang.String getFilterString()

getFilterType

public int getFilterType()

getFilterValue

public java.lang.Object getFilterValue()

getSQLComparison

public java.lang.String getSQLComparison()

toString

public java.lang.String toString()


SourceForge.net Logo OBE-1.0 Copyright (C) 2002-2006 Adrian Price. All Rights Reserved.