Class InlineBytecodeGenerator
java.lang.Object
org.mockito.internal.creation.bytebuddy.InlineBytecodeGenerator
- All Implemented Interfaces:
ClassFileTransformer,BytecodeGenerator
@SuppressSignatureCheck
public class InlineBytecodeGenerator
extends Object
implements BytecodeGenerator, ClassFileTransformer
-
Constructor Summary
ConstructorsConstructorDescriptionInlineBytecodeGenerator(Instrumentation instrumentation, WeakConcurrentMap<Object, MockMethodInterceptor> mocks, DetachedThreadLocal<Map<Class<?>, MockMethodInterceptor>> mockedStatics, Predicate<Class<?>> isMockConstruction, ConstructionCallback onConstruction) -
Method Summary
Modifier and TypeMethodDescriptionvoid<T> Class<? extends T> mockClass(org.mockito.internal.creation.bytebuddy.MockFeatures<T> features) voidmockClassConstruction(Class<?> type) voidmockClassStatic(Class<?> type) byte[]transform(ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.instrument.ClassFileTransformer
transform
-
Constructor Details
-
InlineBytecodeGenerator
public InlineBytecodeGenerator(Instrumentation instrumentation, WeakConcurrentMap<Object, MockMethodInterceptor> mocks, DetachedThreadLocal<Map<Class<?>, MockMethodInterceptor>> mockedStatics, Predicate<Class<?>> isMockConstruction, ConstructionCallback onConstruction)
-
-
Method Details
-
mockClass
public <T> Class<? extends T> mockClass(org.mockito.internal.creation.bytebuddy.MockFeatures<T> features) - Specified by:
mockClassin interfaceBytecodeGenerator
-
mockClassStatic
- Specified by:
mockClassStaticin interfaceBytecodeGenerator
-
mockClassConstruction
- Specified by:
mockClassConstructionin interfaceBytecodeGenerator
-
transform
public byte[] transform(ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer) - Specified by:
transformin interfaceClassFileTransformer
-
clearAllCaches
public void clearAllCaches()- Specified by:
clearAllCachesin interfaceBytecodeGenerator
-