Class GeneratedAbstractPromotion

    • Field Detail

      • PROMOTIONTYPE

        public static final java.lang.String PROMOTIONTYPE
        Qualifier of the AbstractPromotion.promotionType attribute
        See Also:
        Constant Field Values
      • CODE

        public static final java.lang.String CODE
        Qualifier of the AbstractPromotion.code attribute
        See Also:
        Constant Field Values
      • TITLE

        public static final java.lang.String TITLE
        Qualifier of the AbstractPromotion.title attribute
        See Also:
        Constant Field Values
      • DESCRIPTION

        public static final java.lang.String DESCRIPTION
        Qualifier of the AbstractPromotion.description attribute
        See Also:
        Constant Field Values
      • STARTDATE

        public static final java.lang.String STARTDATE
        Qualifier of the AbstractPromotion.startDate attribute
        See Also:
        Constant Field Values
      • ENDDATE

        public static final java.lang.String ENDDATE
        Qualifier of the AbstractPromotion.endDate attribute
        See Also:
        Constant Field Values
      • DETAILSURL

        public static final java.lang.String DETAILSURL
        Qualifier of the AbstractPromotion.detailsURL attribute
        See Also:
        Constant Field Values
      • RESTRICTIONS

        public static final java.lang.String RESTRICTIONS
        Qualifier of the AbstractPromotion.restrictions attribute
        See Also:
        Constant Field Values
      • ENABLED

        public static final java.lang.String ENABLED
        Qualifier of the AbstractPromotion.enabled attribute
        See Also:
        Constant Field Values
      • PRIORITY

        public static final java.lang.String PRIORITY
        Qualifier of the AbstractPromotion.priority attribute
        See Also:
        Constant Field Values
      • IMMUTABLEKEYHASH

        public static final java.lang.String IMMUTABLEKEYHASH
        Qualifier of the AbstractPromotion.immutableKeyHash attribute
        See Also:
        Constant Field Values
      • IMMUTABLEKEY

        public static final java.lang.String IMMUTABLEKEY
        Qualifier of the AbstractPromotion.immutableKey attribute
        See Also:
        Constant Field Values
      • PROMOTIONGROUP

        public static final java.lang.String PROMOTIONGROUP
        Qualifier of the AbstractPromotion.PromotionGroup attribute
        See Also:
        Constant Field Values
      • DEFAULT_INITIAL_ATTRIBUTES

        protected static final java.util.Map<java.lang.String,​Item.AttributeMode> DEFAULT_INITIAL_ATTRIBUTES
    • Constructor Detail

      • GeneratedAbstractPromotion

        public GeneratedAbstractPromotion()
    • Method Detail

      • getCode

        public java.lang.String getCode​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.code attribute.
        Returns:
        the code - Identifier for this promotion
      • getCode

        public java.lang.String getCode()
        Generated method - Getter of the AbstractPromotion.code attribute.
        Returns:
        the code - Identifier for this promotion
      • setCode

        public void setCode​(SessionContext ctx,
                            java.lang.String value)
        Generated method - Setter of the AbstractPromotion.code attribute.
        Parameters:
        value - the code - Identifier for this promotion
      • setCode

        public void setCode​(java.lang.String value)
        Generated method - Setter of the AbstractPromotion.code attribute.
        Parameters:
        value - the code - Identifier for this promotion
      • createItem

        protected Item createItem​(SessionContext ctx,
                                  ComposedType type,
                                  Item.ItemAttributeMap allAttributes)
                           throws JaloBusinessException
        Description copied from class: Item
        Has to be implemented for each concrete subtype of item. This method is responsible for creating a new item instance ( by calling managers, ejb homes, etc. ) during ComposedType.newInstance(Map).

        In case this method uses any of the attribute values during creation it is required to override Item.getNonInitialAttributes(SessionContext, ItemAttributeMap) too.
        Sn example:

        
         public static final String MY_ATTRIBUTE = "someAttribute"; ... protected Item createItem(SessionContext
         ctx, ComposedType type, Map allAttributes ) throws JaloBusinessException { MyManager man = ... return
         man.createMyItem( (String)allAttributes.get(MY_ATTRIBUTE) );
         // here MY_ATTRIBUTE is used for creation, so it must not be set again } protected Map getNonInitialAttributes(
         SessionContext ctx, Map allAttributes ) { // let superclass remove its own initial attributes Map ret =
         super.getNonInitialAttributes( ctx, allAttributes );
         // remove MY_ATTRIBUTE from all attributes since if has already been set ret.remove(MY_ATTRIBUTE); return ret; }
        
         
        Overrides:
        createItem in class GenericItem
        Parameters:
        ctx - the current session context which this item is created within
        type - the actual item type ( since subtypes may not provide a own jalo class this may be different from the type which this method was implemented for )
        Returns:
        the new item instance
        Throws:
        JaloBusinessException - indicates an error during creation - any changes will be rollbacked
      • getDescription

        public java.lang.String getDescription​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.description attribute.
        Returns:
        the description - Description of this promotion
      • getDescription

        public java.lang.String getDescription()
        Generated method - Getter of the AbstractPromotion.description attribute.
        Returns:
        the description - Description of this promotion
      • setDescription

        public void setDescription​(SessionContext ctx,
                                   java.lang.String value)
        Generated method - Setter of the AbstractPromotion.description attribute.
        Parameters:
        value - the description - Description of this promotion
      • setDescription

        public void setDescription​(java.lang.String value)
        Generated method - Setter of the AbstractPromotion.description attribute.
        Parameters:
        value - the description - Description of this promotion
      • getDetailsURL

        public java.lang.String getDetailsURL​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.detailsURL attribute.
        Returns:
        the detailsURL - URL to a content page with further details of this promotion
      • getDetailsURL

        public java.lang.String getDetailsURL()
        Generated method - Getter of the AbstractPromotion.detailsURL attribute.
        Returns:
        the detailsURL - URL to a content page with further details of this promotion
      • setDetailsURL

        public void setDetailsURL​(SessionContext ctx,
                                  java.lang.String value)
        Generated method - Setter of the AbstractPromotion.detailsURL attribute.
        Parameters:
        value - the detailsURL - URL to a content page with further details of this promotion
      • setDetailsURL

        public void setDetailsURL​(java.lang.String value)
        Generated method - Setter of the AbstractPromotion.detailsURL attribute.
        Parameters:
        value - the detailsURL - URL to a content page with further details of this promotion
      • isEnabled

        public java.lang.Boolean isEnabled​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.enabled attribute.
        Returns:
        the enabled - Flag to indicate if this promotion is enabled.
      • isEnabled

        public java.lang.Boolean isEnabled()
        Generated method - Getter of the AbstractPromotion.enabled attribute.
        Returns:
        the enabled - Flag to indicate if this promotion is enabled.
      • isEnabledAsPrimitive

        public boolean isEnabledAsPrimitive​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.enabled attribute.
        Returns:
        the enabled - Flag to indicate if this promotion is enabled.
      • isEnabledAsPrimitive

        public boolean isEnabledAsPrimitive()
        Generated method - Getter of the AbstractPromotion.enabled attribute.
        Returns:
        the enabled - Flag to indicate if this promotion is enabled.
      • setEnabled

        public void setEnabled​(SessionContext ctx,
                               java.lang.Boolean value)
        Generated method - Setter of the AbstractPromotion.enabled attribute.
        Parameters:
        value - the enabled - Flag to indicate if this promotion is enabled.
      • setEnabled

        public void setEnabled​(java.lang.Boolean value)
        Generated method - Setter of the AbstractPromotion.enabled attribute.
        Parameters:
        value - the enabled - Flag to indicate if this promotion is enabled.
      • setEnabled

        public void setEnabled​(SessionContext ctx,
                               boolean value)
        Generated method - Setter of the AbstractPromotion.enabled attribute.
        Parameters:
        value - the enabled - Flag to indicate if this promotion is enabled.
      • setEnabled

        public void setEnabled​(boolean value)
        Generated method - Setter of the AbstractPromotion.enabled attribute.
        Parameters:
        value - the enabled - Flag to indicate if this promotion is enabled.
      • getEndDate

        public java.util.Date getEndDate​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.endDate attribute.
        Returns:
        the endDate - Date on which this promotion stops being available, if not set the promotion will not be available.
      • getEndDate

        public java.util.Date getEndDate()
        Generated method - Getter of the AbstractPromotion.endDate attribute.
        Returns:
        the endDate - Date on which this promotion stops being available, if not set the promotion will not be available.
      • setEndDate

        public void setEndDate​(SessionContext ctx,
                               java.util.Date value)
        Generated method - Setter of the AbstractPromotion.endDate attribute.
        Parameters:
        value - the endDate - Date on which this promotion stops being available, if not set the promotion will not be available.
      • setEndDate

        public void setEndDate​(java.util.Date value)
        Generated method - Setter of the AbstractPromotion.endDate attribute.
        Parameters:
        value - the endDate - Date on which this promotion stops being available, if not set the promotion will not be available.
      • getImmutableKey

        public java.lang.String getImmutableKey​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.immutableKey attribute.
        Returns:
        the immutableKey - The full immutable identifier for this promotion
      • getImmutableKey

        public java.lang.String getImmutableKey()
        Generated method - Getter of the AbstractPromotion.immutableKey attribute.
        Returns:
        the immutableKey - The full immutable identifier for this promotion
      • setImmutableKey

        public void setImmutableKey​(SessionContext ctx,
                                    java.lang.String value)
        Generated method - Setter of the AbstractPromotion.immutableKey attribute.
        Parameters:
        value - the immutableKey - The full immutable identifier for this promotion
      • setImmutableKey

        public void setImmutableKey​(java.lang.String value)
        Generated method - Setter of the AbstractPromotion.immutableKey attribute.
        Parameters:
        value - the immutableKey - The full immutable identifier for this promotion
      • getImmutableKeyHash

        public java.lang.String getImmutableKeyHash​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.immutableKeyHash attribute.
        Returns:
        the immutableKeyHash - The HASH of the immutableKey
      • getImmutableKeyHash

        public java.lang.String getImmutableKeyHash()
        Generated method - Getter of the AbstractPromotion.immutableKeyHash attribute.
        Returns:
        the immutableKeyHash - The HASH of the immutableKey
      • setImmutableKeyHash

        public void setImmutableKeyHash​(SessionContext ctx,
                                        java.lang.String value)
        Generated method - Setter of the AbstractPromotion.immutableKeyHash attribute.
        Parameters:
        value - the immutableKeyHash - The HASH of the immutableKey
      • setImmutableKeyHash

        public void setImmutableKeyHash​(java.lang.String value)
        Generated method - Setter of the AbstractPromotion.immutableKeyHash attribute.
        Parameters:
        value - the immutableKeyHash - The HASH of the immutableKey
      • getPriority

        public java.lang.Integer getPriority​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.priority attribute.
        Returns:
        the priority - Value to indicate relative priority of promotions. The higher the value the higher the priority.
      • getPriority

        public java.lang.Integer getPriority()
        Generated method - Getter of the AbstractPromotion.priority attribute.
        Returns:
        the priority - Value to indicate relative priority of promotions. The higher the value the higher the priority.
      • getPriorityAsPrimitive

        public int getPriorityAsPrimitive​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.priority attribute.
        Returns:
        the priority - Value to indicate relative priority of promotions. The higher the value the higher the priority.
      • getPriorityAsPrimitive

        public int getPriorityAsPrimitive()
        Generated method - Getter of the AbstractPromotion.priority attribute.
        Returns:
        the priority - Value to indicate relative priority of promotions. The higher the value the higher the priority.
      • setPriority

        public void setPriority​(SessionContext ctx,
                                java.lang.Integer value)
        Generated method - Setter of the AbstractPromotion.priority attribute.
        Parameters:
        value - the priority - Value to indicate relative priority of promotions. The higher the value the higher the priority.
      • setPriority

        public void setPriority​(java.lang.Integer value)
        Generated method - Setter of the AbstractPromotion.priority attribute.
        Parameters:
        value - the priority - Value to indicate relative priority of promotions. The higher the value the higher the priority.
      • setPriority

        public void setPriority​(SessionContext ctx,
                                int value)
        Generated method - Setter of the AbstractPromotion.priority attribute.
        Parameters:
        value - the priority - Value to indicate relative priority of promotions. The higher the value the higher the priority.
      • setPriority

        public void setPriority​(int value)
        Generated method - Setter of the AbstractPromotion.priority attribute.
        Parameters:
        value - the priority - Value to indicate relative priority of promotions. The higher the value the higher the priority.
      • getPromotionGroup

        public PromotionGroup getPromotionGroup​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.PromotionGroup attribute.
        Returns:
        the PromotionGroup
      • getPromotionGroup

        public PromotionGroup getPromotionGroup()
        Generated method - Getter of the AbstractPromotion.PromotionGroup attribute.
        Returns:
        the PromotionGroup
      • setPromotionGroup

        public void setPromotionGroup​(SessionContext ctx,
                                      PromotionGroup value)
        Generated method - Setter of the AbstractPromotion.PromotionGroup attribute.
        Parameters:
        value - the PromotionGroup
      • setPromotionGroup

        public void setPromotionGroup​(PromotionGroup value)
        Generated method - Setter of the AbstractPromotion.PromotionGroup attribute.
        Parameters:
        value - the PromotionGroup
      • getPromotionType

        public abstract java.lang.String getPromotionType​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.promotionType attribute.
        Returns:
        the promotionType - The type of this promotion.
      • getPromotionType

        public java.lang.String getPromotionType()
        Generated method - Getter of the AbstractPromotion.promotionType attribute.
        Returns:
        the promotionType - The type of this promotion.
      • getAllPromotionType

        public abstract java.util.Map<Language,​java.lang.String> getAllPromotionType​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.promotionType attribute.
        Returns:
        the localized promotionType - The type of this promotion.
      • getAllPromotionType

        public java.util.Map<Language,​java.lang.String> getAllPromotionType()
        Generated method - Getter of the AbstractPromotion.promotionType attribute.
        Returns:
        the localized promotionType - The type of this promotion.
      • getRestrictions

        public abstract java.util.Collection<AbstractPromotionRestriction> getRestrictions​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.restrictions attribute.
        Returns:
        the restrictions - Collection of restrictions that are applied to this promotion
      • getRestrictions

        public java.util.Collection<AbstractPromotionRestriction> getRestrictions()
        Generated method - Getter of the AbstractPromotion.restrictions attribute.
        Returns:
        the restrictions - Collection of restrictions that are applied to this promotion
      • setRestrictions

        public abstract void setRestrictions​(SessionContext ctx,
                                             java.util.Collection<AbstractPromotionRestriction> value)
        Generated method - Setter of the AbstractPromotion.restrictions attribute.
        Parameters:
        value - the restrictions - Collection of restrictions that are applied to this promotion
      • setRestrictions

        public void setRestrictions​(java.util.Collection<AbstractPromotionRestriction> value)
        Generated method - Setter of the AbstractPromotion.restrictions attribute.
        Parameters:
        value - the restrictions - Collection of restrictions that are applied to this promotion
      • getStartDate

        public java.util.Date getStartDate​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.startDate attribute.
        Returns:
        the startDate - Date on which this promotion becomes available, if not set the promotion will not be available.
      • getStartDate

        public java.util.Date getStartDate()
        Generated method - Getter of the AbstractPromotion.startDate attribute.
        Returns:
        the startDate - Date on which this promotion becomes available, if not set the promotion will not be available.
      • setStartDate

        public void setStartDate​(SessionContext ctx,
                                 java.util.Date value)
        Generated method - Setter of the AbstractPromotion.startDate attribute.
        Parameters:
        value - the startDate - Date on which this promotion becomes available, if not set the promotion will not be available.
      • setStartDate

        public void setStartDate​(java.util.Date value)
        Generated method - Setter of the AbstractPromotion.startDate attribute.
        Parameters:
        value - the startDate - Date on which this promotion becomes available, if not set the promotion will not be available.
      • getTitle

        public java.lang.String getTitle​(SessionContext ctx)
        Generated method - Getter of the AbstractPromotion.title attribute.
        Returns:
        the title - Title for this promotion
      • getTitle

        public java.lang.String getTitle()
        Generated method - Getter of the AbstractPromotion.title attribute.
        Returns:
        the title - Title for this promotion
      • setTitle

        public void setTitle​(SessionContext ctx,
                             java.lang.String value)
        Generated method - Setter of the AbstractPromotion.title attribute.
        Parameters:
        value - the title - Title for this promotion
      • setTitle

        public void setTitle​(java.lang.String value)
        Generated method - Setter of the AbstractPromotion.title attribute.
        Parameters:
        value - the title - Title for this promotion