本文整理汇总了Java中org.joda.time.tz.UTCProvider类的典型用法代码示例。如果您正苦于以下问题:Java UTCProvider类的具体用法?Java UTCProvider怎么用?Java UTCProvider使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
UTCProvider类属于org.joda.time.tz包,在下文中一共展示了UTCProvider类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: SortedListTestSetup
import org.joda.time.tz.UTCProvider; //导入依赖的package包/类
public SortedListTestSetup() {
DateTimeZone.setProvider(new UTCProvider());
callbackRecorder = new SortedListCallbackRecorder();
sortedList = new SortedList<>(Article.class, callbackRecorder);
Article past = Article.past();
Article prePast = Article.past();
Article current = Article.current();
Article future = Article.future();
Article postFuture = Article.future();
orderedArticleList = new ArrayList<>();
orderedArticleList.add(prePast);
orderedArticleList.add(past);
orderedArticleList.add(current);
orderedArticleList.add(future);
orderedArticleList.add(postFuture);
shuffledArticles = new ArrayList<>();
for (Article article : orderedArticleList) {
shuffledArticles.add(article.dupe());
}
Collections.shuffle(shuffledArticles);
}
开发者ID:madhu314,项目名称:playbook-android-sortedlist,代码行数:23,代码来源:SortedListTestSetup.java
示例2: packageTest
import org.joda.time.tz.UTCProvider; //导入依赖的package包/类
@Test
public void packageTest() throws Exception {
League league = new Soccer_Total();
DateTimeZone.setProvider(new UTCProvider());
for (Game game : league.pullGamesFromNetwork(null)) {
System.out.println(game.getFirstTeam().getCity() + ", " + game.getSecondTeam().getCity());
}
assertEquals(true, league.hasSecondPhase());
}
开发者ID:riteshakya037,项目名称:Android-Scrapper,代码行数:11,代码来源:ExampleUnitTest.java
示例3: setUp
import org.joda.time.tz.UTCProvider; //导入依赖的package包/类
@Before
public void setUp() throws Exception {
DateTimeZone.setProvider(new UTCProvider());
}
开发者ID:st1hy,项目名称:Red-Calorie,代码行数:5,代码来源:JodaTimePropertyConverterTest.java
注:本文中的org.joda.time.tz.UTCProvider类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论