@param fileList @param maxCount @return
( HashMap<String, FileInfo> fileList, int maxCount )
| 1341 | * @return |
| 1342 | */ |
| 1343 | public ArrayList<BookInfo> loadRecentBooks( HashMap<String, FileInfo> fileList, int maxCount ) |
| 1344 | { |
| 1345 | ArrayList<FileInfo> list = new ArrayList<FileInfo>(); |
| 1346 | findRecentBooks( list, maxCount, maxCount*10 ); |
| 1347 | ArrayList<BookInfo> res = new ArrayList<BookInfo>(list.size()); |
| 1348 | for ( FileInfo file : list ) { |
| 1349 | fileList.put(file.getPathName(), file); |
| 1350 | BookInfo item = new BookInfo( file ); |
| 1351 | ArrayList<Bookmark> bookmarks = new ArrayList<Bookmark>(); |
| 1352 | if ( load( bookmarks, "book_fk=" + file.id + " ORDER BY type" ) ) { |
| 1353 | item.setBookmarks(bookmarks); |
| 1354 | } |
| 1355 | res.add(item); |
| 1356 | } |
| 1357 | return res; |
| 1358 | } |
| 1359 | |
| 1360 | private boolean saveBookInternal( BookInfo bookInfo ) |
| 1361 | { |
no test coverage detected