@NotThreadSafe public static final class ImmutableMixinClass.Builder extends Object
ImmutableMixinClass.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
| Modifier and Type | Method and Description |
|---|---|
ImmutableMixinClass.Builder |
addAllInterfaces(Iterable<? extends org.objectweb.asm.Type> elements)
Adds elements to
interfaces list. |
ImmutableMixinClass.Builder |
addInterfaces(org.objectweb.asm.Type... elements)
Adds elements to
interfaces list. |
ImmutableMixinClass.Builder |
addInterfaces(org.objectweb.asm.Type element)
Adds one element to
interfaces list. |
ImmutableMixinClass |
build()
Builds a new
ImmutableMixinClass. |
ImmutableMixinClass.Builder |
bytes(byte... bytes)
Initializes the value for the
bytes attribute. |
ImmutableMixinClass.Builder |
copyFrom(org.glowroot.agent.weaving.PluginDetail.MixinClass instance)
Fill a builder with attribute values from the provided
MixinClass instance. |
ImmutableMixinClass.Builder |
initMethodName(String initMethodName)
Initializes the value for the
initMethodName attribute. |
ImmutableMixinClass.Builder |
interfaces(Iterable<? extends org.objectweb.asm.Type> elements)
Sets or replaces all elements for
interfaces list. |
ImmutableMixinClass.Builder |
mixin(Mixin mixin)
Initializes the value for the
mixin attribute. |
ImmutableMixinClass.Builder |
type(org.objectweb.asm.Type type)
Initializes the value for the
type attribute. |
public final ImmutableMixinClass.Builder addAllInterfaces(Iterable<? extends org.objectweb.asm.Type> elements)
interfaces list.elements - An iterable of interfaces elementsthis builder for use in a chained invocationpublic final ImmutableMixinClass.Builder addInterfaces(org.objectweb.asm.Type... elements)
interfaces list.elements - An array of interfaces elementsthis builder for use in a chained invocationpublic final ImmutableMixinClass.Builder addInterfaces(org.objectweb.asm.Type element)
interfaces list.element - A interfaces elementthis builder for use in a chained invocationpublic ImmutableMixinClass build()
ImmutableMixinClass.IllegalStateException - if any required attributes are missingpublic final ImmutableMixinClass.Builder bytes(byte... bytes)
bytes attribute.bytes - The elements for bytesthis builder for use in a chained invocationpublic final ImmutableMixinClass.Builder copyFrom(org.glowroot.agent.weaving.PluginDetail.MixinClass instance)
MixinClass instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.
Collection elements and entries will be added, not replaced.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final ImmutableMixinClass.Builder initMethodName(@Nullable String initMethodName)
initMethodName attribute.initMethodName - The value for initMethodName (can be null)this builder for use in a chained invocationpublic final ImmutableMixinClass.Builder interfaces(Iterable<? extends org.objectweb.asm.Type> elements)
interfaces list.elements - An iterable of interfaces elementsthis builder for use in a chained invocationpublic final ImmutableMixinClass.Builder mixin(Mixin mixin)
mixin attribute.mixin - The value for mixinthis builder for use in a chained invocationpublic final ImmutableMixinClass.Builder type(org.objectweb.asm.Type type)
type attribute.type - The value for typethis builder for use in a chained invocationCopyright © 2011–2020 Glowroot contributors. All rights reserved.