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

📄 category.java

📁 hibernate 开源框架的代码 jar包希望大家能喜欢
💻 JAVA
字号:
// $Id: Category.java 6507 2005-04-25 16:57:32Z steveebersole $package org.hibernate.test.filter;import java.util.Date;import java.util.Set;/** * Implementation of Category. * * @author Steve Ebersole */public class Category {	private Long id;	private String name;	private Date effectiveStartDate;	private Date effectiveEndDate;	private Set products;	public Category() {	}	public Category(String name) {		this.name = name;	}	public Category(String name, Date effectiveStartDate, Date effectiveEndDate) {		this.name = name;		this.effectiveStartDate = effectiveStartDate;		this.effectiveEndDate = effectiveEndDate;	}	public Long getId() {		return id;	}	public void setId(Long id) {		this.id = id;	}	public String getName() {		return name;	}	public void setName(String name) {		this.name = name;	}	public Date getEffectiveStartDate() {		return effectiveStartDate;	}	public void setEffectiveStartDate(Date effectiveStartDate) {		this.effectiveStartDate = effectiveStartDate;	}	public Date getEffectiveEndDate() {		return effectiveEndDate;	}	public void setEffectiveEndDate(Date effectiveEndDate) {		this.effectiveEndDate = effectiveEndDate;	}	public Set getProducts() {		return products;	}	public void setProducts(Set products) {		this.products = products;	}	public boolean equals(Object o) {		if ( this == o ) return true;		if ( !( o instanceof Category ) ) return false;		final Category category = ( Category ) o;		if ( !name.equals( category.name ) ) {			return false;		}		if ( effectiveEndDate != null ?		        !effectiveEndDate.equals( category.effectiveEndDate ) :		        category.effectiveEndDate != null ) {			return false;		}		if ( effectiveStartDate != null ?		        !effectiveStartDate.equals( category.effectiveStartDate ) :		        category.effectiveStartDate != null ) {			return false;		}		return true;	}	public int hashCode() {		int result;		result = name.hashCode();		result = 29 * result + ( effectiveStartDate != null ? effectiveStartDate.hashCode() : 0 );		result = 29 * result + ( effectiveEndDate != null ? effectiveEndDate.hashCode() : 0 );		return result;	}}

⌨️ 快捷键说明

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