magnolia-module-rssaggregator Version: 2.0.3-rc1 Last Published: Sep 17, 2013

CPD Results

The following document contains the results of PMD's CPD 4.2.5.

Duplications

FileLine
info/magnolia/module/rssaggregator/templates/components/FeedStatisticsModel.java107
info/magnolia/module/rssaggregator/templates/components/FeedSubscriptionsModel.java83
            log.debug(query);

            Query q = qm.createQuery(query, "xpath");
            QueryResult res = q.execute();
            Collection<Content> col = res.getContent(DataConsts.MODULE_DATA_CONTENT_NODE_TYPE);
            int resCount = 0;
            for (Content c : col) {
                resCount++;
                if (resCount <= maxResults) {
                    results.add(new NodeMapWrapper(c, c.getHandle()));
                } else {
                    break;
                }
            }
            log.debug("returning collection with {} items.", "" + results.size());
            return results;
        } catch (RepositoryException e) {
            log.error(e.getLocalizedMessage(), e);
        }
        return null;
    }

    /**
     * Retrieve the title attribute of an individual feed subscription.
     *
     * @param feedLink Link to the feed.
     * @return Assigned title of a feed if defined in the dialog or null.
     */
    public String getFeedTitle(String feedLink) {
        try {
            if (content.hasProperty("feed")) {
                Node rssParent = SessionUtil.getNodeByIdentifier(DATA_WORKSPACE, content.getProperty("feed").getString());