package com.eactive.eai.rms.data.entity.onl.adapter;

import java.io.Serializable;

import javax.persistence.Cacheable;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;
import org.hibernate.annotations.Comment;

import com.eactive.eai.data.entity.AbstractEntity;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NonNull;

@Data
@EqualsAndHashCode(onlyExplicitlyIncluded = true, callSuper = true)

@Cache(usage = CacheConcurrencyStrategy.NONSTRICT_READ_WRITE)
@Cacheable
@Entity
@Table(name = "tseaicm23")
@org.hibernate.annotations.Table(appliesTo = "tseaicm23", comment = "코드정의 도메인, 프로퍼티의 UI 표현을 위한 domain 정보(RADIO_YN, SELECT_YN 등)")
public class CommonDomain extends AbstractEntity<String> implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@Column(unique = true, nullable = false, length = 20)
	@Comment("도메인명")
	private String domainNm;

	@Column(length = 10)
	@Comment("도메인 옵션")
	private String domainOption;

	@Column(length = 10)
	@Comment("도메인 타입")
	private String domainType;

	@Column(length = 1000)
	@Comment("도메인 값")
	private String domainVal;

	@Override
	public @NonNull String getId() {
		return domainNm;
	}

}