Class LockManagerServiceImpl

  • All Implemented Interfaces:
    LockManagerService, org.opendaylight.yangtools.yang.binding.RpcService

    @Singleton
    public class LockManagerServiceImpl
    extends java.lang.Object
    implements LockManagerService
    • Constructor Summary

      Constructors 
      Constructor Description
      LockManagerServiceImpl​(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker, LockManagerUtils lockManagerUtils)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<LockOutput>> lock​(LockInput input)
      Method that checks if its locked already.
      com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<TryLockOutput>> tryLock​(TryLockInput input)
      Method that checks if its locked already.
      com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<UnlockOutput>> unlock​(UnlockInput input)
      Method that removes the lock from the list of locks
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • LockManagerServiceImpl

        @Inject
        public LockManagerServiceImpl​(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker,
                                      LockManagerUtils lockManagerUtils)
    • Method Detail

      • lock

        public com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<LockOutput>> lock​(LockInput input)
        Description copied from interface: LockManagerService
        Method that checks if its locked already. If not adds the lock to the list of locks. Else tries until it acquires the lock
        Specified by:
        lock in interface LockManagerService
      • tryLock

        public com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<TryLockOutput>> tryLock​(TryLockInput input)
        Description copied from interface: LockManagerService
        Method that checks if its locked already. If not adds the lock to the list of locks. Else tries for the specified time
        Specified by:
        tryLock in interface LockManagerService