java.time.LocalDateTime.minusDays(long daysToSubtract) java.time.LocalDateTime.minus() 方法示例 java.time.LocalDateTime.minusDays() 方法示例 java.time.LocalDateTime.minusDays(long daysToSubtract) package com.codingdict; import java.time.LocalDateTime; import java.time.Period; public class LocalDateTimeDemo { public static void main(String[] args) { LocalDateTime date = LocalDateTime.parse("2017-02-03T12:30:30"); System.out.println(date.minus(Period.ofDays(2))); } } java.time.LocalDateTime.minus() 方法示例 java.time.LocalDateTime.minusDays() 方法示例