本文整理了Java中com.j256.ormlite.dao.Dao.mapSelectStarRow()
方法的一些代码示例,展示了Dao.mapSelectStarRow()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Dao.mapSelectStarRow()
方法的具体详情如下:
包路径:com.j256.ormlite.dao.Dao
类名称:Dao
方法名:mapSelectStarRow
[英]Return the latest row from the database results from a query to select * (star).
[中]从数据库中返回查询结果中的最新行,以选择*(星形)。
代码示例来源:origin: j256/ormlite-core
/**
* @see Dao#mapSelectStarRow(DatabaseResults)
*/
@Override
public T mapSelectStarRow(DatabaseResults results) {
try {
return dao.mapSelectStarRow(results);
} catch (SQLException e) {
logMessage(e, "mapSelectStarRow threw exception on results");
throw new RuntimeException(e);
}
}
代码示例来源:origin: com.j256.ormlite/ormlite-core
/**
* @see Dao#mapSelectStarRow(DatabaseResults)
*/
@Override
public T mapSelectStarRow(DatabaseResults results) {
try {
return dao.mapSelectStarRow(results);
} catch (SQLException e) {
logMessage(e, "mapSelectStarRow threw exception on results");
throw new RuntimeException(e);
}
}
代码示例来源:origin: j256/ormlite-core
@Test(expected = RuntimeException.class)
public void testMapSelectStarRowThrow() throws Exception {
@SuppressWarnings("unchecked")
Dao<Foo, String> dao = (Dao<Foo, String>) createMock(Dao.class);
RuntimeExceptionDao<Foo, String> rtDao = new RuntimeExceptionDao<Foo, String>(dao);
DatabaseResults results = createMock(DatabaseResults.class);
expect(dao.mapSelectStarRow(results)).andThrow(new SQLException("Testing catch"));
replay(dao);
rtDao.mapSelectStarRow(results);
verify(dao);
}
代码示例来源:origin: j256/ormlite-core
DatabaseResults results = iterator.getRawResults();
for (int count = 0; results.next(); count++) {
Foo foo = dao.mapSelectStarRow(results);
switch (count) {
case 0 :
内容来源于网络,如有侵权,请联系作者删除!