public class Comparison extends Object implements Constraint
Modifier and Type | Class and Description |
---|---|
static class |
Comparison.Operator
The method with which to evaluate data that is compared to a value.
|
Constructor and Description |
---|
Comparison(Column column,
Comparison.Operator operator,
Serializable value)
Constructor.
|
Comparison(Column column,
Comparison.Operator operator,
Serializable value,
boolean caseSensitive)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
Comparison |
caseInsensitive()
Sets the comparison as case insensitive.
|
Comparison |
caseSensitive()
Sets the comparison as case-sensitive.
|
Comparison |
column(Column column)
Sets the
Column of the comparison. |
static Comparison |
comparison(Column column,
Comparison.Operator operator,
Serializable value)
Creates a
Comparison object with the specified column, operator, and value. |
static Comparison |
comparison(Column column,
Comparison.Operator operator,
Serializable value,
boolean caseSensitive)
Creates a
Comparison object with the specified column, operator, value and indicates whether the comparison is
case-sensitive. |
static Comparison |
equal(Column column,
Serializable value)
Creates a
Comparison object with the specified column and value using the EQUAL
operator. |
static Comparison |
equal(Column column,
Serializable value,
boolean caseSensitive)
Creates a
Comparison object with the specified column and value using the EQUAL
operator, and indicates whether the comparison is case-sensitive. |
Column |
getColumn()
Gets the column for the comparison.
|
Comparison.Operator |
getOperator()
Gets the operator for the comparison.
|
Serializable |
getValue()
Gets the value to compare.
|
static Comparison |
greaterThan(Column column,
Serializable value)
Creates a
Comparison object with the specified column and value using the GREATER_THAN operator. |
static Comparison |
greaterThan(Column column,
Serializable value,
boolean caseSensitive)
Creates a
Comparison object with the specified column and value using the GREATER_THAN operator, and indicates whether the comparison is case-sensitive. |
static Comparison |
greaterThanOrEqual(Column column,
Serializable value)
Creates a
Comparison object with the specified column and value using the
GREATER_THAN_OR_EQUAL operator. |
static Comparison |
greaterThanOrEqual(Column column,
Serializable value,
boolean caseSensitive)
Creates a
Comparison object with the specified column and value using the
GREATER_THAN_OR_EQUAL operator, and indicates whether the comparison
should be case-sensitive. |
boolean |
isCaseSensitive()
Indicates whether the comparison is case-sensitive.
|
static Comparison |
lessThan(Column column,
Serializable value)
Creates a
Comparison object with the specified column and value using the LESS_THAN operator. |
static Comparison |
lessThan(Column column,
Serializable value,
boolean caseSensitive)
Creates a
Comparison object with the specified column and value using the LESS_THAN operator, and indicates whether the comparison is case-sensitive. |
static Comparison |
lessThanOrEqual(Column column,
Serializable value)
Creates a
Comparison object with the specified column and value using the
LESS_THAN_OR_EQUAL operator. |
static Comparison |
lessThanOrEqual(Column column,
Serializable value,
boolean caseSensitive)
Creates a
Comparison object with the specified column and value using the
LESS_THAN_OR_EQUAL operator, and indicates whether the comparison is
case-sensitive. |
static Comparison |
like(Column column,
Serializable value)
Creates a
Comparison object with the specified column and value using the LIKE
operator. |
static Comparison |
like(Column column,
Serializable value,
boolean caseSensitive)
Creates a
Comparison object with the specified column and value using the LIKE
operator, and indicates whether the comparison is case-sensitive. |
static Comparison |
notEqual(Column column,
Serializable value)
Creates a
Comparison object with the specified column and value using the NOT_EQUAL operator. |
static Comparison |
notEqual(Column column,
Serializable value,
boolean caseSensitive)
Creates a
Comparison object with the specified column and value using the NOT_EQUAL operator, and indicates whether the comparison is case-sensitive. |
static Comparison |
notLike(Column column,
Serializable value)
Creates a
Comparison object with the specified column and value using the NOT_LIKE operator. |
static Comparison |
notLike(Column column,
Serializable value,
boolean caseSensitive)
Creates a
Comparison object with the specified column and value using the NOT_LIKE operator, and indicates whether the comparison is case-sensitive. |
Comparison |
operator(Comparison.Operator o)
Sets the
Comparison.Operator of the comparison. |
void |
setCaseSensitive(boolean caseSensitive)
Sets whether the comparison is case-sensitive.
|
void |
setColumn(Column column)
Sets the column for the comparison.
|
void |
setOperator(Comparison.Operator operator)
Sets the operator for the comparison.
|
void |
setValue(Serializable value)
Sets the value for comparison.
|
String |
toString() |
Comparison |
value(Serializable v)
Sets the value of the comparison.
|
public Comparison(Column column, Comparison.Operator operator, Serializable value)
column
- The column for the comparison.operator
- The operator for the comparison.value
- The value to compare.public Comparison(Column column, Comparison.Operator operator, Serializable value, boolean caseSensitive)
column
- The column for the comparison.operator
- The operator for the comparison.value
- The value to compare.caseSensitive
- Indicates whether the comparison is case-sensitive. The default is True
.public Column getColumn()
public void setColumn(Column column)
column
- The column for the comparison.public Comparison.Operator getOperator()
public void setOperator(Comparison.Operator operator)
operator
- The operator for the comparison.public Serializable getValue()
public void setValue(Serializable value)
value
- The value for comparison.public boolean isCaseSensitive()
boolean
value that indicates whether the comparison is case-sensitive.public void setCaseSensitive(boolean caseSensitive)
True
.caseSensitive
- Indicator of whether the comparison is case-sensitive. Default is True
.public Comparison caseSensitive()
public Comparison caseInsensitive()
public Comparison column(Column column)
Column
of the comparison.public Comparison operator(Comparison.Operator o)
Comparison.Operator
of the comparison.public Comparison value(Serializable v)
public static Comparison comparison(Column column, Comparison.Operator operator, Serializable value)
Comparison
object with the specified column, operator, and value.Comparison
object with the specified column, operator, and value.public static Comparison comparison(Column column, Comparison.Operator operator, Serializable value, boolean caseSensitive)
Comparison
object with the specified column, operator, value and indicates whether the comparison is
case-sensitive.Comparison
object with the specified column, operator, value and indicates whether the
comparison is case-sensitive.public static Comparison equal(Column column, Serializable value)
Comparison
object with the specified column and value using the EQUAL
operator.Comparison
object with the specified column and value using the EQUAL
operator.public static Comparison equal(Column column, Serializable value, boolean caseSensitive)
Comparison
object with the specified column and value using the EQUAL
operator, and indicates whether the comparison is case-sensitive.Comparison
object with the specified column and value using the EQUAL
operator, and indicates whether the comparison is case-sensitive.public static Comparison notEqual(Column column, Serializable value)
Comparison
object with the specified column and value using the NOT_EQUAL
operator.Comparison
object with the specified column and value using the
NOT_EQUAL
operator.public static Comparison notEqual(Column column, Serializable value, boolean caseSensitive)
Comparison
object with the specified column and value using the NOT_EQUAL
operator, and indicates whether the comparison is case-sensitive.Comparison
object with the specified column and value using the
NOT_EQUAL
operator, and indicates whether the comparison is case
sensitive.public static Comparison greaterThan(Column column, Serializable value)
Comparison
object with the specified column and value using the GREATER_THAN
operator.Comparison
object with the specified column and value using the
GREATER_THAN
operator.public static Comparison greaterThan(Column column, Serializable value, boolean caseSensitive)
Comparison
object with the specified column and value using the GREATER_THAN
operator, and indicates whether the comparison is case-sensitive.Comparison
object with the specified column and value using the
GREATER_THAN
operator, and indicates whether the comparison is case
sensitive.public static Comparison greaterThanOrEqual(Column column, Serializable value)
Comparison
object with the specified column and value using the
GREATER_THAN_OR_EQUAL
operator.Comparison
object with the specified column and value using the
GREATER_THAN_OR_EQUAL
operator.public static Comparison greaterThanOrEqual(Column column, Serializable value, boolean caseSensitive)
Comparison
object with the specified column and value using the
GREATER_THAN_OR_EQUAL
operator, and indicates whether the comparison
should be case-sensitive.Comparison
object with the specified column and value using the
GREATER_THAN_OR_EQUAL
operator, and indicates whether the
comparison is case-sensitive.public static Comparison lessThan(Column column, Serializable value)
Comparison
object with the specified column and value using the LESS_THAN
operator.Comparison
object with the specified column and value using the
LESS_THAN
operator.public static Comparison lessThan(Column column, Serializable value, boolean caseSensitive)
Comparison
object with the specified column and value using the LESS_THAN
operator, and indicates whether the comparison is case-sensitive.Comparison
object with the specified column and value using the
LESS_THAN
operator, and indicates whether the comparison is case-sensitive.public static Comparison lessThanOrEqual(Column column, Serializable value)
Comparison
object with the specified column and value using the
LESS_THAN_OR_EQUAL
operator.Comparison
object with the specified column and value using the
LESS_THAN_OR_EQUAL
operator.public static Comparison lessThanOrEqual(Column column, Serializable value, boolean caseSensitive)
Comparison
object with the specified column and value using the
LESS_THAN_OR_EQUAL
operator, and indicates whether the comparison is
case-sensitive.Comparison
object with the specified column and value using the
LESS_THAN_OR_EQUAL
operator, and indicates whether the comparison
should be case-sensitive.public static Comparison like(Column column, Serializable value)
Comparison
object with the specified column and value using the LIKE
operator.Comparison
object with the specified column and value using the LIKE
operator.public static Comparison like(Column column, Serializable value, boolean caseSensitive)
Comparison
object with the specified column and value using the LIKE
operator, and indicates whether the comparison is case-sensitive.Comparison
object with the specified column and value using the LIKE
operator, and indicates whether the comparison is case-sensitive.public static Comparison notLike(Column column, Serializable value)
Comparison
object with the specified column and value using the NOT_LIKE
operator.Comparison
object with the specified column and value using the
NOT_LIKE
operator.public static Comparison notLike(Column column, Serializable value, boolean caseSensitive)
Comparison
object with the specified column and value using the NOT_LIKE
operator, and indicates whether the comparison is case-sensitive.Comparison
object with the specified column and value using the
NOT_LIKE
operator, and indicates whether the comparison is case
sensitive.<i>Copyright (c) 2020, SAS Institute Inc., Cary, NC, USA</i>