com.basho.riak.client.query
Class LinkWalk

java.lang.Object
  extended by com.basho.riak.client.query.LinkWalk
All Implemented Interfaces:
RiakOperation<WalkResult>

public class LinkWalk
extends Object
implements RiakOperation<WalkResult>

A Link Walk operation, build the operation by adding steps, then execute.

Author:
russell
See Also:
IRiakClient.walk(IRiakObject)

Constructor Summary
LinkWalk(RawClient client, IRiakObject startObject)
          Create a Link Walk operation that will be executed with client, starting from startObject
 
Method Summary
 LinkWalk addStep(String bucket, String tag)
          Add a link walking step to this link walk using the default accumulate value for the step (NO for all steps accept last step)
 LinkWalk addStep(String bucket, String tag, boolean keep)
          Add a link walking step to this link walk
 LinkWalk addStep(String bucket, String tag, LinkWalkStep.Accumulate accumulate)
          Add a link walking step to this link walk
 WalkResult execute()
          Run the Link Walk query on the RawClient the operation was constructed with.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LinkWalk

public LinkWalk(RawClient client,
                IRiakObject startObject)
Create a Link Walk operation that will be executed with client, starting from startObject

Parameters:
client - the RawClient to use
startObject - the IRiakObject to start from
Method Detail

execute

public WalkResult execute()
                   throws RiakException
Run the Link Walk query on the RawClient the operation was constructed with.

Specified by:
execute in interface RiakOperation<WalkResult>
Returns:
a WalkResult
Throws:
RiakException

addStep

public LinkWalk addStep(String bucket,
                        String tag,
                        LinkWalkStep.Accumulate accumulate)
Add a link walking step to this link walk

Parameters:
bucket - the bucket, a null, or empty string is treated as the wildcard
tag - the tag of the link, a null or empty string is treated as the wildcard
accumulate - to keep the result of this step or not
Returns:
this

addStep

public LinkWalk addStep(String bucket,
                        String tag,
                        boolean keep)
Add a link walking step to this link walk

Parameters:
bucket - the bucket, a null, or empty string is treated as the wildcard _
tag - the tag of the link, a null or empty string is treated as the wildcard
accumulate - to keep the result of this step or not
Returns:
this

addStep

public LinkWalk addStep(String bucket,
                        String tag)
Add a link walking step to this link walk using the default accumulate value for the step (NO for all steps accept last step)

Parameters:
bucket - the bucket, a null, or empty string is treated as the wildcard _
tag - the tag of the link, a null or empty string is treated as the wildcard
Returns:
this


Copyright © 2012. All Rights Reserved.