package cn.wise.sc.cement.business.util;

import java.time.LocalDateTime;
import java.time.temporal.WeekFields;

/**
 * @author neo.shu
 * @since 2020/4/5 22:26
 */

public class DateUtil {

	/**
	 * 获取自然周数
	 *
	 * @param localDateTime
	 * @return
	 */
	public static int getWeek(LocalDateTime localDateTime) {
		WeekFields weekFields = WeekFields.ISO;
		return localDateTime.get(weekFields.weekOfWeekBasedYear());
	}
}
