Class AgentBuilder.CircularityLock.Global

java.lang.Object
net.bytebuddy.agent.builder.AgentBuilder.CircularityLock.WithInnerClassLoadingLock
net.bytebuddy.agent.builder.AgentBuilder.CircularityLock.Global
All Implemented Interfaces:
AgentBuilder.CircularityLock
Enclosing interface:
AgentBuilder.CircularityLock

@Enhance public static class AgentBuilder.CircularityLock.Global extends AgentBuilder.CircularityLock.WithInnerClassLoadingLock
A circularity lock that holds a global monitor and does not permit concurrent access.
  • Field Details

    • lock

      private final Lock lock
      The lock to hold.
    • time

      private final long time
      The time to wait for the lock.
    • timeUnit

      private final TimeUnit timeUnit
      The time's time unit.
  • Constructor Details

    • Global

      public Global()
      Creates a new global circularity lock that does not wait for a release and a default size for the amount of global locks.
    • Global

      public Global(long time, TimeUnit timeUnit)
      Creates a new global circularity lock with a default size for the amount of global locks.
      Parameters:
      time - The time to wait for the lock.
      timeUnit - The time's time unit.
    • Global

      public Global(int size)
      Creates a new global circularity lock that does not wait for a release.
      Parameters:
      size - The amount of locks used in parallel or 0 if no global locks should be used.
    • Global

      public Global(int size, long time, TimeUnit timeUnit)
      Creates a new global circularity lock.
      Parameters:
      size - The amount of locks used in parallel or 0 if no global locks should be used.
      time - The time to wait for the lock.
      timeUnit - The time's time unit.
  • Method Details