org.apache.abdera.model.Feed.addExtension()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(3.5k)|赞(0)|评价(0)|浏览(137)

本文整理了Java中org.apache.abdera.model.Feed.addExtension()方法的一些代码示例,展示了Feed.addExtension()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Feed.addExtension()方法的具体详情如下:
包路径:org.apache.abdera.model.Feed
类名称:Feed
方法名:addExtension

Feed.addExtension介绍

暂无

代码示例

代码示例来源:origin: org.apache.abdera/abdera-extensions-main

public static void addTombstone(Feed source, Tombstone tombstone) {
  source.addExtension(tombstone);
}

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(list.size()));

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(list.size()));

代码示例来源:origin: org.apache.abdera/abdera-extensions-opensearch

private Feed createFeed(RequestContext searchRequest, Map<String, String> parameters, List<T> searchResults) {
    Factory factory = searchRequest.getAbdera().getFactory();
    Feed feed = factory.newFeed();
    feed.setId(this.getOpenSearchFeedId(searchRequest));
    feed.setTitle(this.getOpenSearchFeedTitle(searchRequest));
    feed.addAuthor(this.getOpenSearchFeedAuthor(searchRequest));
    feed.setUpdated(this.getOpenSearchFeedUpdatedDate(searchRequest));
    feed.addLink(searchRequest.getUri().toString(), "self");
    int totalResults = this.getOpenSearchFeedTotalResults(searchRequest, parameters, searchResults);
    if (totalResults > -1) {
      ((IntegerElement)feed.addExtension(OpenSearchConstants.TOTAL_RESULTS)).setValue(totalResults);
    }
    int itemsPerPage = this.getOpenSearchFeedItemsPerPage(searchRequest, parameters, searchResults);
    if (itemsPerPage > -1) {
      ((IntegerElement)feed.addExtension(OpenSearchConstants.ITEMS_PER_PAGE)).setValue(itemsPerPage);
    }
    int startIndex = this.getOpenSearchFeedStartIndex(searchRequest, parameters, searchResults);
    if (startIndex > -1) {
      ((IntegerElement)feed.addExtension(OpenSearchConstants.START_INDEX)).setValue(startIndex);
    }
    for (T entity : searchResults) {
      Entry entry = factory.newEntry();
      this.fillEntry(entry, entity);
      feed.addEntry(entry);
    }
    this.postProcess(feed, searchRequest, parameters, searchResults);
    return feed;
  }
}

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(list.getNumItems()));

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(descendants.size()));

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(tree.size()));

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText("1"); // Folder always has only one parent.
Entry e = feed.addEntry();
Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(parents.size()));

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(list.getNumItems()));

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(list.getNumItems()));

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(list.getNumItems()));

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(list.getNumItems()));

代码示例来源:origin: org.xcmis/xcmis-restatom

Element numItems = feed.addExtension(AtomCMIS.NUM_ITEMS);
numItems.setText(Integer.toString(list.getNumItems()));

相关文章