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

📄 item.java

📁 基于Struts的网络商店源码。使用Hibernate技术
💻 JAVA
字号:
package com.sush.webstore.store.domain.beans;

import com.sush.webstore.store.domain.IImages;
import com.sush.webstore.store.domain.IItem;

public class Item implements IItem {

	private long id;

	private String name;

	private String description;

	private Double price;

	private Images images = new Images();
	
	private boolean available = true;

	/**
	 * @return the description
	 */
	public String getDescription() {
		return description;
	}

	/**
	 * @param description
	 *            the description to set
	 */
	public void setDescription(String description) {
		this.description = description;
	}

	/**
	 * @return the id
	 */
	public long getId() {
		return id;
	}

	/**
	 * @param id
	 *            the id to set
	 */
	private void setId(long id) {
		this.id = id;
	}

	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}

	/**
	 * @param name
	 *            the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}

	/**
	 * @return the price
	 */
	public Double getPrice() {
		return price;
	}

	/**
	 * @param price
	 *            the price to set
	 */
	public void setPrice(Double price) {
		this.price = price;
	}

	/**
	 * @return the images
	 */
	public IImages getIImages() {
		return images;
	}

	/**
	 * @param images
	 *            the images to set
	 */
	public void setImages(Images images) {
		this.images = images;
	}

	/**
	 * @return the images
	 */
	public Images getImages() {
		return images;
	}
//	@Override
//	public boolean equals(Object obj) {
//
//		if (this == obj)
//			return true;
//
//		if (this.getClass() != obj.getClass())
//			return false;
//
//		Item objP = (Item) obj;
//
//		return (objP.id == this.id) ? true : false;
//	}
//
//	@Override
//	public int hashCode() {
//
//		int hash = 7;
//		hash = hash * 31 + new Integer(Long.toString(id));
//		return hash;
//	}

	/**
	 * @return the available
	 */
	public boolean isAvailable() {
		return available;
	}

	/**
	 * @param available the available to set
	 */
	public void setAvailable(boolean available) {
		this.available = available;
	}
}

⌨️ 快捷键说明

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