customerkey.java
来自「噶额外噶外骨骼感广泛高热感 就 啊啊」· Java 代码 · 共 52 行
JAVA
52 行
package itso.ejb.model.entity;
/**
* Key class for Entity Bean: Customer
*/
public class CustomerKey implements java.io.Serializable {
static final long serialVersionUID = 3206093459760846163L;
/**
* Implementation field for persistent attribute: id
*/
public int id;
/**
* Creates an empty key for Entity Bean: Customer
*/
public CustomerKey() {
}
/**
* Creates a key for Entity Bean: Customer
*/
public CustomerKey(int id) {
this.id = id;
}
/**
* Returns true if both keys are equal.
*/
public boolean equals(java.lang.Object otherKey) {
if (otherKey instanceof itso.ejb.model.entity.CustomerKey) {
itso.ejb.model.entity.CustomerKey o =
(itso.ejb.model.entity.CustomerKey) otherKey;
return ((this.id == o.id));
}
return false;
}
/**
* Returns the hash code for the key.
*/
public int hashCode() {
return ((new java.lang.Integer(id).hashCode()));
}
/**
* Get accessor for persistent attribute: id
*/
public int getId() {
return id;
}
/**
* Set accessor for persistent attribute: id
*/
public void setId(int newId) {
id = newId;
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?