@Test public void testIterable() { final ArrayList<String> strings = Lists.newArrayList(); buildFirstPage().iterable().forEach(strings::add); assertResults(strings); }
public Iterable<T> iterable() { return new ResourceCollectionIterable<>(this); }
ResourceCollection { public Iterable<T> iterable() { return new ResourceCollectionIterable<>(this); } }
ResourceCollection { public Iterable<T> iterable() { return new ResourceCollectionIterable<>(this); } ResourceCollection(List<T> items, List<ResourceLink> links, NakadiClient client); }
ResourceCollection { public Iterable<T> iterable() { return new ResourceCollectionIterable<>(this); } ResourceCollection(List<T> items, List<ResourceLink> links, NakadiClient client); abstract ResourceCollection<T> fetchPage(String url); ResourceCollection<T> emptyPage(); ResourceCollection<T> nextPage(); List<T> items(); List<ResourceLink> links(); boolean hasNextLink(); Optional<URI> findLink(String rel); Iterable<T> iterable(); @Override int hashCode(); @Override boolean equals(Object o); @Override String toString(); }
ResourceCollection { public Iterable<T> iterable() { return new ResourceCollectionIterable<>(this); } ResourceCollection(List<T> items, List<ResourceLink> links, NakadiClient client); abstract ResourceCollection<T> fetchPage(String url); ResourceCollection<T> emptyPage(); ResourceCollection<T> nextPage(); List<T> items(); List<ResourceLink> links(); boolean hasNextLink(); Optional<URI> findLink(String rel); Iterable<T> iterable(); @Override int hashCode(); @Override boolean equals(Object o); @Override String toString();  }