Top Description Inners Fields Constructors Methods
reactor.blockhound

pack-priv Class AllowancesByteBuddyTransformer

extends Object
implements Transformer
Class Inheritance
All Implemented Interfaces
net.bytebuddy.agent.builder.AgentBuilder.Transformer
Imports
net.bytebuddy.agent.builder.AgentBuilder, net.bytebuddy.asm.Advice, .AsmVisitorWrapper, net.bytebuddy.description.annotation.AnnotationDescription, net.bytebuddy.description.method.ParameterDescription, net.bytebuddy.description.type.TypeDescription, net.bytebuddy.dynamic.DynamicType, net.bytebuddy.utility.JavaModule, java.lang.annotation.Documented, .ElementType, .Retention, .RetentionPolicy, java.security.ProtectionDomain, java.util.Map

This transformer applies AllowAdvice to every method registered with BlockHound.Builder#allowBlockingCallsInside(String, String).

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class
pack-priv static @interface

Field Summary

Modifier and TypeField and Description
private Map<String, Map<String, Boolean>>

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public DynamicType.Builder<?>
transform(DynamicType.Builder<?>
The dynamic builder to transform.
builder
,
TypeDescription
The description of the type currently being instrumented.
typeDescription
,
ClassLoader
The class loader of the instrumented class. Might be null to represent the bootstrap class loader.
classLoader
,
JavaModule
The class's module or null if the current VM does not support modules.
module
,
ProtectionDomain
The protection domain of the transformed type or null if not available
protectionDomain
)

Implements net.bytebuddy.agent.builder.AgentBuilder.Transformer.transform.

Allows for a transformation of a net.bytebuddy.dynamic.DynamicType.Builder.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

allowancesback to summary
private Map<String, Map<String, Boolean>> allowances

Constructor Detail

AllowancesByteBuddyTransformerback to summary
pack-priv AllowancesByteBuddyTransformer(Map<String, Map<String, Boolean>> allowances)

Method Detail

transformback to summary
public DynamicType.Builder<?> transform(DynamicType.Builder<?> builder, TypeDescription typeDescription, ClassLoader classLoader, JavaModule module, ProtectionDomain protectionDomain)

Implements net.bytebuddy.agent.builder.AgentBuilder.Transformer.transform.

Doc from net.bytebuddy.agent.builder.AgentBuilder.Transformer.transform.

Allows for a transformation of a net.bytebuddy.dynamic.DynamicType.Builder.

Parameters
builder:DynamicType.Builder<?>

The dynamic builder to transform.

typeDescription:TypeDescription

The description of the type currently being instrumented.

classLoader:ClassLoader

The class loader of the instrumented class. Might be null to represent the bootstrap class loader.

module:JavaModule

The class's module or null if the current VM does not support modules.

protectionDomain:ProtectionDomain

The protection domain of the transformed type or null if not available

Returns:DynamicType.Builder<?>

A transformed version of the supplied builder.

Annotations
@Override
reactor.blockhound back to summary

pack-priv Class AllowancesByteBuddyTransformer.AllowAdvice

extends Object
Class Inheritance
  • java.lang.Object
  • reactor.blockhound.AllowancesByteBuddyTransformer.AllowAdvice

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
pack-priv static BlockHoundRuntime.State
onEnter(boolean allowed)

pack-priv static void
onExit(BlockHoundRuntime.State previousState, boolean allowed)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

AllowAdviceback to summary
pack-priv AllowAdvice()

Method Detail

onEnterback to summary
pack-priv static BlockHoundRuntime.State onEnter(boolean allowed)
Annotations
@OnMethodEnter
onExitback to summary
pack-priv static void onExit(BlockHoundRuntime.State previousState, boolean allowed)
Annotations
@OnMethodExit
onThrowable:Throwable
reactor.blockhound back to summary

pack-priv @Interface AllowancesByteBuddyTransformer.AllowedArgument

extends Annotation
Annotations
@Documented
@Retention:RUNTIME
@Target:PARAMETER

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
AllowancesByteBuddyTransformer.AllowedArgument.Factory

Binds advice method's argument annotated with AllowedArgument to boolean where `true` means "allowed" and `false" means "disallowed"

Method Summary

Inherited from java.lang.annotation.Annotation:
annotationTypeequalshashCodetoString
reactor.blockhound back to summary

public Class AllowancesByteBuddyTransformer.AllowedArgument.Factory

extends Object
implements Advice.OffsetMapping.Factory<AllowancesByteBuddyTransformer.AllowedArgument>
Class Inheritance
  • java.lang.Object
  • reactor.blockhound.AllowancesByteBuddyTransformer.AllowedArgument.Factory
All Implemented Interfaces
net.bytebuddy.asm.Advice.OffsetMapping.Factory

Binds advice method's argument annotated with AllowedArgument to boolean where `true` means "allowed" and `false" means "disallowed"

Field Summary

Modifier and TypeField and Description
pack-priv final Map<String, Boolean>

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public Class<AllowancesByteBuddyTransformer.AllowedArgument>
getAnnotationType()

Implements net.bytebuddy.asm.Advice.OffsetMapping.Factory.getAnnotationType.

Returns the annotation type of this factory.
public Advice.OffsetMapping
make(ParameterDescription.InDefinedShape
The parameter description for which to resolve an offset mapping.
target
,
AnnotationDescription.Loadable<AllowancesByteBuddyTransformer.AllowedArgument>
The annotation that triggered this factory.
annotation
,
Advice.OffsetMapping.Factory.AdviceType
true if the binding is applied using advice method delegation.
adviceType
)

Implements net.bytebuddy.asm.Advice.OffsetMapping.Factory.make.

Creates a new offset mapping for the supplied parameter if possible.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

methodsback to summary
pack-priv final Map<String, Boolean> methods

Constructor Detail

Factoryback to summary
pack-priv Factory(Map<String, Boolean> methods)

Method Detail

getAnnotationTypeback to summary
public Class<AllowancesByteBuddyTransformer.AllowedArgument> getAnnotationType()

Implements net.bytebuddy.asm.Advice.OffsetMapping.Factory.getAnnotationType.

Doc from net.bytebuddy.asm.Advice.OffsetMapping.Factory.getAnnotationType.

Returns the annotation type of this factory.

Returns:Class<AllowancesByteBuddyTransformer.AllowedArgument>

The factory's annotation type.

Annotations
@Override
makeback to summary
public Advice.OffsetMapping make(ParameterDescription.InDefinedShape target, AnnotationDescription.Loadable<AllowancesByteBuddyTransformer.AllowedArgument> annotation, Advice.OffsetMapping.Factory.AdviceType adviceType)

Implements net.bytebuddy.asm.Advice.OffsetMapping.Factory.make.

Doc from net.bytebuddy.asm.Advice.OffsetMapping.Factory.make.

Creates a new offset mapping for the supplied parameter if possible.

Parameters
target:ParameterDescription.InDefinedShape

The parameter description for which to resolve an offset mapping.

annotation:AnnotationDescription.Loadable<AllowancesByteBuddyTransformer.AllowedArgument>

The annotation that triggered this factory.

adviceType:Advice.OffsetMapping.Factory.AdviceType

true if the binding is applied using advice method delegation.

Returns:Advice.OffsetMapping

A resolved offset mapping or null if no mapping can be resolved for this parameter.

Annotations
@Override