枚举类,解决重复代码

枚举类,解决重复代码块问题

public abstract class JoneEvent<T> {

    private EventType eventType;
    private String operator;
    private Date eventTime;
    private T data;


    public EventType getEventType() {
        return eventType;
    }

    public void setEventType(EventType eventType) {
        this.eventType = eventType;
    }

    public String getOperator() {
        return operator;
    }

    public void setOperator(String operator) {
        this.operator = operator;
    }

    public Date getEventTime() {
        return eventTime;
    }

    public void setEventTime(Date eventTime) {
        this.eventTime = eventTime;
    }

    public T getData() {
        return data;
    }

    public void setData(T data) {
        this.data = data;
    }


}
posted @ 2021-03-10 16:23  SpecialSpeculator  阅读(184)  评论(0编辑  收藏  举报