All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.fengwenyi.javalib.convert.FormatterUtils Maven / Gradle / Ivy

There is a newer version: 3.0.1
Show newest version
package com.fengwenyi.javalib.convert;

import com.fengwenyi.javalib.constant.DateTimePattern;

import java.time.format.DateTimeFormatter;

/**
 * @author Erwin Feng
 * @since 2021-12-02
 */
public class FormatterUtils {

    public static DateTimeFormatter dateTimeFormatter() {
        return DateTimeFormatter.ofPattern(DateTimePattern.DATE_TIME);
    }

    public static DateTimeFormatter dateFormatter() {
        return DateTimeFormatter.ofPattern(DateTimePattern.DATE);
    }

    public static DateTimeFormatter timeFormatter() {
        return DateTimeFormatter.ofPattern(DateTimePattern.TIME);
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy