Examples of Entries


Examples of apigen.adt.api.types.Entries

          List<Type> listModuleType = new LinkedList<Type>();
          currentModule = (Modulentry)adt.getHead();
          moduleName = currentModule.getModulename().getName();
          //System.out.println("Processing module "+moduleName);
          modules.add(currentModule);
          Entries currentEntries = currentModule.getEntries();
          while(!currentEntries.isEmpty()) {
            entries.add(currentEntries.getHead());
            currentEntries = currentEntries.getTail();
          }
         
         
          while (!entries.isEmpty()) { //For each entry in the module
            List<Entry> alts = new LinkedList<Entry>();
View Full Code Here

Examples of com.apress.prospring3.springblog.domain.Entries

  private EntryService entryService;
 
  @RequestMapping(value = "/listdata", method = RequestMethod.GET)
  @ResponseBody
  public Entries listData() {
    return new Entries(entryService.findAll());
  }
View Full Code Here

Examples of com.badlogic.gdx.utils.IntFloatMap.Entries

  /** Returns an iterator for the entries in the map. Remove is supported. Note that the same iterator instance is returned each
   * time this method is called. Use the {@link Entries} constructor for nested or multithreaded iteration. */
  public Entries entries () {
    if (entries1 == null) {
      entries1 = new Entries(this);
      entries2 = new Entries(this);
    }
    if (!entries1.valid) {
      entries1.reset();
      entries1.valid = true;
      entries2.valid = false;
View Full Code Here

Examples of com.commafeed.frontend.model.Entries

    List<FeedEntryKeyword> entryKeywords = FeedEntryKeyword.fromQueryString(keywords);

    limit = Math.min(limit, 1000);
    limit = Math.max(0, limit);

    Entries entries = new Entries();
    entries.setOffset(offset);
    entries.setLimit(limit);
    boolean unreadOnly = readType == ReadingMode.unread;
    if (StringUtils.isBlank(id)) {
      id = ALL;
    }

    Date newerThanDate = newerThan == null ? null : new Date(newerThan);

    List<Long> excludedIds = null;
    if (StringUtils.isNotEmpty(excludedSubscriptionIds)) {
      excludedIds = Lists.newArrayList();
      for (String excludedId : excludedSubscriptionIds.split(",")) {
        excludedIds.add(Long.valueOf(excludedId));
      }
    }

    if (ALL.equals(id)) {
      entries.setName(Optional.fromNullable(tag).or("All"));
      List<FeedSubscription> subs = feedSubscriptionDAO.findAll(user);
      removeExcludedSubscriptions(subs, excludedIds);
      List<FeedEntryStatus> list = feedEntryStatusDAO.findBySubscriptions(user, subs, unreadOnly, entryKeywords, newerThanDate,
          offset, limit + 1, order, true, onlyIds, tag);

      for (FeedEntryStatus status : list) {
        entries.getEntries().add(
            Entry.build(status, config.getApplicationSettings().getPublicUrl(), config.getApplicationSettings()
                .isImageProxyEnabled()));
      }

    } else if (STARRED.equals(id)) {
      entries.setName("Starred");
      List<FeedEntryStatus> starred = feedEntryStatusDAO.findStarred(user, newerThanDate, offset, limit + 1, order, !onlyIds);
      for (FeedEntryStatus status : starred) {
        entries.getEntries().add(
            Entry.build(status, config.getApplicationSettings().getPublicUrl(), config.getApplicationSettings()
                .isImageProxyEnabled()));
      }
    } else {
      FeedCategory parent = feedCategoryDAO.findById(user, Long.valueOf(id));
      if (parent != null) {
        List<FeedCategory> categories = feedCategoryDAO.findAllChildrenCategories(user, parent);
        List<FeedSubscription> subs = feedSubscriptionDAO.findByCategories(user, categories);
        removeExcludedSubscriptions(subs, excludedIds);
        List<FeedEntryStatus> list = feedEntryStatusDAO.findBySubscriptions(user, subs, unreadOnly, entryKeywords, newerThanDate,
            offset, limit + 1, order, true, onlyIds, tag);

        for (FeedEntryStatus status : list) {
          entries.getEntries().add(
              Entry.build(status, config.getApplicationSettings().getPublicUrl(), config.getApplicationSettings()
                  .isImageProxyEnabled()));
        }
        entries.setName(parent.getName());
      } else {
        return Response.status(Status.NOT_FOUND).entity("<message>category not found</message>").build();
      }
    }

    boolean hasMore = entries.getEntries().size() > limit;
    if (hasMore) {
      entries.setHasMore(true);
      entries.getEntries().remove(entries.getEntries().size() - 1);
    }

    entries.setTimestamp(System.currentTimeMillis());
    entries.setIgnoredReadStatus(STARRED.equals(id) || keywords != null || tag != null);
    FeedUtils.removeUnwantedFromSearch(entries.getEntries(), entryKeywords);
    return Response.ok(entries).build();
  }
View Full Code Here

Examples of com.commafeed.frontend.model.Entries

    Response response = getCategoryEntries(user, id, readType, newerThan, offset, limit, order, keywords, onlyIds,
        excludedSubscriptionIds, tag);
    if (response.getStatus() != Status.OK.getStatusCode()) {
      return response;
    }
    Entries entries = (Entries) response.getEntity();

    SyndFeed feed = new SyndFeedImpl();
    feed.setFeedType("rss_2.0");
    feed.setTitle("CommaFeed - " + entries.getName());
    feed.setDescription("CommaFeed - " + entries.getName());
    String publicUrl = config.getApplicationSettings().getPublicUrl();
    feed.setLink(publicUrl);

    List<SyndEntry> children = Lists.newArrayList();
    for (Entry entry : entries.getEntries()) {
      children.add(entry.asRss());
    }
    feed.setEntries(children);

    SyndFeedOutput output = new SyndFeedOutput();
View Full Code Here

Examples of com.commafeed.frontend.model.Entries

    List<FeedEntryKeyword> entryKeywords = FeedEntryKeyword.fromQueryString(keywords);

    limit = Math.min(limit, 1000);
    limit = Math.max(0, limit);

    Entries entries = new Entries();
    entries.setOffset(offset);
    entries.setLimit(limit);

    boolean unreadOnly = readType == ReadingMode.unread;

    Date newerThanDate = newerThan == null ? null : new Date(newerThan);

    FeedSubscription subscription = feedSubscriptionDAO.findById(user, Long.valueOf(id));
    if (subscription != null) {
      entries.setName(subscription.getTitle());
      entries.setMessage(subscription.getFeed().getMessage());
      entries.setErrorCount(subscription.getFeed().getErrorCount());
      entries.setFeedLink(subscription.getFeed().getLink());

      List<FeedEntryStatus> list = feedEntryStatusDAO.findBySubscriptions(user, Arrays.asList(subscription), unreadOnly,
          entryKeywords, newerThanDate, offset, limit + 1, order, true, onlyIds, null);

      for (FeedEntryStatus status : list) {
        entries.getEntries().add(
            Entry.build(status, config.getApplicationSettings().getPublicUrl(), config.getApplicationSettings()
                .isImageProxyEnabled()));
      }

      boolean hasMore = entries.getEntries().size() > limit;
      if (hasMore) {
        entries.setHasMore(true);
        entries.getEntries().remove(entries.getEntries().size() - 1);
      }
    } else {
      return Response.status(Status.NOT_FOUND).entity("<message>feed not found</message>").build();
    }

    entries.setTimestamp(System.currentTimeMillis());
    entries.setIgnoredReadStatus(keywords != null);
    FeedUtils.removeUnwantedFromSearch(entries.getEntries(), entryKeywords);
    return Response.ok(entries).build();
  }
View Full Code Here

Examples of com.commafeed.frontend.model.Entries

    Response response = getFeedEntries(user, id, readType, newerThan, offset, limit, order, keywords, onlyIds);
    if (response.getStatus() != Status.OK.getStatusCode()) {
      return response;
    }
    Entries entries = (Entries) response.getEntity();

    SyndFeed feed = new SyndFeedImpl();
    feed.setFeedType("rss_2.0");
    feed.setTitle("CommaFeed - " + entries.getName());
    feed.setDescription("CommaFeed - " + entries.getName());
    String publicUrl = config.getApplicationSettings().getPublicUrl();
    feed.setLink(publicUrl);

    List<SyndEntry> children = Lists.newArrayList();
    for (Entry entry : entries.getEntries()) {
      children.add(entry.asRss());
    }
    feed.setEntries(children);

    SyndFeedOutput output = new SyndFeedOutput();
View Full Code Here

Examples of com.hp.jena.rules.retelike.impl.scratch.Entries

    public Binder( Consumer<Entries> consumer )
        { this( null, consumer ); }
   
    public void consume( Triple triple )
        {
        Entries bound = new Entries();
        if (tripleTerm.bind( triple, bound )) consumer.consume( bound );
        }
View Full Code Here

Examples of com.hp.jena.rules.retelike.impl.scratch.Entries

    public static List<Entries> bindingsList( String seq )
        {
        List<Entries> result = new ArrayList<Entries>();
        if (seq.length() > 0)
            for (String bindings: seq.split( " *; *" ))
                result.add( new Entries( TestBindings.nodeBindings( bindings ) ) );
        return result;
        }
View Full Code Here

Examples of com.hp.jena.rules.retelike.impl.scratch.Entries

            result.add( TestTripleTerm.tripleTerm( oneTerm ) );
        return result;
        }

    private Entries binding( Node x, Node y )
        { return new Entries().set( x, y ); }
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.