Examples of BrowseInfo


Examples of org.dspace.browse.BrowseInfo

                scope.setResultsPerPage(Integer.MAX_VALUE);
                // scope.setSortBy(sortBy);
                scope.setBrowseLevel(1);
                // scope.setEtAl(etAl);

                BrowseInfo binfo = be.browse(scope);
                log.debug("Find " + binfo.getResultCount()
                        + "item(s) in browsing...");
                for (BrowseItem bitem : binfo.getBrowseItemResults())
                {
                    if (!invalidIds.contains(bitem.getID()))
                    {
                        result.add(bitem.getID());
                    }
View Full Code Here

Examples of org.dspace.browse.BrowseInfo

                scope.setResultsPerPage(Integer.MAX_VALUE);
                // scope.setSortBy(sortBy);
                scope.setBrowseLevel(1);
                // scope.setEtAl(etAl);

                BrowseInfo binfo = be.browse(scope);
                log.info("Find " + binfo.getResultCount()
                        + "item(s) in browsing...");
                bindItemsToRP(relationPreferenceService, context,
                        fieldsWithAuthoritySupport, tempName,
                        binfo.getItemResults(context));
                count++;
            }

        }
        catch (Exception e)
View Full Code Here

Examples of org.dspace.browse.BrowseInfo

                scope.setFilterValue(authKey);
                scope.setAuthorityValue(authKey);
                scope.setResultsPerPage(Integer.MAX_VALUE);
                scope.setBrowseLevel(1);

                BrowseInfo binfo = be.browse(scope);
                log.debug("Find " + binfo.getResultCount()
                        + "item(s) for the reseracher " + authKey);
                items = binfo.getItemResults(dspaceContext);
               
                if (!silent && rp != null)
                {
                    System.out.println(MESSAGE_ONE);
                   
View Full Code Here

Examples of org.dspace.browse.BrowseInfo

                scope.setFilterValue(authKey);
                scope.setAuthorityValue(authKey);
                scope.setResultsPerPage(Integer.MAX_VALUE);
                scope.setBrowseLevel(1);

                BrowseInfo binfo = be.browse(scope);
                log.debug("Find " + binfo.getResultCount()
                        + "item(s) for the reseracher " + authKey);
                Item[] items = binfo.getItemResults(context);
                for (Item item : items)
                {
                    DSIndexer.indexContent(context, item, true);
                    ib.indexItem(item);
                }
View Full Code Here

Examples of org.dspace.browse.BrowseInfo

        {
            BrowseIndex bi = scope.getBrowseIndex();

            // now start up a browse engine and get it to do the work for us
            BrowseEngine be = new BrowseEngine(context);
            BrowseInfo binfo = be.browse(scope);
           
            request.setAttribute("browse.info", binfo);

            if (AuthorizeManager.isAdmin(context))
            {
                // Set a variable to create admin buttons
                request.setAttribute("admin_button", new Boolean(true));
            }

            if (binfo.hasResults())
            {
                if (bi.isMetadataIndex() && !scope.isSecondLevel())
                {
                    showSinglePage(context, request, response);
                }
View Full Code Here

Examples of org.dspace.browse.BrowseInfo

                DSpaceObject dso = HandleUtil.obtainHandle(objectModel);

                if (dso != null)
                    validity.add(dso);

                BrowseInfo info = getBrowseInfo();

                // Are we browsing items, or unique metadata?
                if (isItemBrowse(info))
                {
                    // Add the browse items to the validity
                    for (BrowseItem item : (java.util.List<BrowseItem>) info.getResults())
                    {
                        validity.add(item);
                    }
                }
                else
View Full Code Here

Examples of org.dspace.browse.BrowseInfo

     * Add Page metadata.
     */
    public void addPageMeta(PageMeta pageMeta) throws SAXException, WingException, UIException,
            SQLException, IOException, AuthorizeException
    {
        BrowseInfo info = getBrowseInfo();

        // Get the name of the index
        String type = info.getBrowseIndex().getName();

        pageMeta.addMetadata("title").addContent(getTitleMessage(info));

        DSpaceObject dso = HandleUtil.obtainHandle(objectModel);

View Full Code Here

Examples of org.dspace.browse.BrowseInfo

     */
    public void addBody(Body body) throws SAXException, WingException, UIException, SQLException,
            IOException, AuthorizeException
    {
        BrowseParams params = getUserParams();
        BrowseInfo info = getBrowseInfo();

        String type = "withdrawn";

        // Build the DRI Body
        Division div = body.addDivision("browse-by-" + type, "primary");

        div.setHead(getTitleMessage(info));

        // Build the internal navigation (jump lists)
        addBrowseJumpNavigation(div, info, params);

        // Build the sort and display controls
        addBrowseControls(div, info, params);

        // This div will hold the browsing results
        Division results = div.addDivision("browse-by-" + type + "-results", "primary");

        // Add the pagination
        if (info.getTotal() <= 0)
        {
            results.setSimplePagination(0, 0, 0, null, null);

        }
        else
        {
            results.setSimplePagination(info.getTotal(), browseInfo.getOverallPosition() + 1,
                    browseInfo.getOverallPosition() + browseInfo.getResultCount(), getPreviousPageURL(
                            params, info), getNextPageURL(params, info));
        }

        // Reference all the browsed items
        ReferenceSet referenceSet = results.addReferenceSet("browse-by-" + type,
                ReferenceSet.TYPE_SUMMARY_LIST, type, null);

        // Are we browsing items, or unique metadata?
        if (isItemBrowse(info))
        {
            // Add the items to the browse results
            for (BrowseItem item : (java.util.List<BrowseItem>) info.getResults())
            {
                referenceSet.addReference(item);
            }
        }
        else    // browsing a list of unique metadata entries
View Full Code Here

Examples of org.dspace.browse.BrowseInfo

            scope.setOrder(SortOption.DESCENDING);
        scope.setResultsPerPage(itemCount);
       
            // gather & add items to the feed.
        BrowseEngine be = new BrowseEngine(context);
        BrowseInfo bi = be.browseMini(scope);
        Item[] results = bi.getItemResults(context);

            if (includeAll)
            {
                return results;
            }
View Full Code Here

Examples of org.dspace.browse.BrowseInfo

            {
                if (so.getName().equals(source))
                    bs.setSortBy(so.getNumber());
            }
     
      BrowseInfo results = be.browseMini(bs);
     
      Item[] items = results.getItemResults(context);
     
      RecentSubmissions rs = new RecentSubmissions(items);
     
      return rs;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.