Class GeneratedExternalDiscountValue

    • Constructor Detail

      • GeneratedExternalDiscountValue

        public GeneratedExternalDiscountValue()
    • Method Detail

      • getCode

        public java.lang.String getCode​(SessionContext ctx)
        Generated method - Getter of the ExternalDiscountValue.code attribute.
        Returns:
        the code - Discount code
      • getCode

        public java.lang.String getCode()
        Generated method - Getter of the ExternalDiscountValue.code attribute.
        Returns:
        the code - Discount code
      • setCode

        public void setCode​(SessionContext ctx,
                            java.lang.String value)
        Generated method - Setter of the ExternalDiscountValue.code attribute.
        Parameters:
        value - the code - Discount code
      • setCode

        public void setCode​(java.lang.String value)
        Generated method - Setter of the ExternalDiscountValue.code attribute.
        Parameters:
        value - the code - Discount code
      • 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
      • getLevel

        public java.lang.Integer getLevel​(SessionContext ctx)
        Generated method - Getter of the ExternalDiscountValue.level attribute.
        Returns:
        the level - Discount level
      • getLevel

        public java.lang.Integer getLevel()
        Generated method - Getter of the ExternalDiscountValue.level attribute.
        Returns:
        the level - Discount level
      • getLevelAsPrimitive

        public int getLevelAsPrimitive​(SessionContext ctx)
        Generated method - Getter of the ExternalDiscountValue.level attribute.
        Returns:
        the level - Discount level
      • getLevelAsPrimitive

        public int getLevelAsPrimitive()
        Generated method - Getter of the ExternalDiscountValue.level attribute.
        Returns:
        the level - Discount level
      • setLevel

        public void setLevel​(SessionContext ctx,
                             java.lang.Integer value)
        Generated method - Setter of the ExternalDiscountValue.level attribute.
        Parameters:
        value - the level - Discount level
      • setLevel

        public void setLevel​(java.lang.Integer value)
        Generated method - Setter of the ExternalDiscountValue.level attribute.
        Parameters:
        value - the level - Discount level
      • setLevel

        public void setLevel​(SessionContext ctx,
                             int value)
        Generated method - Setter of the ExternalDiscountValue.level attribute.
        Parameters:
        value - the level - Discount level
      • setLevel

        public void setLevel​(int value)
        Generated method - Setter of the ExternalDiscountValue.level attribute.
        Parameters:
        value - the level - Discount level
      • getOrder

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

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

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

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

        public AbstractOrderEntry getOrderEntry​(SessionContext ctx)
        Generated method - Getter of the ExternalDiscountValue.orderEntry attribute.
        Returns:
        the orderEntry
      • getOrderEntry

        public AbstractOrderEntry getOrderEntry()
        Generated method - Getter of the ExternalDiscountValue.orderEntry attribute.
        Returns:
        the orderEntry
      • setOrderEntry

        public void setOrderEntry​(SessionContext ctx,
                                  AbstractOrderEntry value)
        Generated method - Setter of the ExternalDiscountValue.orderEntry attribute.
        Parameters:
        value - the orderEntry
      • setOrderEntry

        public void setOrderEntry​(AbstractOrderEntry value)
        Generated method - Setter of the ExternalDiscountValue.orderEntry attribute.
        Parameters:
        value - the orderEntry
      • getType

        public java.lang.String getType​(SessionContext ctx)
        Generated method - Getter of the ExternalDiscountValue.type attribute.
        Returns:
        the type - Discount type
      • getType

        public java.lang.String getType()
        Generated method - Getter of the ExternalDiscountValue.type attribute.
        Returns:
        the type - Discount type
      • setType

        public void setType​(SessionContext ctx,
                            java.lang.String value)
        Generated method - Setter of the ExternalDiscountValue.type attribute.
        Parameters:
        value - the type - Discount type
      • setType

        public void setType​(java.lang.String value)
        Generated method - Setter of the ExternalDiscountValue.type attribute.
        Parameters:
        value - the type - Discount type
      • getValue

        public java.lang.Double getValue​(SessionContext ctx)
        Generated method - Getter of the ExternalDiscountValue.value attribute.
        Returns:
        the value - External Discount Value
      • getValue

        public java.lang.Double getValue()
        Generated method - Getter of the ExternalDiscountValue.value attribute.
        Returns:
        the value - External Discount Value
      • getValueAsPrimitive

        public double getValueAsPrimitive​(SessionContext ctx)
        Generated method - Getter of the ExternalDiscountValue.value attribute.
        Returns:
        the value - External Discount Value
      • getValueAsPrimitive

        public double getValueAsPrimitive()
        Generated method - Getter of the ExternalDiscountValue.value attribute.
        Returns:
        the value - External Discount Value
      • setValue

        public void setValue​(SessionContext ctx,
                             java.lang.Double value)
        Generated method - Setter of the ExternalDiscountValue.value attribute.
        Parameters:
        value - the value - External Discount Value
      • setValue

        public void setValue​(java.lang.Double value)
        Generated method - Setter of the ExternalDiscountValue.value attribute.
        Parameters:
        value - the value - External Discount Value
      • setValue

        public void setValue​(SessionContext ctx,
                             double value)
        Generated method - Setter of the ExternalDiscountValue.value attribute.
        Parameters:
        value - the value - External Discount Value
      • setValue

        public void setValue​(double value)
        Generated method - Setter of the ExternalDiscountValue.value attribute.
        Parameters:
        value - the value - External Discount Value