本文整理了Java中com.yahoo.bard.webservice.data.time.ZonedTimeGrain.getBaseTimeGrain()
方法的一些代码示例,展示了ZonedTimeGrain.getBaseTimeGrain()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZonedTimeGrain.getBaseTimeGrain()
方法的具体详情如下:
包路径:com.yahoo.bard.webservice.data.time.ZonedTimeGrain
类名称:ZonedTimeGrain
方法名:getBaseTimeGrain
暂无
代码示例来源:origin: yahoo/fili
@Override
public boolean equals(Object that) {
if (!(that instanceof ZonedTimeGrain)) {
return false;
}
ZonedTimeGrain thatGrain = (ZonedTimeGrain) that;
return (this.getBaseTimeGrain().equals((thatGrain.getBaseTimeGrain()))) && Objects.equals(
this.timeZone,
thatGrain.timeZone
);
}
代码示例来源:origin: yahoo/fili
/**
* Gets a list of {@link SqlDatePartFunction} to be performed on a timestamp
* which can be used to group by the given {@link Granularity}.
*
* @param granularity The granularity to map to a list of {@link SqlDatePartFunction}.
*
* @return the list of sql functions.
*/
public List<SqlDatePartFunction> timeGrainToDatePartFunctions(Granularity granularity) {
if (granularity instanceof ZonedTimeGrain) {
ZonedTimeGrain defaultTimeGrain = (ZonedTimeGrain) granularity;
return granularityToDateFunctionMap.get(defaultTimeGrain.getBaseTimeGrain());
}
return granularityToDateFunctionMap.get(granularity);
}
代码示例来源:origin: yahoo/fili
/**
* Create a ZonedTimeGrain with the same base grain and a different time zone.
*
* @param dateTimeZone The time zone to associate with the resulting zone time grain
*
* @return The modified copy ZonedTimeGrain
*/
public ZonedTimeGrain withZone(DateTimeZone dateTimeZone) {
return new ZonedTimeGrain(this.getBaseTimeGrain(), dateTimeZone);
}
内容来源于网络,如有侵权,请联系作者删除!