public interface RecordComponentRegistry
RecordComponentAttributeAppender
. Record components
can be uniquely identified by their name for a given type since record components are never inherited.
This registry is the counterpart of a
MethodRegistry
.
However, a record component registry is implemented simpler since it does not have to deal with complex signatures or
inheritance. For the sake of consistency, the record component registry follows however a similar pattern without introducing
unnecessary complexity.Modifier and Type | Interface and Description |
---|---|
static interface |
RecordComponentRegistry.Compiled
Represents a compiled record component registry.
|
static class |
RecordComponentRegistry.Default
An immutable default implementation of a record component registry.
|
Modifier and Type | Method and Description |
---|---|
RecordComponentRegistry.Compiled |
compile(TypeDescription instrumentedType)
Prepares the record component registry for a given instrumented type.
|
RecordComponentRegistry |
prepend(LatentMatcher<? super RecordComponentDescription> matcher,
RecordComponentAttributeAppender.Factory recordComponentAttributeAppenderFactory,
Transformer<RecordComponentDescription> transformer)
Prepends the given record component definition to this record component registry, i.e.
|
RecordComponentRegistry prepend(LatentMatcher<? super RecordComponentDescription> matcher, RecordComponentAttributeAppender.Factory recordComponentAttributeAppenderFactory, Transformer<RecordComponentDescription> transformer)
matcher
- The matcher to identify any record component that this definition concerns.recordComponentAttributeAppenderFactory
- The record component attribute appender factory to apply on any matched record component.transformer
- The record component transformer to apply to any matched record component.RecordComponentRegistry.Compiled compile(TypeDescription instrumentedType)
instrumentedType
- The instrumented type.Copyright © 2014–2025. All rights reserved.