im.shs.tick.sequence.seq.format.GenerateNoFormat Maven / Gradle / Ivy
package im.shs.tick.sequence.seq.format;
import cn.hutool.core.date.DatePattern;
import cn.hutool.core.date.DateUtil;
import java.util.Date;
public enum GenerateNoFormat {
NONE,
DATE(DatePattern.PURE_DATE_PATTERN),
DATETIME(DatePattern.PURE_DATETIME_PATTERN),
DATETIME_MS(DatePattern.PURE_DATETIME_MS_PATTERN),
TIME(DatePattern.PURE_TIME_PATTERN),
;
private String format;
GenerateNoFormat() {
}
GenerateNoFormat(String format) {
this.format = format;
}
public String getFmt() {
return DateUtil.format(new Date(), format);
}
}