public class ERXInQualifier extends ERXKeyValueQualifier implements Cloneable
ERXInQualifier q = new ERXInQualifier("userId", arrayOfNumbers);
Then this qualifier would generate SQL of the form:
USER_ID IN (<array of numbers or data>)Modifier and Type | Class and Description |
---|---|
static class |
ERXInQualifier.InQualifierSQLGenerationSupport
Adds SQL generation support.
|
com.webobjects.eocontrol.EOQualifier.Comparison, com.webobjects.eocontrol.EOQualifier.ComparisonSupport, com.webobjects.eocontrol.EOQualifier.QualifierVariableSubstitutionException
com.webobjects.foundation.NSCoding._BigDecimalSupport, com.webobjects.foundation.NSCoding._BigIntegerSupport, com.webobjects.foundation.NSCoding._BooleanSupport, com.webobjects.foundation.NSCoding._ByteSupport, com.webobjects.foundation.NSCoding._CharacterSupport, com.webobjects.foundation.NSCoding._DateSupport, com.webobjects.foundation.NSCoding._DoubleSupport, com.webobjects.foundation.NSCoding._FloatSupport, com.webobjects.foundation.NSCoding._IntegerSupport, com.webobjects.foundation.NSCoding._LongSupport, com.webobjects.foundation.NSCoding._NumberSupport, com.webobjects.foundation.NSCoding._ShortSupport, com.webobjects.foundation.NSCoding._StringSupport, com.webobjects.foundation.NSCoding.Support
com.webobjects.eocontrol.EOKeyValueArchiving._NullValueSupport, com.webobjects.eocontrol.EOKeyValueArchiving._NumberSupport, com.webobjects.eocontrol.EOKeyValueArchiving._TimestampSupport, com.webobjects.eocontrol.EOKeyValueArchiving.Awaking, com.webobjects.eocontrol.EOKeyValueArchiving.FinishInitialization, com.webobjects.eocontrol.EOKeyValueArchiving.Support
_CLASS, _key, _lowercaseCache, _selector, _value
QualifierOperatorCaseInsensitiveLike, QualifierOperatorContains, QualifierOperatorEqual, QualifierOperatorGreaterThan, QualifierOperatorGreaterThanOrEqualTo, QualifierOperatorLessThan, QualifierOperatorLessThanOrEqualTo, QualifierOperatorLike, QualifierOperatorNotEqual
Constructor and Description |
---|
ERXInQualifier(String key,
NSArray values)
Constructs an in qualifer for a given
attribute name and an array of values.
|
ERXInQualifier(String key,
NSArray values,
int padToSize)
Constructs an in qualifier for a given
attribute name and an array of values.
|
Modifier and Type | Method and Description |
---|---|
Class |
classForCoder() |
Object |
clone()
EOF seems to be wanting to clone qualifiers when
they are inside an and-or qualifier without this
method, ERXInQualifier is cloned into
an EOKeyValueQualifier and the generated SQL is incorrect...
|
static Object |
decodeObject(com.webobjects.foundation.NSCoder coder) |
static Object |
decodeWithKeyValueUnarchiver(com.webobjects.eocontrol.EOKeyValueUnarchiver unarchiver) |
void |
encodeWithCoder(com.webobjects.foundation.NSCoder coder) |
void |
encodeWithKeyValueArchiver(com.webobjects.eocontrol.EOKeyValueArchiver archiver) |
boolean |
evaluateWithObject(Object object)
Tests if the given object's key is in the supplied values
|
String |
toString()
String representation of the in
qualifier.
|
NSArray |
values() |
and, filter, filtered, first, not, one, or, requiredOne
_accept, addQualifierKeysToSet, equals, key, qualifierWithBindings, selector, validateKeysWithRootClassDescription, value
_isEmpty, allQualifierKeys, allQualifierOperators, bindingKeys, filterArrayWithQualifier, filteredArrayWithQualifier, keyPathForBindingKey, operatorSelectorForSelectorNamed, operatorSelectorForString, qualifierToMatchAllValues, qualifierToMatchAnyValue, qualifierWithQualifierFormat, relationalQualifierOperators, stringForOperatorSelector
public ERXInQualifier(String key, NSArray values)
key
- attribute namevalues
- array of valuespublic ERXInQualifier(String key, NSArray values, int padToSize)
key
- attribute namevalues
- array of valuespadToSize
- the size which is expected to be reasonable for this qualifier. If the NSArray values
has more than one element, the padToSize is used to round up the number of elements and pad with nulls.
Doing this reduces the number of unique queries which result from having an arbitrary number of values.
For example, if the padToSize is 8, then we'll either have 1, or 8, or 16, or... bind variables as
compared to 1..., 2..., 3..., 4..., or ....16public String toString()
toString
in class com.webobjects.eocontrol.EOKeyValueQualifier
public NSArray values()
public boolean evaluateWithObject(Object object)
evaluateWithObject
in interface com.webobjects.eocontrol.EOQualifierEvaluation
evaluateWithObject
in class ERXKeyValueQualifier
public Object clone()
clone
in class com.webobjects.eocontrol.EOQualifier
public Class classForCoder()
classForCoder
in interface com.webobjects.foundation.NSCoding
classForCoder
in class com.webobjects.eocontrol.EOKeyValueQualifier
public static Object decodeObject(com.webobjects.foundation.NSCoder coder)
public void encodeWithCoder(com.webobjects.foundation.NSCoder coder)
encodeWithCoder
in interface com.webobjects.foundation.NSCoding
encodeWithCoder
in class com.webobjects.eocontrol.EOKeyValueQualifier
public void encodeWithKeyValueArchiver(com.webobjects.eocontrol.EOKeyValueArchiver archiver)
encodeWithKeyValueArchiver
in interface com.webobjects.eocontrol.EOKeyValueArchiving
encodeWithKeyValueArchiver
in class com.webobjects.eocontrol.EOKeyValueQualifier
public static Object decodeWithKeyValueUnarchiver(com.webobjects.eocontrol.EOKeyValueUnarchiver unarchiver)
Copyright © 2002 – 2020 Project Wonder.