@Override public int getTrashContainerModelsCount(long classPK) throws PortalException { BookmarksFolder folder = BookmarksFolderLocalServiceUtil.getFolder(classPK); return BookmarksFolderLocalServiceUtil.getFoldersCount( folder.getGroupId(), classPK, WorkflowConstants.STATUS_IN_TRASH); }
@Override public List<TrashRenderer> getTrashContainerModelTrashRenderers(long classPK, int start, int end) throws PortalException { List<TrashRenderer> trashRenderers = new ArrayList<TrashRenderer>(); BookmarksFolder folder = BookmarksFolderLocalServiceUtil.getFolder(classPK); List<BookmarksFolder> folders = BookmarksFolderLocalServiceUtil.getFolders( folder.getGroupId(), classPK, WorkflowConstants.STATUS_IN_TRASH, start, end); for (BookmarksFolder curFolder : folders) { TrashHandler trashHandler = TrashHandlerRegistryUtil.getTrashHandler(BookmarksFolder.class.getName()); TrashRenderer trashRenderer = trashHandler.getTrashRenderer(curFolder.getPrimaryKey()); trashRenderers.add(trashRenderer); } return trashRenderers; }