Package de.hybris.platform.voucher.model
Class RestrictionModel
java.lang.Object
de.hybris.platform.servicelayer.model.AbstractItemModel
de.hybris.platform.core.model.ItemModel
de.hybris.platform.voucher.model.RestrictionModel
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
DateRestrictionModel,NewCustomerRestrictionModel,OrderRestrictionModel,ProductRestrictionModel,RegularCustomerOrderQuantityRestrictionModel,RegularCustomerOrderTotalRestrictionModel,UserRestrictionModel
Generated model class for type Restriction first defined at extension voucher.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class de.hybris.platform.servicelayer.model.AbstractItemModel
de.hybris.platform.servicelayer.model.AbstractItemModel.NewModelContextFactory -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringGenerated model type code constant.static final StringGenerated relation code constant for relationVoucherRestrictionsRelationdefining source attributevoucherin extensionvoucher.static final StringGenerated constant - Attribute key ofRestriction.descriptionattribute defined at extensionvoucher.static final StringGenerated constant - Attribute key ofRestriction.positiveattribute defined at extensionvoucher.static final StringGenerated constant - Attribute key ofRestriction.restrictionTypeattribute defined at extensionvoucher.static final StringGenerated constant - Attribute key ofRestriction.violationMessageattribute defined at extensionvoucher.static final StringGenerated constant - Attribute key ofRestriction.voucherattribute defined at extensionvoucher.static final StringGenerated constant - Attribute key ofRestriction.voucherPOSattribute defined at extensionvoucher.Fields inherited from class de.hybris.platform.core.model.ItemModel
_COMMENTITEMRELATION, COMMENTS, CREATIONTIME, ITEMTYPE, MODIFIEDTIME, OWNER, PK, SEALEDFields inherited from class de.hybris.platform.servicelayer.model.AbstractItemModel
LANGUAGE_FALLBACK_ENABLED_SERVICE_LAYER, MODEL_CONTEXT_FACTORY -
Constructor Summary
ConstructorsConstructorDescriptionGenerated constructor - Default constructor for generic creation.RestrictionModel(ItemModel _owner, VoucherModel _voucher) Deprecated, for removal: This API element is subject to removal in a future version.since 4.1.1 Please use the default constructor without parametersRestrictionModel(de.hybris.platform.servicelayer.model.ItemModelContext ctx) Generated constructor - Default constructor for creation with existing contextRestrictionModel(VoucherModel _voucher) Deprecated, for removal: This API element is subject to removal in a future version.since 4.1.1 Please use the default constructor without parameters -
Method Summary
Modifier and TypeMethodDescriptionGenerated method - Getter of theRestriction.descriptionattribute defined at extensionvoucher.getDescription(Locale loc) Generated method - Getter of theRestriction.descriptionattribute defined at extensionvoucher.Generated method - Getter of theRestriction.positiveattribute defined at extensionvoucher.Generated method - Getter of theRestriction.restrictionTypeattribute defined at extensionvoucher.getRestrictionType(Locale loc) Generated method - Getter of theRestriction.restrictionTypeattribute defined at extensionvoucher.Generated method - Getter of theRestriction.violationMessageattribute defined at extensionvoucher.Generated method - Getter of theRestriction.violationMessageattribute defined at extensionvoucher.Generated method - Getter of theRestriction.voucherattribute defined at extensionvoucher.voidsetDescription(String value) Generated method - Setter ofRestriction.descriptionattribute defined at extensionvoucher.voidsetDescription(String value, Locale loc) Generated method - Setter ofRestriction.descriptionattribute defined at extensionvoucher.voidsetPositive(Boolean value) Generated method - Setter ofRestriction.positiveattribute defined at extensionvoucher.voidsetViolationMessage(String value) Generated method - Setter ofRestriction.violationMessageattribute defined at extensionvoucher.voidsetViolationMessage(String value, Locale loc) Generated method - Setter ofRestriction.violationMessageattribute defined at extensionvoucher.voidsetVoucher(VoucherModel value) Generated method - Initial setter ofRestriction.voucherattribute defined at extensionvoucher.Methods inherited from class de.hybris.platform.core.model.ItemModel
getComments, getCreationtime, getModifiedtime, getOwner, isSealed, setComments, setCreationtime, setModifiedtime, setOwnerMethods inherited from class de.hybris.platform.servicelayer.model.AbstractItemModel
equals, getItemModelContext, getItemtype, getPersistenceContext, getPk, getProperty, getProperty, getTenantId, hashCode, readResolve, setProperty, setProperty, toObject, toObject, toObject, toObject, toObject, toObject, toObject, toObject, toPrimitive, toPrimitive, toPrimitive, toPrimitive, toPrimitive, toPrimitive, toPrimitive, toPrimitive, toString, writeReplace
-
Field Details
-
_TYPECODE
Generated model type code constant.- See Also:
-
_VOUCHERRESTRICTIONSRELATION
Generated relation code constant for relationVoucherRestrictionsRelationdefining source attributevoucherin extensionvoucher.- See Also:
-
POSITIVE
Generated constant - Attribute key ofRestriction.positiveattribute defined at extensionvoucher.- See Also:
-
DESCRIPTION
Generated constant - Attribute key ofRestriction.descriptionattribute defined at extensionvoucher.- See Also:
-
VIOLATIONMESSAGE
Generated constant - Attribute key ofRestriction.violationMessageattribute defined at extensionvoucher.- See Also:
-
RESTRICTIONTYPE
Generated constant - Attribute key ofRestriction.restrictionTypeattribute defined at extensionvoucher.- See Also:
-
VOUCHERPOS
Generated constant - Attribute key ofRestriction.voucherPOSattribute defined at extensionvoucher.- See Also:
-
VOUCHER
Generated constant - Attribute key ofRestriction.voucherattribute defined at extensionvoucher.- See Also:
-
-
Constructor Details
-
RestrictionModel
public RestrictionModel()Generated constructor - Default constructor for generic creation. -
RestrictionModel
public RestrictionModel(de.hybris.platform.servicelayer.model.ItemModelContext ctx) Generated constructor - Default constructor for creation with existing context- Parameters:
ctx- the model context to be injected, must not be null
-
RestrictionModel
Deprecated, for removal: This API element is subject to removal in a future version.since 4.1.1 Please use the default constructor without parametersGenerated constructor - Constructor with all mandatory attributes.- Parameters:
_voucher- initial attribute declared by typeRestrictionat extensionvoucher
-
RestrictionModel
@Deprecated(since="4.1.1", forRemoval=true) public RestrictionModel(ItemModel _owner, VoucherModel _voucher) Deprecated, for removal: This API element is subject to removal in a future version.since 4.1.1 Please use the default constructor without parametersGenerated constructor - for all mandatory and initial attributes.- Parameters:
_owner- initial attribute declared by typeItemat extensioncore_voucher- initial attribute declared by typeRestrictionat extensionvoucher
-
-
Method Details
-
getDescription
Generated method - Getter of theRestriction.descriptionattribute defined at extensionvoucher.- Returns:
- the description - the description of the restriction.
-
getDescription
Generated method - Getter of theRestriction.descriptionattribute defined at extensionvoucher.- Parameters:
loc- the value localization key- Returns:
- the description - the description of the restriction.
- Throws:
IllegalArgumentException- if localization key cannot be mapped to data language
-
getPositive
Generated method - Getter of theRestriction.positiveattribute defined at extensionvoucher.- Returns:
- the positive - Specifies if this restriction is a positive (true) or negative (false) one.
-
getRestrictionType
Generated method - Getter of theRestriction.restrictionTypeattribute defined at extensionvoucher.- Returns:
- the restrictionType - the type of this restriction.
-
getRestrictionType
Generated method - Getter of theRestriction.restrictionTypeattribute defined at extensionvoucher.- Parameters:
loc- the value localization key- Returns:
- the restrictionType - the type of this restriction.
- Throws:
IllegalArgumentException- if localization key cannot be mapped to data language
-
getViolationMessage
Generated method - Getter of theRestriction.violationMessageattribute defined at extensionvoucher.- Returns:
- the violationMessage - the message to return if the restriction is violated (not fulfilled).
-
getViolationMessage
Generated method - Getter of theRestriction.violationMessageattribute defined at extensionvoucher.- Parameters:
loc- the value localization key- Returns:
- the violationMessage - the message to return if the restriction is violated (not fulfilled).
- Throws:
IllegalArgumentException- if localization key cannot be mapped to data language
-
getVoucher
Generated method - Getter of theRestriction.voucherattribute defined at extensionvoucher.- Returns:
- the voucher
-
setDescription
Generated method - Setter ofRestriction.descriptionattribute defined at extensionvoucher.- Parameters:
value- the description - the description of the restriction.
-
setDescription
@Accessor(qualifier="description", type=SETTER) public void setDescription(String value, Locale loc) Generated method - Setter ofRestriction.descriptionattribute defined at extensionvoucher.- Parameters:
value- the description - the description of the restriction.loc- the value localization key- Throws:
IllegalArgumentException- if localization key cannot be mapped to data language
-
setPositive
Generated method - Setter ofRestriction.positiveattribute defined at extensionvoucher.- Parameters:
value- the positive - Specifies if this restriction is a positive (true) or negative (false) one.
-
setViolationMessage
Generated method - Setter ofRestriction.violationMessageattribute defined at extensionvoucher.- Parameters:
value- the violationMessage - the message to return if the restriction is violated (not fulfilled).
-
setViolationMessage
@Accessor(qualifier="violationMessage", type=SETTER) public void setViolationMessage(String value, Locale loc) Generated method - Setter ofRestriction.violationMessageattribute defined at extensionvoucher.- Parameters:
value- the violationMessage - the message to return if the restriction is violated (not fulfilled).loc- the value localization key- Throws:
IllegalArgumentException- if localization key cannot be mapped to data language
-
setVoucher
Generated method - Initial setter ofRestriction.voucherattribute defined at extensionvoucher. Can only be used at creation of model - before first save.- Parameters:
value- the voucher
-