add lombok
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
package com.imyeyu.spring.entity;
|
||||
|
||||
import com.imyeyu.spring.annotation.table.Id;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
/**
|
||||
* 基本长整型 ID 实体
|
||||
@@ -8,33 +10,11 @@ import com.imyeyu.spring.annotation.table.Id;
|
||||
* @author 夜雨
|
||||
* @since 2025-02-07 12:51
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
public class Entity extends BaseEntity implements IDEntity<Long> {
|
||||
|
||||
/** ID */
|
||||
@Id
|
||||
protected Long id;
|
||||
|
||||
/**
|
||||
* 创建基础 ID 实体
|
||||
*/
|
||||
public Entity() {
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取 ID
|
||||
*
|
||||
* @return ID
|
||||
*/
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置 ID
|
||||
*
|
||||
* @param id ID
|
||||
*/
|
||||
public void setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user