private static List<FeedItem> convert(List<Item> items) {
        List<FeedItem> results = new ArrayList<>(items.size());
        for (Item item : items) {
            FeedItem fi = new FeedItem();
            fi.setAuthor(item.getAuthor().orElse(Constants.EMPTY_STRING));
            fi.getCategories().addAll(item.getCategories());
            fi.setComments(item.getComments().orElse(Constants.EMPTY_STRING));
            fi.setDescription(item.getDescription().orElse(Constants.EMPTY_STRING));
            fi.setGuid(item.getGuid().orElse(Constants.EMPTY_STRING));
            fi.setIsPermaLink(item.getIsPermaLink().orElse(Boolean.FALSE));
            fi.setLink(item.getLink().orElse(Constants.EMPTY_STRING));
            fi.setPubDate(item.getPubDate().orElse(Constants.EMPTY_STRING));
            fi.setTitle(item.getTitle().orElse(Constants.EMPTY_STRING));
            if (item instanceof ItunesItem) {
                ItunesItem itunes = (ItunesItem) item;
                fi.setItunesBlock(itunes.isItunesBlock());
                fi.setItunesDuration(itunes.getItunesDuration().orElse(Constants.EMPTY_STRING));
                fi.setItunesEpisode(itunes.getItunesEpisode().orElse(0));
                fi.setItunesEpisodeType(itunes.getItunesEpisodeType().orElse(Constants.EMPTY_STRING));
                fi.setItunesExplicit(itunes.isItunesExplicit());
                fi.setItunesImage(itunes.getItunesImage().orElse(Constants.EMPTY_STRING));
                fi.setItunesKeywords(itunes.getItunesKeywords().orElse(Constants.EMPTY_STRING));
                fi.setItunesSeason(itunes.getItunesSeason().orElse(0));
                fi.setItunesSubtitle(itunes.getItunesSubtitle().orElse(Constants.EMPTY_STRING));
                fi.setItunesSummary(itunes.getItunesSummary().orElse(Constants.EMPTY_STRING));
                fi.setItunesTitle(itunes.getItunesTitle().orElse(Constants.EMPTY_STRING));
            }
            results.add(fi);
        }
        return results;
    }
Converts a list of generic RSS items into a list of FeedItem objects.

@param items The list of generic RSS items to convert.
@return A list of FeedItem objects converted from the input list of items.
primefaces/src/main/java/org/primefaces/component/feedreader/RSSUtils.java