org.threeten.bp.OffsetDateTime.toLocalDateTime()方法的使用及代码示例

x33g5p2x  于2022-01-26 转载在 其他  
字(1.9k)|赞(0)|评价(0)|浏览(191)

本文整理了Java中org.threeten.bp.OffsetDateTime.toLocalDateTime()方法的一些代码示例,展示了OffsetDateTime.toLocalDateTime()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。OffsetDateTime.toLocalDateTime()方法的具体详情如下:
包路径:org.threeten.bp.OffsetDateTime
类名称:OffsetDateTime
方法名:toLocalDateTime

OffsetDateTime.toLocalDateTime介绍

[英]Gets the LocalDateTime part of this offset date-time.

This returns a LocalDateTime with the same year, month, day and time as this date-time.
[中]获取此偏移日期时间的LocalDateTime部分。
这将返回一个LocalDateTime,其年、月、日和时间与此日期时间相同。

代码示例

代码示例来源:origin: XeroAPI/Xero-Java

@Override
 public OffsetDateTime apply(OffsetDateTime d, ZoneId z) {
  return d.withOffsetSameInstant(z.getRules().getOffset(d.toLocalDateTime()));
 }
}

代码示例来源:origin: com.github.joschi.jackson/jackson-datatype-threetenbp

@Override
  public OffsetDateTime apply(OffsetDateTime d, ZoneId z) {
    return d.withOffsetSameInstant(z.getRules().getOffset(d.toLocalDateTime()));
  }
},

代码示例来源:origin: mercadolibre/java-sdk

@Override
 public OffsetDateTime apply(OffsetDateTime d, ZoneId z) {
  return d.withOffsetSameInstant(z.getRules().getOffset(d.toLocalDateTime()));
 }
}

代码示例来源:origin: gengstrand/clojure-news-feed

@Override
 public OffsetDateTime apply(OffsetDateTime d, ZoneId z) {
  return d.withOffsetSameInstant(z.getRules().getOffset(d.toLocalDateTime()));
 }
}

代码示例来源:origin: ThreeTen/threetenbp

public int compareTo(OffsetDateTime other) {
  if (getOffset().equals(other.getOffset())) {
    return toLocalDateTime().compareTo(other.toLocalDateTime());
    cmp = toLocalTime().getNano() - other.toLocalTime().getNano();
    if (cmp == 0) {
      cmp = toLocalDateTime().compareTo(other.toLocalDateTime());

代码示例来源:origin: org.threeten/threetenbp

public int compareTo(OffsetDateTime other) {
  if (getOffset().equals(other.getOffset())) {
    return toLocalDateTime().compareTo(other.toLocalDateTime());
    cmp = toLocalTime().getNano() - other.toLocalTime().getNano();
    if (cmp == 0) {
      cmp = toLocalDateTime().compareTo(other.toLocalDateTime());

相关文章