本文整理了Java中com.datastax.driver.core.LocalDate.getYear()
方法的一些代码示例,展示了LocalDate.getYear()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。LocalDate.getYear()
方法的具体详情如下:
包路径:com.datastax.driver.core.LocalDate
类名称:LocalDate
方法名:getYear
[英]Returns the year.
[中]返回年份。
代码示例来源:origin: com.datastax.cassandra/cassandra-driver-core
@Override
public String toString() {
return String.format("%d-%s-%s", getYear(), pad2(getMonth()), pad2(getDay()));
}
代码示例来源:origin: com.datastax.cassandra/cassandra-driver-core
public LocalDateAssert hasYearMonthDay(int expectedYear, int expectedMonth, int expectedDay) {
assertThat(actual.getYear()).isEqualTo(expectedYear);
assertThat(actual.getMonth()).isEqualTo(expectedMonth);
assertThat(actual.getDay()).isEqualTo(expectedDay);
return this;
}
代码示例来源:origin: org.springframework.data/spring-data-cassandra
@Override
public LocalDate convert(com.datastax.driver.core.LocalDate source) {
return new LocalDate(source.getYear(), source.getMonth(), source.getDay());
}
}
代码示例来源:origin: org.springframework.data/spring-data-cassandra
@Override
public LocalDate convert(com.datastax.driver.core.LocalDate source) {
return LocalDate.of(source.getYear(), source.getMonth(), source.getDay());
}
}
代码示例来源:origin: com.facebook.presto.cassandra/cassandra-driver
@Override
public String toString() {
return String.format("%d-%s-%s", getYear(),
pad2(getMonth()),
pad2(getDay()));
}
代码示例来源:origin: io.prestosql.cassandra/cassandra-driver
@Override
public String toString() {
return String.format("%d-%s-%s", getYear(),
pad2(getMonth()),
pad2(getDay()));
}
代码示例来源:origin: com.yugabyte/cassandra-driver-core
@Override
public String toString() {
return String.format("%d-%s-%s", getYear(),
pad2(getMonth()),
pad2(getDay()));
}
代码示例来源:origin: org.springframework.data/spring-data-cassandra
@Override
public LocalDate convert(com.datastax.driver.core.LocalDate source) {
return LocalDate.of(source.getYear(), source.getMonth(), source.getDay());
}
}
代码示例来源:origin: com.datastax.dse/dse-java-driver-core
public LocalDateAssert hasYearMonthDay(int expectedYear, int expectedMonth, int expectedDay) {
assertThat(actual.getYear()).isEqualTo(expectedYear);
assertThat(actual.getMonth()).isEqualTo(expectedMonth);
assertThat(actual.getDay()).isEqualTo(expectedDay);
return this;
}
内容来源于网络,如有侵权,请联系作者删除!