Package net.bytebuddy.agent.builder
Interface AgentBuilder.PoolStrategy
-
- All Known Implementing Classes:
AgentBuilder.PoolStrategy.ClassLoading,AgentBuilder.PoolStrategy.Default,AgentBuilder.PoolStrategy.Eager,AgentBuilder.PoolStrategy.WithTypePoolCache,AgentBuilder.PoolStrategy.WithTypePoolCache.Simple
- Enclosing interface:
- AgentBuilder
public static interface AgentBuilder.PoolStrategyA type locator allows to specify howTypeDescriptions are resolved by anAgentBuilder.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classAgentBuilder.PoolStrategy.ClassLoadingA type locator that attempts loading a type if it cannot be located by the underlying lazy type pool.static classAgentBuilder.PoolStrategy.DefaultA default type locator that resolves types only if any property that is not the type's name is requested.static classAgentBuilder.PoolStrategy.EagerA type locator that resolves all type descriptions eagerly.static classAgentBuilder.PoolStrategy.WithTypePoolCacheA type locator that uses type pools but allows for the configuration of a custom cache provider by class loader.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description TypePooltypePool(ClassFileLocator classFileLocator, java.lang.ClassLoader classLoader)Creates a type pool for a given class file locator.TypePooltypePool(ClassFileLocator classFileLocator, java.lang.ClassLoader classLoader, java.lang.String name)Creates a type pool for a given class file locator.
-
-
-
Method Detail
-
typePool
TypePool typePool(ClassFileLocator classFileLocator, java.lang.ClassLoader classLoader)
Creates a type pool for a given class file locator.- Parameters:
classFileLocator- The class file locator to use.classLoader- The class loader for which the class file locator was created.- Returns:
- A type pool for the supplied class file locator.
-
typePool
TypePool typePool(ClassFileLocator classFileLocator, java.lang.ClassLoader classLoader, java.lang.String name)
Creates a type pool for a given class file locator. If a cache is used, the type that is currently instrumented is not used.- Parameters:
classFileLocator- The class file locator to use.classLoader- The class loader for which the class file locator was created.name- The name of the currently instrumented type.- Returns:
- A type pool for the supplied class file locator.
-
-