⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 product.java

📁 ssd3部分quiz、exercise、exam的参考答案
💻 JAVA
字号:

public class Product {

	/*
 * (non-javadoc)
 */
	private String code;

/*
 * (non-javadoc)
 */
	private String description;

/*
 * (non-javadoc)
 */
	private double price;

	public String getCode(){
		return this.code;

	}
	
	public Product(String initializeCode, String initializeDescription, double initializePrice) {
		this.code = initializeCode;
		this.description = initializeDescription;
		this.price = initializePrice;
	}

	public String getDescription(){
		return this.description;

	}

	public double getPrice(){
		return this.price;
	
	}
	
	public boolean equals(Object object) {
		return object instanceof Product
        && getCode().equals(((Product) object).getCode());
		
	}
	
	public String toString() {
		return this.code + "_" + this.description + "_" + this.price;
	}



}

///**
// * Getter of the property <tt>processesOrder</tt>
// *
// * @return Returns the processesOrder.
// * 
// */
//public ProcessesOrder getProcessesOrder()
//{
//	return processesOrder;
//}
///**
// * Setter of the property <tt>processesOrder</tt>
// *
// * @param processesOrder The processesOrder to set.
// *
// */
//public void setProcessesOrder(ProcessesOrder processesOrder ){
//	this.processesOrder = processesOrder;
//}

⌨️ 快捷键说明

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