Class BoughtProducts

java.lang.Object
com.cyran.tp.server.orders.BoughtProducts

@Entity
public class BoughtProducts
extends java.lang.Object
Class for bought products
Author:
Jakub Perdek
  • Constructor Summary

    Constructors 
    Constructor Description
    BoughtProducts()  
  • Method Summary

    Modifier and Type Method Description
    java.lang.Integer getId()
    Gets id of bought product
    Orders getOrder()
    Gets order which contains this product
    java.lang.Double getPrice()
    Gets price of bought product
    Products getProduct()
    Gets original product
    java.lang.Long getQuantity()
    Gets quantity of bought product
    void setId​(java.lang.Integer id)
    Sets id of bought product
    void setOrder​(Orders order)
    Sets order which contains this product
    void setPrice​(java.lang.Double price)
    Sets price of bought product
    void setProduct​(Products product)
    Sets reference to original product
    void setQuantity​(java.lang.Long quantity)
    Sets quantity of bought product

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • getId

      public java.lang.Integer getId()
      Gets id of bought product
      Returns:
      id of bought product
    • setId

      public void setId​(java.lang.Integer id)
      Sets id of bought product
      Parameters:
      id - of bought product
    • getPrice

      public java.lang.Double getPrice()
      Gets price of bought product
      Returns:
      price of bought product
    • setPrice

      public void setPrice​(java.lang.Double price)
      Sets price of bought product
      Parameters:
      price - of bought product
    • getQuantity

      public java.lang.Long getQuantity()
      Gets quantity of bought product
      Returns:
      quantity of bought product
    • setQuantity

      public void setQuantity​(java.lang.Long quantity)
      Sets quantity of bought product
      Parameters:
      quantity - of bought product
    • getOrder

      public Orders getOrder()
      Gets order which contains this product
      Returns:
      order which contains this product
    • setOrder

      public void setOrder​(Orders order)
      Sets order which contains this product
      Parameters:
      order - which contains this product
    • getProduct

      public Products getProduct()
      Gets original product
      Returns:
      original product with its actual price
    • setProduct

      public void setProduct​(Products product)
      Sets reference to original product
      Parameters:
      product - - original product with its actual price