package com.hr.dto;

//import com.yy.basedevelop.common.data.BaseDto;
import com.yy.basedevelop.common.data.BaseReturnDto;
import lombok.Data;

@Data
public class  MyDto<T> extends BaseReturnDto<T> {

   public MyDto(int code, String msg, T data) {
      super(code, msg,data);
   }
   public static <T>  MyDto<T> success(T data) {
      return new MyDto<T>(200, "success",data);
   }
   public static <T> MyDto<T> error( Object data) {
      return new MyDto(0, "error",data);
   }
   public static <T> MyDto<T> success( ) {
      return new MyDto(200, "success",null);
   }

}
