Class ProductBuilder

    • Constructor Summary

      Constructors 
      Constructor Description
      ProductBuilder()
      Default constructor.
      ProductBuilder​(java.lang.Integer amount)
      Custom Constructor.
      ProductBuilder​(java.lang.Integer amount, java.lang.String productType, java.lang.String productTypeDetails)
      Custom Constructor.
      ProductBuilder​(java.lang.Integer amount, java.lang.String productType, java.lang.String productTypeDetails, java.lang.String descriptiveName)
      Custom Constructor.
      ProductBuilder​(Product product)
      Custom Constructor.
      ProductBuilder​(org.w3c.dom.Node productNode)
      Custom constructor.
    • Constructor Detail

      • ProductBuilder

        public ProductBuilder()
        Default constructor.
      • ProductBuilder

        public ProductBuilder​(org.w3c.dom.Node productNode)
                       throws jakarta.xml.bind.JAXBException
        Custom constructor. Accepting a W3C Node object for initializing.
        Parameters:
        productNode - W2C Node object for
        Throws:
        jakarta.xml.bind.JAXBException
      • ProductBuilder

        public ProductBuilder​(java.lang.Integer amount)
        Custom Constructor. Creates a new instance of ProductBuilder which already contains attribute Amount.
        Parameters:
        amount - Value of Amount attribute
      • ProductBuilder

        public ProductBuilder​(java.lang.Integer amount,
                              java.lang.String productType,
                              java.lang.String productTypeDetails)
        Custom Constructor. Creates a new instance of ProductBuilder which already contains attributes Amount, ID, ProductType and ProductTypeDetails.
        Parameters:
        amount - Value of Amount attribute
        productType - Value of ProductType attribute
        productTypeDetails - Value of ProductTypeDetails attribute
      • ProductBuilder

        public ProductBuilder​(java.lang.Integer amount,
                              java.lang.String productType,
                              java.lang.String productTypeDetails,
                              java.lang.String descriptiveName)
        Custom Constructor. Creates a new instance of ProductBuilder which already contains attributes Amount, ID, ProductType and ProductTypeDetails.
        Parameters:
        amount - Value of Amount attribute
        productType - Value of ProductType attribute
        productTypeDetails - Value of ProductTypeDetails attribute
        descriptiveName - String value for DescriptiveName attribute.
      • ProductBuilder

        public ProductBuilder​(Product product)
        Custom Constructor. Creates a new instance of ProductBuilder based on a existing Product Node.
        Parameters:
        product - Product node for initializing.
    • Method Detail

      • getProduct

        protected Product getProduct()
        Getter for product attribute.
        Returns:
        the product
      • addIntent

        public void addIntent​(ProductIntent intent)
        Append Intent node to Product Definition.
        Parameters:
        intent - Intent object to append to.