org.jclouds.collect
Class PagedIterables

java.lang.Object
  extended by org.jclouds.collect.PagedIterables

@Beta
public class PagedIterables
extends Object

Utilities for using PagedIterables.

Author:
Adrian Cole

Field Summary
static PagedIterable EMPTY
           
 
Constructor Summary
PagedIterables()
           
 
Method Summary
static
<T> PagedIterable<T>
advance(IterableWithMarker<T> initial, com.google.common.base.Function<Object,IterableWithMarker<T>> markerToNext)
           
static
<T> Iterator<IterableWithMarker<T>>
advancingIterator(IterableWithMarker<T> initial, com.google.common.base.Function<Object,IterableWithMarker<T>> markerToNext)
           
static
<T> PagedIterable<T>
of(IterableWithMarker<T> only)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EMPTY

public static final PagedIterable EMPTY
Constructor Detail

PagedIterables

public PagedIterables()
Method Detail

of

public static <T> PagedIterable<T> of(IterableWithMarker<T> only)
Parameters:
only - the only page of data
Returns:
iterable with only the one page

advance

public static <T> PagedIterable<T> advance(IterableWithMarker<T> initial,
                                           com.google.common.base.Function<Object,IterableWithMarker<T>> markerToNext)
Parameters:
initial - the initial set current data
markerToNext - produces the next set based on the marker
Returns:
iterable current data which continues if the user iterates beyond the first page

advancingIterator

public static <T> Iterator<IterableWithMarker<T>> advancingIterator(IterableWithMarker<T> initial,
                                                                    com.google.common.base.Function<Object,IterableWithMarker<T>> markerToNext)
Parameters:
initial - the initial set current data
markerToNext - produces the next set based on the marker
Returns:
iterable current data which continues if the user iterates beyond the first page


Copyright © 2009-2013 jclouds. All Rights Reserved.