Class GeneratedPromotionResult

    • Field Detail

      • ACTIONS

        public static final java.lang.String ACTIONS
        Qualifier of the PromotionResult.actions attribute
        See Also:
        Constant Field Values
      • CONSUMEDENTRIES

        public static final java.lang.String CONSUMEDENTRIES
        Qualifier of the PromotionResult.consumedEntries attribute
        See Also:
        Constant Field Values
      • PROMOTION

        public static final java.lang.String PROMOTION
        Qualifier of the PromotionResult.promotion attribute
        See Also:
        Constant Field Values
      • CERTAINTY

        public static final java.lang.String CERTAINTY
        Qualifier of the PromotionResult.certainty attribute
        See Also:
        Constant Field Values
      • CUSTOM

        public static final java.lang.String CUSTOM
        Qualifier of the PromotionResult.custom attribute
        See Also:
        Constant Field Values
      • ORDER

        public static final java.lang.String ORDER
        Qualifier of the PromotionResult.order attribute
        See Also:
        Constant Field Values
      • ALLPROMOTIONACTIONS

        public static final java.lang.String ALLPROMOTIONACTIONS
        Qualifier of the PromotionResult.allPromotionActions 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

      • GeneratedPromotionResult

        public GeneratedPromotionResult()
    • Method Detail

      • getActions

        public abstract java.util.Collection<AbstractPromotionAction> getActions​(SessionContext ctx)
        Generated method - Getter of the PromotionResult.actions attribute.
        Returns:
        the actions - List of actions
      • getActions

        public java.util.Collection<AbstractPromotionAction> getActions()
        Generated method - Getter of the PromotionResult.actions attribute.
        Returns:
        the actions - List of actions
      • setActions

        public abstract void setActions​(SessionContext ctx,
                                        java.util.Collection<AbstractPromotionAction> value)
        Generated method - Setter of the PromotionResult.actions attribute.
        Parameters:
        value - the actions - List of actions
      • setActions

        public void setActions​(java.util.Collection<AbstractPromotionAction> value)
        Generated method - Setter of the PromotionResult.actions attribute.
        Parameters:
        value - the actions - List of actions
      • getAllPromotionActions

        public java.util.Set<AbstractPromotionAction> getAllPromotionActions​(SessionContext ctx)
        Generated method - Getter of the PromotionResult.allPromotionActions attribute.
        Returns:
        the allPromotionActions
      • getAllPromotionActions

        public java.util.Set<AbstractPromotionAction> getAllPromotionActions()
        Generated method - Getter of the PromotionResult.allPromotionActions attribute.
        Returns:
        the allPromotionActions
      • setAllPromotionActions

        public void setAllPromotionActions​(SessionContext ctx,
                                           java.util.Set<AbstractPromotionAction> value)
        Generated method - Setter of the PromotionResult.allPromotionActions attribute.
        Parameters:
        value - the allPromotionActions
      • setAllPromotionActions

        public void setAllPromotionActions​(java.util.Set<AbstractPromotionAction> value)
        Generated method - Setter of the PromotionResult.allPromotionActions attribute.
        Parameters:
        value - the allPromotionActions
      • addToAllPromotionActions

        public void addToAllPromotionActions​(SessionContext ctx,
                                             AbstractPromotionAction value)
        Generated method - Adds value to allPromotionActions.
        Parameters:
        value - the item to add to allPromotionActions
      • addToAllPromotionActions

        public void addToAllPromotionActions​(AbstractPromotionAction value)
        Generated method - Adds value to allPromotionActions.
        Parameters:
        value - the item to add to allPromotionActions
      • removeFromAllPromotionActions

        public void removeFromAllPromotionActions​(SessionContext ctx,
                                                  AbstractPromotionAction value)
        Generated method - Removes value from allPromotionActions.
        Parameters:
        value - the item to remove from allPromotionActions
      • removeFromAllPromotionActions

        public void removeFromAllPromotionActions​(AbstractPromotionAction value)
        Generated method - Removes value from allPromotionActions.
        Parameters:
        value - the item to remove from allPromotionActions
      • getCertainty

        public java.lang.Float getCertainty​(SessionContext ctx)
        Generated method - Getter of the PromotionResult.certainty attribute.
        Returns:
        the certainty - Certainty
      • getCertainty

        public java.lang.Float getCertainty()
        Generated method - Getter of the PromotionResult.certainty attribute.
        Returns:
        the certainty - Certainty
      • getCertaintyAsPrimitive

        public float getCertaintyAsPrimitive​(SessionContext ctx)
        Generated method - Getter of the PromotionResult.certainty attribute.
        Returns:
        the certainty - Certainty
      • getCertaintyAsPrimitive

        public float getCertaintyAsPrimitive()
        Generated method - Getter of the PromotionResult.certainty attribute.
        Returns:
        the certainty - Certainty
      • setCertainty

        public void setCertainty​(SessionContext ctx,
                                 java.lang.Float value)
        Generated method - Setter of the PromotionResult.certainty attribute.
        Parameters:
        value - the certainty - Certainty
      • setCertainty

        public void setCertainty​(java.lang.Float value)
        Generated method - Setter of the PromotionResult.certainty attribute.
        Parameters:
        value - the certainty - Certainty
      • setCertainty

        public void setCertainty​(SessionContext ctx,
                                 float value)
        Generated method - Setter of the PromotionResult.certainty attribute.
        Parameters:
        value - the certainty - Certainty
      • setCertainty

        public void setCertainty​(float value)
        Generated method - Setter of the PromotionResult.certainty attribute.
        Parameters:
        value - the certainty - Certainty
      • getConsumedEntries

        public abstract java.util.Collection<PromotionOrderEntryConsumed> getConsumedEntries​(SessionContext ctx)
        Generated method - Getter of the PromotionResult.consumedEntries attribute.
        Returns:
        the consumedEntries - List of consumed entries
      • getConsumedEntries

        public java.util.Collection<PromotionOrderEntryConsumed> getConsumedEntries()
        Generated method - Getter of the PromotionResult.consumedEntries attribute.
        Returns:
        the consumedEntries - List of consumed entries
      • setConsumedEntries

        public abstract void setConsumedEntries​(SessionContext ctx,
                                                java.util.Collection<PromotionOrderEntryConsumed> value)
        Generated method - Setter of the PromotionResult.consumedEntries attribute.
        Parameters:
        value - the consumedEntries - List of consumed entries
      • setConsumedEntries

        public void setConsumedEntries​(java.util.Collection<PromotionOrderEntryConsumed> value)
        Generated method - Setter of the PromotionResult.consumedEntries attribute.
        Parameters:
        value - the consumedEntries - List of consumed entries
      • 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
      • getCustom

        public java.lang.String getCustom​(SessionContext ctx)
        Generated method - Getter of the PromotionResult.custom attribute.
        Returns:
        the custom - Custom data stored on this promotion result by the promotion.
      • getCustom

        public java.lang.String getCustom()
        Generated method - Getter of the PromotionResult.custom attribute.
        Returns:
        the custom - Custom data stored on this promotion result by the promotion.
      • setCustom

        public void setCustom​(SessionContext ctx,
                              java.lang.String value)
        Generated method - Setter of the PromotionResult.custom attribute.
        Parameters:
        value - the custom - Custom data stored on this promotion result by the promotion.
      • setCustom

        public void setCustom​(java.lang.String value)
        Generated method - Setter of the PromotionResult.custom attribute.
        Parameters:
        value - the custom - Custom data stored on this promotion result by the promotion.
      • getOrder

        public AbstractOrder getOrder​(SessionContext ctx)
        Generated method - Getter of the PromotionResult.order attribute.
        Returns:
        the order
      • getOrder

        public AbstractOrder getOrder()
        Generated method - Getter of the PromotionResult.order attribute.
        Returns:
        the order
      • setOrder

        public void setOrder​(SessionContext ctx,
                             AbstractOrder value)
        Generated method - Setter of the PromotionResult.order attribute.
        Parameters:
        value - the order
      • setOrder

        public void setOrder​(AbstractOrder value)
        Generated method - Setter of the PromotionResult.order attribute.
        Parameters:
        value - the order
      • getPromotion

        public AbstractPromotion getPromotion​(SessionContext ctx)
        Generated method - Getter of the PromotionResult.promotion attribute.
        Returns:
        the promotion - The promotion
      • getPromotion

        public AbstractPromotion getPromotion()
        Generated method - Getter of the PromotionResult.promotion attribute.
        Returns:
        the promotion - The promotion
      • setPromotion

        public void setPromotion​(SessionContext ctx,
                                 AbstractPromotion value)
        Generated method - Setter of the PromotionResult.promotion attribute.
        Parameters:
        value - the promotion - The promotion
      • setPromotion

        public void setPromotion​(AbstractPromotion value)
        Generated method - Setter of the PromotionResult.promotion attribute.
        Parameters:
        value - the promotion - The promotion