Interface LockProvider

All Known Implementing Classes:
StripedLock

public interface LockProvider
提供获取锁的统一接口。
Author:
xezzon
  • Method Summary

    Modifier and Type
    Method
    Description
    of(String name, int timeout)
    获取锁封装器。
  • Method Details

    • of

      LockAdaptor of(String name, int timeout)
      获取锁封装器。
      Parameters:
      name - 业务类型。
      timeout - 锁的超时时间,超过该时间锁会自动释放,单位为秒。
      Returns:
      锁封装器。