package kr.co.uplus.ez.common.data;

import com.fasterxml.jackson.annotation.JsonInclude;

import lombok.Data;

@Data
@JsonInclude(JsonInclude.Include.NON_NULL)
public class ApiResponseMessage<T> {

	private String retCode;
	private String retMsg;
	protected T data;


	public ApiResponseMessage() {
		this.retCode = ApiResponseCode.SUCCESS.getResultCode();
		this.retMsg = ApiResponseCode.SUCCESS.getResultMsg();
	}

	public ApiResponseMessage(ApiResponseCode returnStr) {
		this.retCode = returnStr.getResultCode();
		this.retMsg = returnStr.getResultMsg();
	}

	public ApiResponseMessage(String code, String msg) {
		this.retCode = code;
		this.retMsg = msg;
	}

}