Class FeatureField
java.lang.Object
de.hybris.platform.core.FlexibleSearchTranslatable
de.hybris.platform.core.GenericField
de.hybris.platform.core.GenericSearchField
de.hybris.platform.catalog.jalo.classification.util.FeatureField
- All Implemented Interfaces:
Serializable
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionFeatureField(ClassAttributeAssignment assignment, String producttypeAlias, Language lang, boolean enumsAsPos, boolean isValueSelect) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddSelectableValue(int position, ClassificationAttributeValue selValue) For enum features: Since operations which require value order are limited to the configured selctable values it is necessary to add unconfigured values manually if they should be comparable within the query.protected booleanFor enum features: Returns all configured selectable value.getUnit()Returns the unit of the queried feature.booleanTells whether or not string comparation should be done case insensitively.voidsetCaseInsensitive(boolean insensitive) Changes whether or not string comparation should be done case insensitively.voidsetLanguage(Language lang) For localized features only: Allows to specify the value language explicitely - otherwise the session language would have been used.voidsetProductTypeAlias(String alias) Allows to specify the alias of the product type within the enclosing query.voidsetSelectRawValue(boolean selectRaw) voidFor features with existing unit only: Changes the target unit of this condition.voidtoFlexibleSearch(StringBuilder query, Map<String, String> typeIndexMap, Map<String, Object> valueMap) compiles this instance in order to append its query snippet and add its value(s), if anyprotected voidwriteConditions(StringBuilder query, Map<String, String> typeIndexMap, Map<String, Object> valueMap) protected voidwriteValueField(StringBuilder query, Map<String, Object> valueMap) Methods inherited from class de.hybris.platform.core.GenericSearchField
addFieldType, equals, getFieldTypes, getLanguagePK, hasFieldType, hashCode, isTranslatableToPolyglotDialect, setFieldTypes, setLanguagePK, toPolyglotSearch, toStringMethods inherited from class de.hybris.platform.core.GenericField
getQualifier, getTypeCode, getTypeIdentifier, setQualifier, setTypeIdentifierMethods inherited from class de.hybris.platform.core.FlexibleSearchTranslatable
getAliasFromTypeMap
-
Constructor Details
-
FeatureField
public FeatureField(ClassAttributeAssignment assignment, String producttypeAlias, Language lang, boolean enumsAsPos, boolean isValueSelect)
-
-
Method Details
-
setSelectRawValue
public void setSelectRawValue(boolean selectRaw) -
getFeatureType
-
getSelectableValues
For enum features: Returns all configured selectable value. Operations which require value order are limited to these values (using their position within the list).See
addSelectableValue(int, ClassificationAttributeValue)for how to allow unconfigured values as well. -
addSelectableValue
For enum features: Since operations which require value order are limited to the configured selctable values it is necessary to add unconfigured values manually if they should be comparable within the query.- Parameters:
position- the desired position of the unconfigured valueselValue- the unconfigured value
-
getClassAttributeAssignment
-
getUnit
Returns the unit of the queried feature. If a unit is present the statement will convert all values of other units into this unit to allow comparation. -
setUnit
For features with existing unit only: Changes the target unit of this condition. Only convertible units of the configured unit are allowed. -
setLanguage
For localized features only: Allows to specify the value language explicitely - otherwise the session language would have been used. -
getLanguage
-
setProductTypeAlias
Allows to specify the alias of the product type within the enclosing query.This is always necessary when the product type is not the initial type of the enclosing query!
-
getProductTypeAlias
-
isCaseInsensitive
public boolean isCaseInsensitive()Tells whether or not string comparation should be done case insensitively. -
setCaseInsensitive
public void setCaseInsensitive(boolean insensitive) Changes whether or not string comparation should be done case insensitively. -
enumsAsPos
protected boolean enumsAsPos() -
writeValueField
-
writeConditions
-
toFlexibleSearch
public void toFlexibleSearch(StringBuilder query, Map<String, String> typeIndexMap, Map<String, Object> valueMap) Description copied from class:FlexibleSearchTranslatablecompiles this instance in order to append its query snippet and add its value(s), if any- Overrides:
toFlexibleSearchin classGenericSearchField- Parameters:
query- contains the querytypeIndexMap- contains typeCode <> typeIndex mappingsvalueMap- contains valueQualifier <> value mappings- See Also:
-