org.ektorp
Class ViewResult

java.lang.Object
  extended by org.ektorp.ViewResult
All Implemented Interfaces:
Serializable, Iterable<ViewResult.Row>

public class ViewResult
extends Object
implements Iterable<ViewResult.Row>, Serializable

Author:
henrik lundgren
See Also:
Serialized Form

Nested Class Summary
static class ViewResult.Row
           
 
Constructor Summary
ViewResult(org.codehaus.jackson.JsonNode resultNode, boolean ignoreNotFound)
           
 
Method Summary
 int getOffset()
           
 List<ViewResult.Row> getRows()
           
 int getSize()
           
 int getTotalRows()
           
 long getUpdateSeq()
           
 String getUpdateSeqAsString()
           
 boolean isEmpty()
           
 boolean isUpdateSeqNumeric()
           
 Iterator<ViewResult.Row> iterator()
           
 void setUpdateSeq(String updateSeq)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ViewResult

public ViewResult(org.codehaus.jackson.JsonNode resultNode,
                  boolean ignoreNotFound)
Method Detail

getRows

public List<ViewResult.Row> getRows()

getSize

public int getSize()

getOffset

public int getOffset()
Returns:
-1 if result did not contain an offset field

getTotalRows

public int getTotalRows()
Returns:
-1 if result did not contain a total_rows field

getUpdateSeq

public long getUpdateSeq()
Returns:
-1L if result did not contain an update_seq field

isUpdateSeqNumeric

public boolean isUpdateSeqNumeric()
Returns:
false if db is an Cloudant instance.

getUpdateSeqAsString

public String getUpdateSeqAsString()
Returns:
null if result did not contain an update_seq field

setUpdateSeq

public void setUpdateSeq(String updateSeq)

iterator

public Iterator<ViewResult.Row> iterator()
Specified by:
iterator in interface Iterable<ViewResult.Row>

isEmpty

public boolean isEmpty()


Copyright © 2011. All Rights Reserved.