Oracle Fusion Middleware Java API Reference for Oracle ADF Model
11g Release 1 (11.1.1.7.0)

E10653-08

oracle.jbo
Class ViewCriteriaItem

java.lang.Object
  extended by java.util.AbstractMap
      extended by oracle.jbo.common.JboAbstractMap
          extended by oracle.jbo.ViewCriteriaItem
All Implemented Interfaces:
java.io.Serializable, java.util.Map, AttributeDef, AttributeHints, ExprValueSupplier, ExprWrappable, GenericHints, Properties, ViewCriteriaComponent, ViewCriteriaItemHints
Direct Known Subclasses:
ViewCriteriaItemCompound, ViewCriteriaItemImpl

public class ViewCriteriaItem
extends JboAbstractMap
implements AttributeDef, java.io.Serializable, ViewCriteriaItemHints, ViewCriteriaComponent, AttributeHints, ExprValueSupplier

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class java.util.AbstractMap
java.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>
 
Nested classes/interfaces inherited from interface oracle.jbo.AttributeHints
AttributeHints.ControlType
 
Nested classes/interfaces inherited from interface java.util.Map
java.util.Map.Entry<K,V>
 
Field Summary
static java.lang.String CARDINALITY
           
static java.lang.String CONJUNCTIONSTR
           
static java.lang.String CONTROL_TYPE
           
static java.lang.String CRITERIA_ITEM
           
static java.lang.String DATATYPE
           
protected static int DEFAULT_CONJ
           
static java.lang.String ESCAPE_WILD_CARD_CHARS
           
static java.lang.String GENERATE_ISNULL_CLAUSE_FOR_BINDVARS
           
static java.lang.String ITEM_NUM
           
static java.lang.String ITEMHOLDER
           
static java.lang.String LABEL
           
static java.lang.String LOV_NAME
           
protected  java.util.ArrayList mAllCompOpers
           
protected  JboCompOper mCompOper
           
protected  java.util.ArrayList mCompOpers
           
protected  java.util.Map mOperatorsAsMap
           
protected  java.util.Hashtable mProperties
           
protected  ViewCriteriaRow mRow
           
protected  java.util.ArrayList<ViewCriteriaItemValue> mValues
           
static java.lang.String NAME
           
static java.lang.String NESTEDVC
           
static java.lang.String OPERATOR
           
static java.lang.String OPERATOR_DESCRIPTION
           
static java.lang.String[] OPERATOR_LIST_ATTR_NAMES
           
static java.lang.String OPERATORS
           
static java.lang.String OPERATORS_MAP
           
static java.lang.String QUOT
           
static java.lang.String REMOVABLE
           
static java.lang.String RENDERED_MODE
           
static java.lang.String REQUIRED
           
static java.lang.String RESET_ORIG_OPER
           
static java.lang.String UPPER_COLUMNS_VALUE
           
static java.lang.String VALIDATE_BINDVARS
           
static java.lang.String VALUE
           
static java.lang.String VALUES
           
static java.lang.String VARIABLE
           
static int VCITEM_COMPOUND
           
static java.lang.String VCITEM_DATATYPE_DATE
           
static java.lang.String VCITEM_DATATYPE_NUMBER
           
static java.lang.String VCITEM_DATATYPE_STRING
           
static int VCITEM_OPTIONAL
           
static java.lang.String VCITEM_OPTIONAL_STR
           
static int VCITEM_REQUIRED
           
static java.lang.String VCITEM_REQUIRED_STR
           
static int VCITEM_SELECTIVELY_REQUIRED
           
static java.lang.String VCITEM_SELECTIVELY_REQUIRED_STR
           
static int VCITEM_SIMPLE
           
static java.lang.String XML_PLURAL_VALUES
           
 
Fields inherited from class oracle.jbo.common.JboAbstractMap
MAP_NULL_VALUE
 
Fields inherited from interface oracle.jbo.AttributeDef
ATTR_ASSOCIATED_ROW, ATTR_ASSOCIATED_ROWITERATOR, ATTR_DYNAMIC, ATTR_ENTITY_DERIVED, ATTR_HIDDEN, ATTR_PERSISTENT, ATTR_ROWSET, ATTR_SQL_DERIVED, ATTR_TRANSIENT, ATTR_VARIABLE, READONLY, UPDATEABLE, UPDATEABLE_WHILE_NEW
 
Fields inherited from interface oracle.jbo.ViewCriteriaItemHints
CRITERIA_ALLOW_MULTIPLE_VALUES, CRITERIA_ALLOW_MULTIPLE_VALUES_DEFAULT, CRITERIA_REMOVABLE, CRITERIA_REMOVABLE_DEFAULT, CRITERIA_RENDERED_MODE, CRITERIA_RENDERED_MODE_ADVANCED, CRITERIA_RENDERED_MODE_BASIC, CRITERIA_RENDERED_MODE_BOTH, CRITERIA_RENDERED_MODE_DEFAULT, CRITERIA_RENDERED_MODE_NEVER
 
Fields inherited from interface oracle.jbo.ViewCriteriaComponent
VC_CONJ_AND, VC_CONJ_NOT, VC_CONJ_OR, VC_CONJ_UNION, VC_UPPER_COL_DEFAULT, VC_UPPER_COL_FALSE, VC_UPPER_COL_TRUE
 
Fields inherited from interface oracle.jbo.AttributeHints
ATTRIBUTE_AUTOSUBMIT, ATTRIBUTE_BINDEDITOR_LABEL, ATTRIBUTE_CTL_CATEGORY, ATTRIBUTE_CTL_DISPLAYHEIGHT, ATTRIBUTE_CTL_DISPLAYWIDTH, ATTRIBUTE_CTL_FIELD_ORDER, ATTRIBUTE_CTL_FORMTYPE, ATTRIBUTE_CTL_TYPE, ATTRIBUTE_DISPLAY_HINT, ATTRIBUTE_DISPLAY_HINT_DISPLAY, ATTRIBUTE_DISPLAY_HINT_HIDE, ATTRIBUTE_FORM_TYPE_DETAIL, ATTRIBUTE_FORM_TYPE_SHORT, ATTRIBUTE_LABEL, ATTRIBUTE_LABEL_PLURAL, ATTRIBUTE_LOVNAME, ATTRIBUTE_TOOLTIP, CTL_CHECK_BOX, CTL_CHOICE_LIST, CTL_COMBO_BOX, CTL_COMBO_BOX_LOV, CTL_DATE, CTL_DEFAULT, CTL_DELIMITEDIDS_CHOICE, CTL_EDIT, CTL_IMAGE, CTL_INPUT_TEXT_LOV, CTL_LIST_BOX, CTL_NUMBER_EDIT, CTL_RADIO_GROUP, CTLTYPE_CHECKBOX, CTLTYPE_COMBO, CTLTYPE_COMBOLOV, CTLTYPE_DATE, CTLTYPE_DEFAULT, CTLTYPE_DELIMITEDIDS_CHOICE, CTLTYPE_EDIT, CTLTYPE_IMAGE, CTLTYPE_LIST, CTLTYPE_LISTBOX, CTLTYPE_LOV, CTLTYPE_NUMEDIT, CTLTYPE_RADIOGRP, CTLTYPE_TOGGLE, FMT_FORMAT, FMT_FORMATTER, HINT_NAME_AUTOSUBMIT, HINT_NAME_CATEGORY, HINT_NAME_CTL_TYPE, HINT_NAME_DESCRIPTION, HINT_NAME_DISPLAY_HEIGHT, HINT_NAME_DISPLAY_HINT, HINT_NAME_DISPLAY_WIDTH, HINT_NAME_FIELD_ORDER, HINT_NAME_FORMAT, HINT_NAME_LABEL, HINT_NAME_LOVNAME, HINT_NAME_MANDATORY, HINT_NAME_MAX_VALUE, HINT_NAME_MIN_LENGTH, HINT_NAME_MIN_VALUE, HINT_NAME_SECRET, HINT_NAME_TIMEZONEID, HINT_NAME_TOOLTIP, HINT_NAME_UPDATEABLE, PNAME_Button, PNAME_ButtonGroup, PNAME_ComboBox, PNAME_ComboBoxLovEdit, PNAME_DYNAMIC_LOV_SUPPORT, PNAME_EnumList, PNAME_LovButton, PNAME_TextField
 
Fields inherited from interface oracle.jbo.GenericHints
PROPERTY_LABEL, PROPERTY_LABEL_PLURAL, PROPERTY_TOOLTIP
 
Constructor Summary
ViewCriteriaItem()
           
ViewCriteriaItem(AttributeDef def, ViewCriteriaRow row)
           
ViewCriteriaItem(java.lang.String attrName, ViewCriteriaRow row)
           
 
Method Summary
 void addCompOper(JboCompOper compOper)
           
 void addItemValue(ViewCriteriaItemValue valueHolder)
           
static boolean areDifferent(java.lang.Object val1, java.lang.Object val2)
           
static java.lang.String convertRequiredFlagToString(int flag)
           
static int convertRequiredStringToFlag(java.lang.String strVal)
          Method to convert the given String to the corresponding value for use in the required flag.
 void copyFrom(ViewCriteriaItem vci)
           
 ViewCriteriaItem createCarrier()
           
protected  ViewCriteriaItemValue createCriteriaItemValue(int index)
           
protected  ViewCriteriaItemValue createCriteriaItemValue(java.lang.Object value, boolean isBindVar, boolean isSqlFragment, int index)
           
 ViewCriteria createViewCriteriaForAccessor()
           
 boolean displayInShortForm(LocaleContext locale)
          Returns true if the attribute is to displayed in the short(summary) form.
 java.lang.Object get(java.lang.Object key)
           
 ViewObject getAccessorVO(ViewObject originVO)
          For an accessor attribute, this method creates a View Object that works for the View Link definition.
protected  void getAllBindVariables(java.util.HashMap<java.lang.String,Variable> map)
           
 AttributeDef getAttributeDef()
           
 byte getAttributeKind()
          Gets the attribute value.
 java.lang.String getBindVarNameFromValue(java.lang.Object value)
          Deprecated. Internal use only.
 java.lang.String getColumnName()
          Gets the name of the database column the attribute represents.
 java.lang.String getColumnNameForQuery()
          Gets the column name to be used in query statement.
 JboCompOper getCompOper()
          Finds the JboCompOper object for the operator set for this VC item.
 JboCompOper getCompOper(java.lang.String operator)
          Finds the JboCompOper object for the given operator.
 java.lang.String[][] getCompOpers()
           
 java.lang.String[][] getCompOpers(int cardinality)
           
 java.lang.String[][] getCompOpers(LocaleContext locale)
          Returns a Map of operators for this attribute.
 int getConjunction()
           
 java.lang.String getConjunctionString()
           
 int getControlType(LocaleContext locale)
          Returns the preferred control type for this attribute
protected static java.lang.String getDataType(int sqlType)
          For supporting the DATATYPE property that returns one of String | Date | Number based on the SQL type of the attribute.
 java.lang.String getDefaultOperator()
           
 int getDisplayHeight(LocaleContext locale)
          Returns the display width for this attribute
 java.lang.String getDisplayHint(LocaleContext locale)
          Retrieves the display hint that dictates whether this attribute should be visible or not.
 int getDisplayWidth(LocaleContext locale)
          Returns the display width for this attribute
 int getElemSQLType()
          Returns the jdbc type of the elements of this attribute.
 java.lang.Class getElemType()
          Returns the element type of the attribute.
 java.lang.Object getExprVarVal(java.lang.String varName)
           
 java.lang.String getFormat(LocaleContext locale)
          returns the format string stored in the ui hints
 java.lang.String getFormattedAttribute(AttributeList attrList, LocaleContext locale)
          Returns a formatted value for this view criteria item when a view criteria row is passed in.
 Formatter getFormatter(LocaleContext locale)
          returns the formatter object stored in the ui hints
 java.lang.String getFormatterClassName(LocaleContext locale)
          Returns the formatter object stored in the ui hints
 java.lang.String getHint(LocaleContext locale, java.lang.String sHintName)
          Return defaulted hint value
 java.lang.String getHintValue(LocaleContext locale, java.lang.String sHintName)
          Return non-defaulted hint value
 int getIndex()
          Gets the index of the attribute in the context of a StoreInfo instance.
 ViewCriteria getItemHolder()
           
 java.lang.Class getJavaType()
          Gets the Java class of the object stored for this attribute definition.
 java.lang.String getLabel(LocaleContext locale)
          Retrieves the label to be used in any attribute prompts
 java.lang.String getLabelPlural(LocaleContext locale)
          Retrives the label_plural text to be used for this attribute
 ListBindingDef getListBindingDef()
           
 java.util.Hashtable getLocalAndResourceProperties()
          Used by the marshaller to get all the properties and resources (on the server side only) that are defined in this view criteria item.
 java.util.ArrayList getLocalCompOpers()
           
protected  LocaleContext getLocale()
           
 java.lang.String getLocaleName(LocaleContext locale, java.lang.String sName)
          function for retrieving the locale name of a hint
 java.util.Hashtable getLocalProperties()
          Return only the properties that have been declared or overriden in the ViewCriteriaItem level.
 java.lang.String getLOVName()
          Gets the name of the LOV (list of values) associated with this attribute definition.
 java.lang.String getName()
          Gets the name of the attribute.
 ViewCriteria getNestedViewCriteria()
          Method for use by the bean datacontrol to retrieve the nested view criteria via the accessor "nestedViewCriteria"
 java.lang.String getOperator()
           
 java.util.Map getOperatorsAsMap()
           
 java.lang.String getOrigOp()
           
 int getPrecision()
          Gets the precision of a numeric or string attribute.
 java.util.Hashtable getProperties()
          Gets the table of properties.
 java.lang.Object getProperty(java.lang.String hintName)
          Retrieves the specified property, if it exists.
 java.lang.Object getProperty(java.lang.String hintName, LocaleContext locale)
           
 java.lang.String getRemovable(LocaleContext locale)
          Retrives the mode hint to be used for this attribute
 java.lang.String getRenderedMode(LocaleContext locale)
          Retrives the mode hint to be used for this attribute
 int getRequired()
           
 java.lang.String getRequiredString()
           
protected  void getResourcesFromBundle(LocaleContext locale, java.util.HashMap map)
          Get all resources from the resource bundle.
 java.lang.String getRootCriteriaRelativeName()
           
 int getScale()
          Get the scale value of a numeric attribute.
 int getSQLType()
          Gets the JDBC type of the attribute.
 StructureDef getStructureDef()
           
 java.lang.String getTooltip(LocaleContext locale)
          Retrives the tooltip text to be used for this attribute
 AttributeHints getUIHelper()
          Returns the user interface hints interface for retrieving hint information such as labels, prompts,...
 byte getUpdateableFlag()
          Tests if an attribute can be modified.
 int getUpperColumnsValue()
           
 java.lang.Object getValue()
          Return the value of this VC item.
 java.lang.Object getValue(int index)
          Return the value at the given index.
 int getValueCardinality()
           
 int getValueCount()
           
 java.lang.Object getValueFromVariableManager(VariableValueManager vMgr)
           
 java.lang.Object getValueFromWhereParams(java.util.HashMap whereParams)
          Deprecated.  
 int getValueMaxCardinality()
           
 int getValueMinCardinality()
           
 java.util.ArrayList<ViewCriteriaItemValue> getValues()
          Return all the values set in this VC item.
protected  java.util.ArrayList<ViewCriteriaItemValue> getValuesInternal()
           
 ViewCriteria getViewCriteria()
           
 ViewCriteriaRow getViewCriteriaRow()
           
protected  boolean hasBindVarValue()
           
 boolean hasData()
           
 boolean hasData(java.util.HashMap whereParams)
          Deprecated. Use hasData(VariableValueManager) instead
 boolean hasData(VariableValueManager vMgr)
           
 boolean hasDataToGenerateQuery(VariableValueManager vMgr)
           
 boolean hasFormatInformation(LocaleContext locale)
          Return true if any format hints have been defined for this attribute.
 boolean hasSameConjunction()
          Checks whether all items under this item has the same conjunction.
 boolean hasWhereClause(boolean checkValue)
           
protected  void initForInOperator(java.lang.Object pluralVals)
           
 boolean isAutoSubmit(LocaleContext locale)
          Returns the autoSubmit value for this vc item
static boolean isBindVariableForTransAttrsOnly(Variable var)
           
 boolean isBindVarValue()
           
 boolean isBindVarValue(int index)
           
 boolean isDiscrColumn()
          Tests if an attribute is a discriminator.
 boolean isEscapeWildCardChars()
           
 boolean isGenerateIsNullClauseForBindVariables()
           
 boolean isMandatory()
          Tests if an attribute does not allow null values.
 boolean isMultiValueType()
          returns true if this item allows multiple values.
static boolean isNull(java.lang.Object val)
           
 boolean isPrimaryKey()
          Tests if an attribute is a Primary Key.
 boolean isQueriable()
          Tests if an attribute is queriable.
 boolean isRemovable()
           
 boolean isSelected()
           
 boolean isSqlFragment()
           
 boolean isSqlFragment(int index)
           
 boolean isUpperColumns()
           
 boolean isValidateBindVariables()
           
static boolean itemHasOnlyNullValues(ViewCriteriaItem vci, ViewCriteria vc, java.lang.String operator, RowSet rowSetForSqlGen, java.util.HashMap bindValsForSqlGen)
           
 ViewCriteriaItemCompound makeCompound()
           
static boolean operatorAllowsMultiValues(java.lang.String oper)
           
 java.lang.Object parseFormattedAttribute(java.lang.String sValue, LocaleContext locale)
          Strips off the formatting from a string and constructs an instance of the attribute's domain using the 'clean' string as a parameter of the contructor.
 java.lang.Object put(java.lang.Object key, java.lang.Object val)
           
 java.lang.Object refreshProperty(java.lang.String hintName)
          Retrieves the specified property, if it exists.
 void removeProperty(java.lang.String hintName)
           
 void setAttributeDef(AttributeDef def)
           
 void setCompOpers(java.util.ArrayList compOpers)
           
 void setConjunction(int conj)
           
 void setConjunctionString(java.lang.String conjStr)
           
 void setEscapeWildCardChars(boolean b)
           
 void setExprVarVal(java.lang.String varName, java.lang.Object val)
           
 void setGenerateIsNullClauseForBindVariables(boolean b)
           
 void setIsBindVarValue(boolean b)
           
 void setIsBindVarValue(int index, boolean b)
           
 void setIsSqlFragment(boolean b)
           
 void setIsSqlFragment(int index, boolean b)
           
 void setName(java.lang.String name)
          Internal: Applications should not use this method.
 void setNameAndPut(java.lang.String newName)
           
 void setOperator(java.lang.String op)
           
 boolean setOperator(java.lang.String op, boolean validate)
          Sets the operator on this view criteria item.
protected  void setOrigOp(java.lang.String op)
           
 void setProperties(java.util.Hashtable properties)
           
 void setProperty(java.lang.String hintName, java.lang.Object hintValue)
           
 void setRemovable(boolean b)
           
 void setRequired(int val)
           
 void setRequiredString(java.lang.String strVal)
           
 void setUpperColumns(boolean b)
           
 void setUpperColumnsValue(int val)
           
 void setValidateBindVariables(boolean b)
           
 void setValue(int index, java.lang.Object val)
           
 void setValue(java.lang.Object val)
           
 void setValueMaxCardinality(int card)
           
 void setValueMinCardinality(int card)
           
 void setValues(java.util.ArrayList<ViewCriteriaItemValue> values)
           
 void suppressChangeNotification()
           
 java.lang.String toString()
           
static boolean useBindVariableInWhereClauseIfNullValue(Variable var)
           
static boolean useBindVariableInWhereClauseIfNullValue(Variable var, java.util.List<ViewCriteriaItem> multiValueItems)
           
 
Methods inherited from class oracle.jbo.common.JboAbstractMap
entrySet, equals, hashCode, internalGet, internalPut, setThrowIfPropertyNotFoundOnGet
 
Methods inherited from class java.util.AbstractMap
clear, clone, containsKey, containsValue, isEmpty, keySet, putAll, remove, size, values
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

QUOT

public static final java.lang.String QUOT
See Also:
Constant Field Values

OPERATOR

public static final java.lang.String OPERATOR
See Also:
Constant Field Values

OPERATORS

public static final java.lang.String OPERATORS
See Also:
Constant Field Values

OPERATORS_MAP

public static final java.lang.String OPERATORS_MAP
See Also:
Constant Field Values

VALUES

public static final java.lang.String VALUES
See Also:
Constant Field Values

VALUE

public static final java.lang.String VALUE
See Also:
Constant Field Values

CARDINALITY

public static final java.lang.String CARDINALITY
See Also:
Constant Field Values

CONJUNCTIONSTR

public static final java.lang.String CONJUNCTIONSTR
See Also:
Constant Field Values

UPPER_COLUMNS_VALUE

public static final java.lang.String UPPER_COLUMNS_VALUE
See Also:
Constant Field Values

ITEMHOLDER

public static final java.lang.String ITEMHOLDER
See Also:
Constant Field Values

NESTEDVC

public static final java.lang.String NESTEDVC
See Also:
Constant Field Values

REMOVABLE

public static final java.lang.String REMOVABLE
See Also:
Constant Field Values

REQUIRED

public static final java.lang.String REQUIRED
See Also:
Constant Field Values

GENERATE_ISNULL_CLAUSE_FOR_BINDVARS

public static final java.lang.String GENERATE_ISNULL_CLAUSE_FOR_BINDVARS
See Also:
Constant Field Values

ESCAPE_WILD_CARD_CHARS

public static final java.lang.String ESCAPE_WILD_CARD_CHARS
See Also:
Constant Field Values

VALIDATE_BINDVARS

public static final java.lang.String VALIDATE_BINDVARS
See Also:
Constant Field Values

NAME

public static final java.lang.String NAME
See Also:
Constant Field Values

ITEM_NUM

public static final java.lang.String ITEM_NUM
See Also:
Constant Field Values

LABEL

public static final java.lang.String LABEL
See Also:
Constant Field Values

RENDERED_MODE

public static final java.lang.String RENDERED_MODE
See Also:
Constant Field Values

CONTROL_TYPE

public static final java.lang.String CONTROL_TYPE
See Also:
Constant Field Values

OPERATOR_DESCRIPTION

public static final java.lang.String OPERATOR_DESCRIPTION
See Also:
Constant Field Values

OPERATOR_LIST_ATTR_NAMES

public static final java.lang.String[] OPERATOR_LIST_ATTR_NAMES

LOV_NAME

public static final java.lang.String LOV_NAME
See Also:
Constant Field Values

DATATYPE

public static final java.lang.String DATATYPE
See Also:
Constant Field Values

VARIABLE

public static final java.lang.String VARIABLE
See Also:
Constant Field Values

CRITERIA_ITEM

public static final java.lang.String CRITERIA_ITEM
See Also:
Constant Field Values

VCITEM_SIMPLE

public static final int VCITEM_SIMPLE
See Also:
Constant Field Values

VCITEM_COMPOUND

public static final int VCITEM_COMPOUND
See Also:
Constant Field Values

VCITEM_REQUIRED

public static final int VCITEM_REQUIRED
See Also:
Constant Field Values

VCITEM_SELECTIVELY_REQUIRED

public static final int VCITEM_SELECTIVELY_REQUIRED
See Also:
Constant Field Values

VCITEM_OPTIONAL

public static final int VCITEM_OPTIONAL
See Also:
Constant Field Values

VCITEM_REQUIRED_STR

public static final java.lang.String VCITEM_REQUIRED_STR
See Also:
Constant Field Values

VCITEM_SELECTIVELY_REQUIRED_STR

public static final java.lang.String VCITEM_SELECTIVELY_REQUIRED_STR
See Also:
Constant Field Values

VCITEM_OPTIONAL_STR

public static final java.lang.String VCITEM_OPTIONAL_STR
See Also:
Constant Field Values

VCITEM_DATATYPE_STRING

public static final java.lang.String VCITEM_DATATYPE_STRING
See Also:
Constant Field Values

VCITEM_DATATYPE_DATE

public static final java.lang.String VCITEM_DATATYPE_DATE
See Also:
Constant Field Values

VCITEM_DATATYPE_NUMBER

public static final java.lang.String VCITEM_DATATYPE_NUMBER
See Also:
Constant Field Values

XML_PLURAL_VALUES

public static final java.lang.String XML_PLURAL_VALUES
See Also:
Constant Field Values

RESET_ORIG_OPER

public static final java.lang.String RESET_ORIG_OPER
See Also:
Constant Field Values

DEFAULT_CONJ

protected static final int DEFAULT_CONJ
See Also:
Constant Field Values

mRow

protected transient ViewCriteriaRow mRow

mValues

protected transient java.util.ArrayList<ViewCriteriaItemValue> mValues

mProperties

protected transient java.util.Hashtable mProperties

mCompOper

protected transient JboCompOper mCompOper

mAllCompOpers

protected transient java.util.ArrayList mAllCompOpers

mOperatorsAsMap

protected transient java.util.Map mOperatorsAsMap

mCompOpers

protected transient java.util.ArrayList mCompOpers
Constructor Detail

ViewCriteriaItem

public ViewCriteriaItem()

ViewCriteriaItem

public ViewCriteriaItem(java.lang.String attrName,
                        ViewCriteriaRow row)

ViewCriteriaItem

public ViewCriteriaItem(AttributeDef def,
                        ViewCriteriaRow row)
Method Detail

suppressChangeNotification

public void suppressChangeNotification()

getValueCardinality

public int getValueCardinality()

getValueMinCardinality

public int getValueMinCardinality()

operatorAllowsMultiValues

public static final boolean operatorAllowsMultiValues(java.lang.String oper)

isMultiValueType

public boolean isMultiValueType()
returns true if this item allows multiple values.


getValueMaxCardinality

public int getValueMaxCardinality()

initForInOperator

protected void initForInOperator(java.lang.Object pluralVals)
For internal use only. Application developers should not use this

setValueMaxCardinality

public void setValueMaxCardinality(int card)
For internal use only. Application developers should not use this
*** For internal framework use in ADS only ***

setValueMinCardinality

public void setValueMinCardinality(int card)
For internal use only. Application developers should not use this
*** For internal framework use in ADS only ***

get

public java.lang.Object get(java.lang.Object key)
Specified by:
get in interface java.util.Map
Overrides:
get in class JboAbstractMap

put

public java.lang.Object put(java.lang.Object key,
                            java.lang.Object val)
Specified by:
put in interface java.util.Map
Overrides:
put in class JboAbstractMap

createViewCriteriaForAccessor

public ViewCriteria createViewCriteriaForAccessor()

setAttributeDef

public void setAttributeDef(AttributeDef def)

getOperator

public java.lang.String getOperator()

getDefaultOperator

public java.lang.String getDefaultOperator()

getDataType

protected static java.lang.String getDataType(int sqlType)
For supporting the DATATYPE property that returns one of String | Date | Number based on the SQL type of the attribute.

Returns:
"String", "Date", or "Number" based on the SQL type.

getCompOper

public JboCompOper getCompOper()
Finds the JboCompOper object for the operator set for this VC item.


getCompOper

public JboCompOper getCompOper(java.lang.String operator)
Finds the JboCompOper object for the given operator.

Parameters:
operator - the operator whose JboCompOper is to be returned.
Returns:
the JboCompOper object for the given operator, or null if none can be found.

setOrigOp

protected void setOrigOp(java.lang.String op)

getOrigOp

public java.lang.String getOrigOp()

setOperator

public void setOperator(java.lang.String op)

setOperator

public boolean setOperator(java.lang.String op,
                           boolean validate)
Sets the operator on this view criteria item. If validate is true and the operator is not valid, the operator will not be set on this view criteria item.

Parameters:
op - the operator
validate - if true, ensure the operator is valid before setting
Returns:
true if the operator is set, false if the operator is invalid and is not set.

addCompOper

public void addCompOper(JboCompOper compOper)

getLocalCompOpers

public java.util.ArrayList getLocalCompOpers()

setCompOpers

public void setCompOpers(java.util.ArrayList compOpers)

getCompOpers

public java.lang.String[][] getCompOpers()

getCompOpers

public java.lang.String[][] getCompOpers(int cardinality)

getOperatorsAsMap

public java.util.Map getOperatorsAsMap()

getLocale

protected LocaleContext getLocale()

getValue

public java.lang.Object getValue()
Return the value of this VC item. In cases where there are multiple values in this VC item, this method return the first value. To retrieve the other values for a multi-value VC item, use getValues or getValue(int index) instead.

Returns:
The value of this VC item.

getValue

public java.lang.Object getValue(int index)
Return the value at the given index. Note that this method does not check for value cardinality, and it is possible to return a value for a given index of 1 (second value) even if the cardinality for the VC item operator is 1, if it was previously set.

Parameters:
index - The index of the value in the list of values to be returned.
Returns:
The value at the given index. This method returns null if the index given is out of bound.

getValueCount

public int getValueCount()

getValues

public java.util.ArrayList<ViewCriteriaItemValue> getValues()
Return all the values set in this VC item.

Returns:
A List containing all the values set for this VC item.

getValuesInternal

protected java.util.ArrayList<ViewCriteriaItemValue> getValuesInternal()

setValues

public void setValues(java.util.ArrayList<ViewCriteriaItemValue> values)

setValue

public void setValue(java.lang.Object val)

setValue

public void setValue(int index,
                     java.lang.Object val)

addItemValue

public void addItemValue(ViewCriteriaItemValue valueHolder)

createCriteriaItemValue

protected ViewCriteriaItemValue createCriteriaItemValue(int index)

createCriteriaItemValue

protected ViewCriteriaItemValue createCriteriaItemValue(java.lang.Object value,
                                                        boolean isBindVar,
                                                        boolean isSqlFragment,
                                                        int index)

getConjunction

public int getConjunction()
Specified by:
getConjunction in interface ViewCriteriaComponent

setConjunction

public void setConjunction(int conj)
Specified by:
setConjunction in interface ViewCriteriaComponent

getConjunctionString

public java.lang.String getConjunctionString()

isUpperColumns

public boolean isUpperColumns()
Specified by:
isUpperColumns in interface ViewCriteriaComponent

setUpperColumns

public void setUpperColumns(boolean b)
Specified by:
setUpperColumns in interface ViewCriteriaComponent

getUpperColumnsValue

public int getUpperColumnsValue()
Specified by:
getUpperColumnsValue in interface ViewCriteriaComponent

setUpperColumnsValue

public void setUpperColumnsValue(int val)

useBindVariableInWhereClauseIfNullValue

public static boolean useBindVariableInWhereClauseIfNullValue(Variable var)

useBindVariableInWhereClauseIfNullValue

public static boolean useBindVariableInWhereClauseIfNullValue(Variable var,
                                                              java.util.List<ViewCriteriaItem> multiValueItems)

itemHasOnlyNullValues

public static boolean itemHasOnlyNullValues(ViewCriteriaItem vci,
                                            ViewCriteria vc,
                                            java.lang.String operator,
                                            RowSet rowSetForSqlGen,
                                            java.util.HashMap bindValsForSqlGen)

isBindVariableForTransAttrsOnly

public static boolean isBindVariableForTransAttrsOnly(Variable var)

convertRequiredFlagToString

public static java.lang.String convertRequiredFlagToString(int flag)

convertRequiredStringToFlag

public static int convertRequiredStringToFlag(java.lang.String strVal)
Method to convert the given String to the corresponding value for use in the required flag.

Parameters:
strVal - The String representation of the value in the required field
Returns:
an integer corresponding to the string passed that is used as the required flag, or -1 if the string does not correspond to a valid value.

getRequiredString

public java.lang.String getRequiredString()

getRequired

public int getRequired()

setRequiredString

public void setRequiredString(java.lang.String strVal)

setRequired

public void setRequired(int val)

setConjunctionString

public void setConjunctionString(java.lang.String conjStr)

isBindVarValue

public boolean isBindVarValue()

isBindVarValue

public boolean isBindVarValue(int index)

setIsBindVarValue

public void setIsBindVarValue(boolean b)

setIsBindVarValue

public void setIsBindVarValue(int index,
                              boolean b)

isSqlFragment

public boolean isSqlFragment()

isSqlFragment

public boolean isSqlFragment(int index)

setIsSqlFragment

public void setIsSqlFragment(boolean b)

setIsSqlFragment

public void setIsSqlFragment(int index,
                             boolean b)

isRemovable

public boolean isRemovable()

setRemovable

public void setRemovable(boolean b)

isValidateBindVariables

public boolean isValidateBindVariables()

setValidateBindVariables

public void setValidateBindVariables(boolean b)

isGenerateIsNullClauseForBindVariables

public boolean isGenerateIsNullClauseForBindVariables()

setGenerateIsNullClauseForBindVariables

public void setGenerateIsNullClauseForBindVariables(boolean b)

isEscapeWildCardChars

public boolean isEscapeWildCardChars()

setEscapeWildCardChars

public void setEscapeWildCardChars(boolean b)

getRootCriteriaRelativeName

public java.lang.String getRootCriteriaRelativeName()

getViewCriteria

public ViewCriteria getViewCriteria()

getViewCriteriaRow

public ViewCriteriaRow getViewCriteriaRow()

getStructureDef

public StructureDef getStructureDef()

getAttributeDef

public AttributeDef getAttributeDef()

getAttributeKind

public byte getAttributeKind()
Description copied from interface: AttributeDef
Gets the attribute value.

Specified by:
getAttributeKind in interface AttributeDef
Returns:
one of the ATTR constants defined for this class.

getName

public java.lang.String getName()
Description copied from interface: AttributeDef
Gets the name of the attribute.

Specified by:
getName in interface AttributeDef
Returns:
the name of the attribute.

setName

public void setName(java.lang.String name)
Internal: Applications should not use this method.


setNameAndPut

public void setNameAndPut(java.lang.String newName)

getColumnName

public java.lang.String getColumnName()
Description copied from interface: AttributeDef
Gets the name of the database column the attribute represents.

Specified by:
getColumnName in interface AttributeDef
Returns:
the name of the column.

getColumnNameForQuery

public java.lang.String getColumnNameForQuery()
Description copied from interface: AttributeDef
Gets the column name to be used in query statement. If the VO involves multiple entity usages, the column name may have to be qualified with the table alias for the appropriate entity. If the query statement is a full query ("expert mode"), the where-clause in the outer select must use column alias used for the inner select. This method takes care of all this and returns the right column name to be used for a query statement.

Specified by:
getColumnNameForQuery in interface AttributeDef
Returns:
the column name to be used in query.

getIndex

public int getIndex()
Description copied from interface: AttributeDef
Gets the index of the attribute in the context of a StoreInfo instance.

Specified by:
getIndex in interface AttributeDef
Returns:
the index of the attribute row's definition object.

getJavaType

public java.lang.Class getJavaType()
Description copied from interface: AttributeDef
Gets the Java class of the object stored for this attribute definition.

Specified by:
getJavaType in interface AttributeDef
Returns:
the class of the attribute.

getSQLType

public int getSQLType()
Description copied from interface: AttributeDef
Gets the JDBC type of the attribute.

Specified by:
getSQLType in interface AttributeDef
Returns:
the JDBC type.
See Also:
Types

getScale

public int getScale()
Description copied from interface: AttributeDef
Get the scale value of a numeric attribute.

Specified by:
getScale in interface AttributeDef
Returns:
the scale value for this attribute, if applicable.

getPrecision

public int getPrecision()
Description copied from interface: AttributeDef
Gets the precision of a numeric or string attribute.

'Precision' for a string is the maximum length.

Specified by:
getPrecision in interface AttributeDef
Returns:
the precision value for this attribute.

isDiscrColumn

public boolean isDiscrColumn()
Description copied from interface: AttributeDef
Tests if an attribute is a discriminator. Discriminating attributes are those whose values determine the (sub)type representing the entity.

Specified by:
isDiscrColumn in interface AttributeDef
Returns:
true if this is a Discriminator Column; false otherwise.

isSelected

public boolean isSelected()
Specified by:
isSelected in interface AttributeDef

isQueriable

public boolean isQueriable()
Description copied from interface: AttributeDef
Tests if an attribute is queriable.

Queriable attributes are those that may have a filter condition for the WHERE clause If this method returns false, the attribute will not be used in constructing the WHERE clause of SQL statements to fetch data.

Specified by:
isQueriable in interface AttributeDef
Returns:
true if this attribute is queriable.

getUpdateableFlag

public byte getUpdateableFlag()
Description copied from interface: AttributeDef
Tests if an attribute can be modified.

Specified by:
getUpdateableFlag in interface AttributeDef
Returns:
READONLY, UPDATEABLE, or UPDATEABLE_WHILE_NEW.

isPrimaryKey

public boolean isPrimaryKey()
Description copied from interface: AttributeDef
Tests if an attribute is a Primary Key.

Specified by:
isPrimaryKey in interface AttributeDef
Returns:
true if this is either a Primary Key attribute or part of the attributes that constitute the Primary Key for a given row.

getLOVName

public java.lang.String getLOVName()
Description copied from interface: AttributeDef
Gets the name of the LOV (list of values) associated with this attribute definition.

Specified by:
getLOVName in interface AttributeDef
Returns:
the name of the LOV (may be null)

getListBindingDef

public ListBindingDef getListBindingDef()
Specified by:
getListBindingDef in interface AttributeDef

isMandatory

public boolean isMandatory()
Description copied from interface: AttributeDef
Tests if an attribute does not allow null values.

Specified by:
isMandatory in interface AttributeDef
Returns:
true if this attribute cannot store a null value

getUIHelper

public AttributeHints getUIHelper()
Description copied from interface: AttributeDef
Returns the user interface hints interface for retrieving hint information such as labels, prompts,...

Specified by:
getUIHelper in interface AttributeDef
See Also:
AttributeHints

getElemType

public java.lang.Class getElemType()
Description copied from interface: AttributeDef
Returns the element type of the attribute.

For VARRAYs, this method returns the class name of the elements that are in the VARRAY.

Element type is relevant only if the attribute is an array attribute.

Specified by:
getElemType in interface AttributeDef
Returns:
the attribute's element class, or null if the attribute is not an array attribute.

getElemSQLType

public int getElemSQLType()
Description copied from interface: AttributeDef
Returns the jdbc type of the elements of this attribute.

For VARRAYs, this method returns the jdbc type of the elements that are in the VARRAY.

Element type is relevant only if the attribute is an array attribute.

Specified by:
getElemSQLType in interface AttributeDef
Returns:
the jdbc type (java.sql.Types.*) of this attribute's elements, or java.sql.Types.NULL if this attribute is not an array attribute.

getAccessorVO

public ViewObject getAccessorVO(ViewObject originVO)
Description copied from interface: AttributeDef
For an accessor attribute, this method creates a View Object that works for the View Link definition.

Specified by:
getAccessorVO in interface AttributeDef
Parameters:
originVO - the View Object that owns the accessor
Returns:
a ViewObject instance.

getProperty

public java.lang.Object getProperty(java.lang.String hintName)
Description copied from interface: Properties
Retrieves the specified property, if it exists.

Specified by:
getProperty in interface Properties
Parameters:
hintName - Property name.
Returns:
the value of the property, if any, otherwise null.

getProperty

public java.lang.Object getProperty(java.lang.String hintName,
                                    LocaleContext locale)
Specified by:
getProperty in interface Properties

refreshProperty

public java.lang.Object refreshProperty(java.lang.String hintName)
Description copied from interface: Properties
Retrieves the specified property, if it exists. If the application running in a 3 tier environment, it retrieves the property from the middle-tier server, refreshing the value on the client side. If the application is running in a 2 tier environment, it is equivalent to getProperty.

Specified by:
refreshProperty in interface Properties
Parameters:
hintName - Property name.
Returns:
the value of the property, if any, otherwise null.

getLocalProperties

public java.util.Hashtable getLocalProperties()
Return only the properties that have been declared or overriden in the ViewCriteriaItem level. This method does not return the properties definied in the associated AttributeDef.

Returns:
properties defined in this ViewCriteriaItem.

getLocalAndResourceProperties

public java.util.Hashtable getLocalAndResourceProperties()
Used by the marshaller to get all the properties and resources (on the server side only) that are defined in this view criteria item. This method is overriden by ViewCriteriaItemImpl to return the resource properties as well.

Returns:
A table containing the properties

getProperties

public java.util.Hashtable getProperties()
Description copied from interface: Properties
Gets the table of properties.

Specified by:
getProperties in interface Properties
Returns:
a hashtable of properties.

setProperty

public void setProperty(java.lang.String hintName,
                        java.lang.Object hintValue)

removeProperty

public void removeProperty(java.lang.String hintName)

setProperties

public void setProperties(java.util.Hashtable properties)

getBindVarNameFromValue

@Deprecated
public java.lang.String getBindVarNameFromValue(java.lang.Object value)
Deprecated. Internal use only.

For internal use only. Application developers should not use this
Called by JboVCItemRequiredValidator to check bind var value.

getAllBindVariables

protected void getAllBindVariables(java.util.HashMap<java.lang.String,Variable> map)

makeCompound

public ViewCriteriaItemCompound makeCompound()

copyFrom

public void copyFrom(ViewCriteriaItem vci)

toString

public java.lang.String toString()
Overrides:
toString in class java.util.AbstractMap

hasData

public boolean hasData()

hasData

public boolean hasData(java.util.HashMap whereParams)
Deprecated. Use hasData(VariableValueManager) instead


hasData

public boolean hasData(VariableValueManager vMgr)

hasDataToGenerateQuery

public boolean hasDataToGenerateQuery(VariableValueManager vMgr)

hasWhereClause

public boolean hasWhereClause(boolean checkValue)

getValueFromWhereParams

public java.lang.Object getValueFromWhereParams(java.util.HashMap whereParams)
Deprecated. 


getValueFromVariableManager

public java.lang.Object getValueFromVariableManager(VariableValueManager vMgr)

hasBindVarValue

protected boolean hasBindVarValue()
Returns:
true if any of the values in this view criteria item is a bind variable, false otherwise.

createCarrier

public ViewCriteriaItem createCarrier()

areDifferent

public static boolean areDifferent(java.lang.Object val1,
                                   java.lang.Object val2)

isNull

public static boolean isNull(java.lang.Object val)

getNestedViewCriteria

public ViewCriteria getNestedViewCriteria()
Method for use by the bean datacontrol to retrieve the nested view criteria via the accessor "nestedViewCriteria"

Returns:
The nested view criteria if the value of this item is a ViewCriteria, or null otherwise.

getItemHolder

public ViewCriteria getItemHolder()

hasSameConjunction

public boolean hasSameConjunction()
Checks whether all items under this item has the same conjunction.

Returns:
true if all items under this item has the same conjunction. False otherwise.

getResourcesFromBundle

protected void getResourcesFromBundle(LocaleContext locale,
                                      java.util.HashMap map)
Get all resources from the resource bundle. Adopted from NamedObjectImpl.getResourcesFromBundle

Parameters:
locale - locale of the resources to be retrieved.
map - the retrieved resources will be added to the map.

getRemovable

public final java.lang.String getRemovable(LocaleContext locale)
Retrives the mode hint to be used for this attribute

Specified by:
getRemovable in interface ViewCriteriaItemHints

getRenderedMode

public final java.lang.String getRenderedMode(LocaleContext locale)
Retrives the mode hint to be used for this attribute

Specified by:
getRenderedMode in interface ViewCriteriaItemHints

getLocaleName

public java.lang.String getLocaleName(LocaleContext locale,
                                      java.lang.String sName)
Description copied from interface: AttributeHints
function for retrieving the locale name of a hint

Specified by:
getLocaleName in interface AttributeHints

getCompOpers

public java.lang.String[][] getCompOpers(LocaleContext locale)
Description copied from interface: AttributeHints
Returns a Map of operators for this attribute.

Specified by:
getCompOpers in interface AttributeHints

getLabel

public final java.lang.String getLabel(LocaleContext locale)
Retrieves the label to be used in any attribute prompts

Specified by:
getLabel in interface GenericHints

getTooltip

public final java.lang.String getTooltip(LocaleContext locale)
Retrives the tooltip text to be used for this attribute

Specified by:
getTooltip in interface GenericHints

getLabelPlural

public final java.lang.String getLabelPlural(LocaleContext locale)
Retrives the label_plural text to be used for this attribute

Specified by:
getLabelPlural in interface GenericHints

getDisplayHint

public java.lang.String getDisplayHint(LocaleContext locale)
Retrieves the display hint that dictates whether this attribute should be visible or not. The two possible values are: ATTRIBUTE_DISPLAY_HINT_DISPLAY = "Display"; ATTRIBUTE_DISPLAY_HINT_HIDE = "Hide";

Specified by:
getDisplayHint in interface AttributeHints

getControlType

public final int getControlType(LocaleContext locale)
Returns the preferred control type for this attribute

Specified by:
getControlType in interface AttributeHints

getDisplayWidth

public final int getDisplayWidth(LocaleContext locale)
Returns the display width for this attribute

Specified by:
getDisplayWidth in interface AttributeHints

getDisplayHeight

public final int getDisplayHeight(LocaleContext locale)
Returns the display width for this attribute

Specified by:
getDisplayHeight in interface AttributeHints

isAutoSubmit

public final boolean isAutoSubmit(LocaleContext locale)
Returns the autoSubmit value for this vc item

Specified by:
isAutoSubmit in interface AttributeHints

getHint

public java.lang.String getHint(LocaleContext locale,
                                java.lang.String sHintName)
Return defaulted hint value

Specified by:
getHint in interface AttributeHints

getHintValue

public java.lang.String getHintValue(LocaleContext locale,
                                     java.lang.String sHintName)
Return non-defaulted hint value

Specified by:
getHintValue in interface GenericHints

hasFormatInformation

public final boolean hasFormatInformation(LocaleContext locale)
Description copied from interface: AttributeHints
Return true if any format hints have been defined for this attribute. This function should eb used to bracket any calls to the formatting api.

Specified by:
hasFormatInformation in interface AttributeHints

getFormattedAttribute

public final java.lang.String getFormattedAttribute(AttributeList attrList,
                                                    LocaleContext locale)
Returns a formatted value for this view criteria item when a view criteria row is passed in. If this item has more than one value use ViewCriteriaItemValue.getFormattedValue(LocaleContext) API.

Specified by:
getFormattedAttribute in interface AttributeHints
Parameters:
attrList - The ViewCriteriaRow reference
locale - locale used in formatting the value
Returns:
formatted value

parseFormattedAttribute

public java.lang.Object parseFormattedAttribute(java.lang.String sValue,
                                                LocaleContext locale)
Description copied from interface: AttributeHints
Strips off the formatting from a string and constructs an instance of the attribute's domain using the 'clean' string as a parameter of the contructor.

Specified by:
parseFormattedAttribute in interface AttributeHints

displayInShortForm

public boolean displayInShortForm(LocaleContext locale)
Description copied from interface: AttributeHints
Returns true if the attribute is to displayed in the short(summary) form.

Specified by:
displayInShortForm in interface AttributeHints

getFormat

public final java.lang.String getFormat(LocaleContext locale)
Description copied from interface: AttributeHints
returns the format string stored in the ui hints

Specified by:
getFormat in interface AttributeHints

getFormatter

public final Formatter getFormatter(LocaleContext locale)
Description copied from interface: AttributeHints
returns the formatter object stored in the ui hints

Specified by:
getFormatter in interface AttributeHints

getFormatterClassName

public final java.lang.String getFormatterClassName(LocaleContext locale)
Returns the formatter object stored in the ui hints

Specified by:
getFormatterClassName in interface AttributeHints

getExprVarVal

public java.lang.Object getExprVarVal(java.lang.String varName)
Specified by:
getExprVarVal in interface ExprValueSupplier

setExprVarVal

public void setExprVarVal(java.lang.String varName,
                          java.lang.Object val)
Specified by:
setExprVarVal in interface ExprValueSupplier

Oracle Fusion Middleware Java API Reference for Oracle ADF Model
11g Release 1 (11.1.1.7.0)

E10653-08

Copyright © 1997, 2013, Oracle. All rights reserved.