public class FetchMeta extends Object
Modifier and Type | Class and Description |
---|---|
static class |
FetchMeta.Builder |
Constructor and Description |
---|
FetchMeta(Integer r,
Integer pr,
Boolean notFoundOK,
Boolean basicQuorum,
Boolean headOnly,
Boolean returnDeletedVClock,
Date ifModifiedSince,
VClock ifModifiedVClock,
Integer timeout)
Create a fetch meta with the specified parameters for a conditional fetch
with the either API
|
FetchMeta(Quorum r,
Quorum pr,
Boolean notFoundOK,
Boolean basicQuorum,
Boolean headOnly,
Boolean returnDeletedVClock,
Date ifModifiedSince,
VClock ifModifiedVClock,
Integer timeout)
Create a fetch meta with the specified parameters for a conditional fetch
with the either API
|
Modifier and Type | Method and Description |
---|---|
Boolean |
getBasicQuorum() |
Boolean |
getHeadOnly() |
Date |
getIfModifiedSince()
The date for an HTTP fetch if-modified-since.
|
VClock |
getIfModifiedVClock()
The
VClock to use in a conditional fetch with the PB API. |
Boolean |
getNotFoundOK() |
Quorum |
getPr() |
Quorum |
getR() |
Boolean |
getReturnDeletedVClock() |
Integer |
getTimeout()
Returns the timeout value if set, otherwise null
|
boolean |
hasBasicQuorum() |
boolean |
hasHeadOnly() |
boolean |
hasNotFoundOk() |
boolean |
hasPr() |
boolean |
hasR() |
boolean |
hasReturnDeletedVClock() |
boolean |
hasTimeout()
Returns true if the timeout parameter is set, otherwise false
|
static FetchMeta |
head() |
static FetchMeta |
withR(int readQuorum)
Convenient way to create a fetch meta with just an r value
|
public FetchMeta(Integer r, Integer pr, Boolean notFoundOK, Boolean basicQuorum, Boolean headOnly, Boolean returnDeletedVClock, Date ifModifiedSince, VClock ifModifiedVClock, Integer timeout)
r
- how many vnodes must replypr
- how many primary vnodes must reply, takes precedence over rnotFoundOK
- if a notfound response counts towards satisfying the r valuebasicQuorum
- if after a quorum of notfounds/error return at onceheadOnly
- only return the object meta, not its valuereturnDeletedVClock
- if an object has been deleted, return the tombstone vclockifModifiedSince
- a date for conditional get. Not null value means only return a
value if the last_modified date is later than this date *NOTE*
only for HTTP API!!!ifModifiedVClock
- a vclock for conditional get. Not null value means only return
a value if the current vclock does not match this one. *NOTE*
Only for PB API!public FetchMeta(Quorum r, Quorum pr, Boolean notFoundOK, Boolean basicQuorum, Boolean headOnly, Boolean returnDeletedVClock, Date ifModifiedSince, VClock ifModifiedVClock, Integer timeout)
r
- how many vnodes must replypr
- how many primary vnodes must reply, takes precedence over rnotFoundOK
- if a notfound response counts towards satisfying the r valuebasicQuorum
- if after a quorum of notfounds/error return at onceheadOnly
- only return the object meta, not its valuereturnDeletedVClock
- if an object has been deleted, return the tombstone vclockifModifiedSince
- a date for conditional get. Not null value means only return a
value if the last_modified date is later than this date *NOTE*
only for HTTP API!!!ifModifiedVClock
- a vclock for conditional get. Not null value means only return
a value if the current vclock does not match this one. *NOTE*
Only for PB API!public boolean hasR()
public Quorum getR()
public boolean hasPr()
public Quorum getPr()
public boolean hasNotFoundOk()
public Boolean getNotFoundOK()
public boolean hasBasicQuorum()
public Boolean getBasicQuorum()
public boolean hasHeadOnly()
public Boolean getHeadOnly()
public boolean hasReturnDeletedVClock()
public Boolean getReturnDeletedVClock()
public VClock getIfModifiedVClock()
VClock
to use in a conditional fetch with the PB API.VClock
value, null means this fetch is not
conditional.public Date getIfModifiedSince()
public boolean hasTimeout()
public Integer getTimeout()
public static FetchMeta withR(int readQuorum)
readQuorum
- FetchMeta
with just an R valuepublic static FetchMeta head()
headOnly
Copyright © 2013. All Rights Reserved.