productentity.java

来自「一个基于java工厂模式的 的实现」· Java 代码 · 共 136 行

JAVA
136
字号
/*
 * ProductEntity.java
 *
 * Created on 2007年4月19日, 上午10:05
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package com.ebuy.entities;

/**
 *
 * @author Administrator
 */
public class ProductEntity
{
    private int productid;
    private String productname;
    private int categoryid;
    private double unitprice;
    private String imagename;
    private int quantity;
    private int downbound;
    
    private double realprice;
    private double discount;
    private boolean normal=true;
    
    public ProductEntity()
    {
    }

    public int getProductid()
    {
        return productid;
    }

    public void setProductid(int productid)
    {
        this.productid = productid;
    }

    public String getProductname()
    {
        return productname;
    }

    public void setProductname(String productname)
    {
        this.productname = productname;
    }

    public int getCategoryid()
    {
        return categoryid;
    }

    public void setCategoryid(int categoryid)
    {
        this.categoryid = categoryid;
    }

    public double getUnitprice()
    {
        return unitprice;
    }

    public void setUnitprice(double unitprice)
    {
        this.unitprice = unitprice;
    }

    public String getImagename()
    {
        return imagename;
    }

    public void setImagename(String imagename)
    {
        this.imagename = imagename;
    }

    public double getRealprice()
    {
        return this.getUnitprice()*(1-this.getDiscount());
    }

    public void setRealprice(double realprice)
    {
        this.realprice = realprice;
    }

    public double getDiscount()
    {
        return discount;
    }

    public void setDiscount(double discount)
    {
        this.discount = discount;
    }

    public int getQuantity()
    {
        return quantity;
    }

    public void setQuantity(int quantity)
    {
        this.quantity = quantity;
    }

    public int getDownbound()
    {
        return downbound;
    }

    public void setDownbound(int downbound)
    {
        this.downbound = downbound;
    }

    public boolean isNormal()
    {
        return this.normal;
    }

    public void setNormal(boolean normal)
    {
        this.normal = normal;
    }

  
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?