Skip navigation links


com.fatwire.assetapi.query
Class ConditionFactory

java.lang.Object
  extended by com.fatwire.assetapi.query.ConditionFactory


public final class ConditionFactory
extends java.lang.Object

A utility for creating Conditions


Constructor Summary
ConditionFactory()
           

 

Method Summary
 Condition createBetweenCondition(java.lang.String attName, java.lang.Object lower, java.lang.Object upper)
          default open between condition
 Condition createBetweenCondition(java.lang.String attName, java.lang.Object lower, java.lang.Object upper, boolean lowerEqual, boolean upperEqual)
          default open between condition
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.util.Date value)
          Create the condition with Date values
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.util.Date value, boolean caseSensitive, boolean immediateOnly)
          Create the condition with Date values
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.lang.Float value)
          Create the condition with Float values
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.lang.Float value, boolean caseSensitive, boolean immediateOnly)
          Create the condition with Float values
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.lang.Integer value)
          Conditions for Integer Values
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.lang.Integer value, boolean caseSensitive, boolean immediateOnly)
          Create the condition with Integer values
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.util.List<java.lang.String> values)
          create a case sensitive String type condition with a list of values as input
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.util.List<java.lang.String> values, boolean containsAll)
          Deprecated. replaced by @see #createCondition(String, OpTypeEnum, List, false, false)
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.util.List<java.lang.String> values, boolean caseSensitive, boolean immediateOnly)
          create a String type condition with a list of values as input
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.lang.Long value)
          Create the condition with Long values
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.lang.Long value, boolean caseSensitive, boolean immediateOnly)
          Create the condition with Long values
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.lang.String value)
          create a case sensitive String condition.
static Condition createCondition(java.lang.String attName, OpTypeEnum opType, java.lang.String value, boolean caseSensitive, boolean immediateOnly)
          create a String type condition with a list of values as input
protected static Condition createConditionExpression(java.lang.String attName, OpTypeEnum opType, java.util.List<java.lang.String> values, boolean caseSensitive, boolean immediateOnly)
          Create the condition with ConditionExpression
protected static Condition createConditionExpression(java.lang.String attName, OpTypeEnum opType, java.util.List<java.lang.String> values, QueryProperties props)
          Create the condition with ConditionExpression
protected static Condition createConditionExpression(java.lang.String attName, OpTypeEnum opType, java.lang.String value, boolean caseSensitive, boolean immediateOnly)
          Create the condition with ConditionExpression

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

ConditionFactory

public ConditionFactory()

Method Detail

createConditionExpression

protected static Condition createConditionExpression(java.lang.String attName,
                                                     OpTypeEnum opType,
                                                     java.lang.String value,
                                                     boolean caseSensitive,
                                                     boolean immediateOnly)
Create the condition with ConditionExpression
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
caseSensitive - true indicates the condition is case sensitive, false indicates the search is case insensitive. When set to false, the value must be in lower case. Note: This parameter is ignored if database is not case sensitive.
immediateOnly - whether the retrieved value is immediateOnly or inherited (for flex asset)
Returns:
Condition the created condition

createConditionExpression

protected static Condition createConditionExpression(java.lang.String attName,
                                                     OpTypeEnum opType,
                                                     java.util.List<java.lang.String> values,
                                                     boolean caseSensitive,
                                                     boolean immediateOnly)
Create the condition with ConditionExpression
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
values - the value for the condition
caseSensitive - true indicates the condition is case sensitive, false indicates the search is case insensitive. When set to false, the value must be in lower case. Note: This parameter is ignored if database is not case sensitive.
immediateOnly - whether the retrieved value is immediateOnly or inherited (for flex asset)
Returns:
Condition the created condition

createConditionExpression

protected static Condition createConditionExpression(java.lang.String attName,
                                                     OpTypeEnum opType,
                                                     java.util.List<java.lang.String> values,
                                                     QueryProperties props)
Create the condition with ConditionExpression
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
values - the value for the condition
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.lang.String value)
create a case sensitive String condition.
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.util.List<java.lang.String> values,
                                        boolean caseSensitive,
                                        boolean immediateOnly)
create a String type condition with a list of values as input
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
values - the value for the condition
caseSensitive - true indicates the condition is case sensitive, false indicates the search is case insensitive. When set to false, the value must be in lower case. Note: This parameter is ignored if database is not case sensitive.
immediateOnly - whether the retrieved value is immediateOnly or inherited (for flex asset)
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.util.List<java.lang.String> values)
create a case sensitive String type condition with a list of values as input
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
values - the value for the condition
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.lang.String value,
                                        boolean caseSensitive,
                                        boolean immediateOnly)
create a String type condition with a list of values as input
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
caseSensitive - true indicates the condition is case sensitive, false indicates the search is case insensitive. When set to false, the value must be in lower case. Note: This parameter is ignored if database is not case sensitive.
immediateOnly - whether the retrieved value is immediateOnly or inherited (for flex asset)
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.lang.Integer value)
Conditions for Integer Values
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.lang.Integer value,
                                        boolean caseSensitive,
                                        boolean immediateOnly)
Create the condition with Integer values
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
caseSensitive - true indicates the condition is case sensitive, false indicates the search is case insensitive. When set to false, the value must be in lower case. Note: This parameter is ignored if database is not case sensitive.
immediateOnly - whether the retrieved value is immediateOnly or inherited (for flex asset)
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.util.Date value)
Create the condition with Date values
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.util.Date value,
                                        boolean caseSensitive,
                                        boolean immediateOnly)
Create the condition with Date values
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
caseSensitive - true indicates the condition is case sensitive, false indicates the search is case insensitive. When set to false, the value must be in lower case. Note: This parameter is ignored if database is not case sensitive.
immediateOnly - whether the retrieved value is immediateOnly or inherited (for flex asset)
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.lang.Float value)
Create the condition with Float values
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.lang.Float value,
                                        boolean caseSensitive,
                                        boolean immediateOnly)
Create the condition with Float values
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
caseSensitive - true indicates the condition is case sensitive, false indicates the search is case insensitive. When set to false, the value must be in lower case. Note: This parameter is ignored if database is not case sensitive.
immediateOnly - whether the retrieved value is immediateOnly or inherited (for flex asset)
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.lang.Long value)
Create the condition with Long values
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.lang.Long value,
                                        boolean caseSensitive,
                                        boolean immediateOnly)
Create the condition with Long values
Parameters:
attName - the attribute name that this condition is restricted on
opType - the operation type of this condition
value - the value for the condition
caseSensitive - true indicates the condition is case sensitive, false indicates the search is case insensitive. When set to false, the value must be in lower case. Note: This parameter is ignored if database is not case sensitive.
immediateOnly - whether the retrieved value is immediateOnly or inherited (for flex asset)
Returns:
condition the created condition

createCondition

public static Condition createCondition(java.lang.String attName,
                                        OpTypeEnum opType,
                                        java.util.List<java.lang.String> values,
                                        boolean containsAll)
Deprecated. replaced by @see #createCondition(String, OpTypeEnum, List, false, false)

createBetweenCondition

public Condition createBetweenCondition(java.lang.String attName,
                                        java.lang.Object lower,
                                        java.lang.Object upper)
                                 throws AssetAccessException
default open between condition
Parameters:
attName - the attribute name
lower - the lower bound
upper - the upper bound
Returns:
created condition
Throws:
AssetAccessException

createBetweenCondition

public Condition createBetweenCondition(java.lang.String attName,
                                        java.lang.Object lower,
                                        java.lang.Object upper,
                                        boolean lowerEqual,
                                        boolean upperEqual)
                                 throws AssetAccessException
default open between condition
Parameters:
attName - the attribute name
lower - the lower bound
upper - the upper bound
lowerEqual - whether the lower bound is open or closed?
upperEqual - whether the upper bound is open or closed
Returns:
created condition
Throws:
AssetAccessException

Skip navigation links


Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.