com.netflix.curator.framework.recipes.atomic
Class PromotedToLock.Builder

java.lang.Object
  extended by com.netflix.curator.framework.recipes.atomic.PromotedToLock.Builder
Enclosing class:
PromotedToLock

public static class PromotedToLock.Builder
extends Object


Method Summary
 PromotedToLock build()
          Build the argument block
 PromotedToLock.Builder lockPath(String path)
          Set the path for the mutex lock (required)
 PromotedToLock.Builder retryPolicy(com.netflix.curator.RetryPolicy retryPolicy)
          Set the retry policy to use when an operation does not succeeed (optional)
 PromotedToLock.Builder timeout(long maxLockTime, TimeUnit maxLockTimeUnit)
          Set the timeout to use when locking (optional)
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

build

public PromotedToLock build()
Build the argument block

Returns:
new block

lockPath

public PromotedToLock.Builder lockPath(String path)
Set the path for the mutex lock (required)

Parameters:
path - path
Returns:
this

retryPolicy

public PromotedToLock.Builder retryPolicy(com.netflix.curator.RetryPolicy retryPolicy)
Set the retry policy to use when an operation does not succeeed (optional)

Parameters:
retryPolicy - new policy
Returns:
this

timeout

public PromotedToLock.Builder timeout(long maxLockTime,
                                      TimeUnit maxLockTimeUnit)
Set the timeout to use when locking (optional)

Parameters:
maxLockTime - time
maxLockTimeUnit - unit
Returns:
this


Copyright © 2012. All Rights Reserved.