package com.tzld.piaoquan.api.model.vo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Objects;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class IdNameVO<T> {
    private T id;
    private String name;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        IdNameVO<?> idNameVO = (IdNameVO<?>) o;
        return Objects.equals(id, idNameVO.id);
    }
}
