Package net.bytebuddy.implementation
Interface Implementation.Context.ExtractableView
- All Superinterfaces:
Implementation.Context
,MethodAccessorFactory
- All Known Implementing Classes:
Implementation.Context.Default
,Implementation.Context.Disabled
,Implementation.Context.ExtractableView.AbstractBase
- Enclosing interface:
Implementation.Context
Represents an extractable view of an
Implementation.Context
which
allows the retrieval of any registered auxiliary type.-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic class
An abstract base implementation of an extractable view of an implementation context.Nested classes/interfaces inherited from interface net.bytebuddy.implementation.Implementation.Context
Implementation.Context.Default, Implementation.Context.Disabled, Implementation.Context.ExtractableView, Implementation.Context.Factory, Implementation.Context.FrameGeneration
Nested classes/interfaces inherited from interface net.bytebuddy.implementation.MethodAccessorFactory
MethodAccessorFactory.AccessType, MethodAccessorFactory.Illegal
-
Method Summary
Modifier and TypeMethodDescriptionvoid
drain
(TypeInitializer.Drain drain, org.objectweb.asm.ClassVisitor classVisitor, AnnotationValueFilter.Factory annotationValueFilterFactory) Writes any information that was registered with anImplementation.Context
to the provided class visitor.Returns anyAuxiliaryType
that was registered with thisImplementation.Context
.boolean
Returnstrue
if this implementation context permits the registration of any implicit type initializers.Methods inherited from interface net.bytebuddy.implementation.Implementation.Context
cache, getClassFileVersion, getFrameGeneration, getInstrumentedType, register
Methods inherited from interface net.bytebuddy.implementation.MethodAccessorFactory
registerAccessorFor, registerGetterFor, registerSetterFor
-
Method Details
-
isEnabled
boolean isEnabled()Returnstrue
if this implementation context permits the registration of any implicit type initializers.- Returns:
true
if this implementation context permits the registration of any implicit type initializers.
-
getAuxiliaryTypes
List<DynamicType> getAuxiliaryTypes()Returns anyAuxiliaryType
that was registered with thisImplementation.Context
.- Returns:
- A list of all manifested registered auxiliary types.
-
drain
void drain(TypeInitializer.Drain drain, org.objectweb.asm.ClassVisitor classVisitor, AnnotationValueFilter.Factory annotationValueFilterFactory) Writes any information that was registered with anImplementation.Context
to the provided class visitor. This contains any fields for value caching, any accessor method and it writes the type initializer. The type initializer must therefore never be written manually.- Parameters:
drain
- The drain to write the type initializer to.classVisitor
- The class visitor to which the extractable view is to be written.annotationValueFilterFactory
- The annotation value filter factory to apply when writing annotation.
-