LambdaMetafactory
| Modifier and Type | Class and Description |
|---|---|
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private static final String[] | |
| private final ClassDesc[] | |
| private final MethodType | |
| private final MethodTypeDesc | |
| private static final boolean | |
| private static final ClassDesc[] | |
| private final ClassDesc | |
| private final MethodTypeDesc | |
| private final String | |
| private static final String | |
| private final ClassEntry | |
| private final String | |
| private static final ClassFileDumper | |
| private final ConstantPoolBuilder | |
| private final boolean |
| Access | Constructor and Description |
|---|---|
| public | InnerClassLambdaMetafactory(MethodHandles.
Stacked automatically by VM; represents a lookup context
with the accessibility privileges of the caller. caller,Stacked automatically by VM; the signature of the
invoked method, which includes the expected static
type of the returned lambda object, and the static
types of the captured arguments for the lambda. In
the event that the implementation method is an
instance method, the first argument in the invocation
signature will correspond to the receiver. factoryType, String Name of the method in the functional interface to
which the lambda or method reference is being
converted, represented as a String. interfaceMethodName, MethodType Type of the method in the functional interface to
which the lambda or method reference is being
converted, represented as a MethodType. interfaceMethodType, MethodHandle The implementation method which should be called (with
suitable adaptation of argument types, return types,
and adjustment for captured arguments) when methods of
the resulting functional interface instance are invoked. implementation, MethodType The signature of the primary functional
interface method after type variables are
substituted with their instantiation from
the capture site dynamicMethodType, boolean Should the lambda be made serializable? If set,
either the target type or one of the additional SAM
types must extend isSerializable, Class<?>[] Serializable.Additional interfaces which the lambda object
should implement. altInterfaces, MethodType[] Method types for additional signatures to be
implemented by invoking the implementation method altMethods)General meta-factory constructor, supporting both standard cases and allowing for uncommon options such as serialization or bridging. |
| Modifier and Type | Method and Description |
|---|---|
| private static String | |
| pack-priv CallSite | Returns: a CallSite, which, when invoked, will return an instance of the functional interfaceImplements abstract java. Build the CallSite. |
| pack-priv static ClassDesc | |
| private void | |
| pack-priv Consumer | forwardingMethod(MethodType methodType)
This method generates a method body which calls the lambda implementation method, converting arguments, as needed. |
| private void | generateClassInitializer(ClassBuilder clb)
Generate a static field and a static initializer that sets this field to an instance of the lambda |
| private void | |
| private Class | Returns: a Class which implements the functional interfaceGenerate a class file which implements the functional interface, define and return the class. |
| private void | generateSerializationFriendlyMethods(ClassBuilder clb)
Generate a writeReplace method that supports serialization |
| private void | generateSerializationHostileMethods(ClassBuilder clb)
Generate a readObject/writeObject method that is hostile to serialization |
| pack-priv static ClassDesc | |
| private Opcode | |
| private static String | |
| pack-priv static MethodTypeDesc | |
| private static String | |
| private Class |
| ARG_NAME_CACHE | back to summary |
|---|---|
| private static final String[] ARG_NAME_CACHE
| |
| argDescs | back to summary |
|---|---|
| private final ClassDesc[] argDescs | |
| constructorType | back to summary |
|---|---|
| private final MethodType constructorType | |
| constructorTypeDesc | back to summary |
|---|---|
| private final MethodTypeDesc constructorTypeDesc | |
| disableEagerInitialization | back to summary |
|---|---|
| private static final boolean disableEagerInitialization | |
| EMPTY_CLASSDESC_ARRAY | back to summary |
|---|---|
| private static final ClassDesc[] EMPTY_CLASSDESC_ARRAY | |
| implMethodClassDesc | back to summary |
|---|---|
| private final ClassDesc implMethodClassDesc | |
| implMethodDesc | back to summary |
|---|---|
| private final MethodTypeDesc implMethodDesc | |
| implMethodName | back to summary |
|---|---|
| private final String implMethodName | |
| LAMBDA_INSTANCE_FIELD | back to summary |
|---|---|
| private static final String LAMBDA_INSTANCE_FIELD | |
| lambdaClassEntry | back to summary |
|---|---|
| private final ClassEntry lambdaClassEntry | |
| lambdaClassName | back to summary |
|---|---|
| private final String lambdaClassName | |
| lambdaProxyClassFileDumper | back to summary |
|---|---|
| private static final ClassFileDumper lambdaProxyClassFileDumper | |
| pool | back to summary |
|---|---|
| private final ConstantPoolBuilder pool | |
| useImplMethodHandle | back to summary |
|---|---|
| private final boolean useImplMethodHandle | |
| InnerClassLambdaMetafactory | back to summary |
|---|---|
| public InnerClassLambdaMetafactory(MethodHandles. General meta-factory constructor, supporting both standard cases and allowing for uncommon options such as serialization or bridging.
| |
| argName | back to summary |
|---|---|
| private static String argName(int i) | |
| buildCallSite | back to summary |
|---|---|
| pack-priv CallSite buildCallSite() throws LambdaConversionException Implements abstract java. Build the CallSite. Generate a class file which implements the functional interface, define the class, if there are no parameters create an instance of the class which the CallSite will return, otherwise, generate handles which will call the class' constructor.
| |
| classDesc | back to summary |
|---|---|
| pack-priv static ClassDesc classDesc(Class<?> cls) | |
| convertArgumentTypes | back to summary |
|---|---|
| private void convertArgumentTypes(CodeBuilder cob, MethodType samType) | |
| forwardingMethod | back to summary |
|---|---|
| pack-priv Consumer This method generates a method body which calls the lambda implementation method, converting arguments, as needed. | |
| generateClassInitializer | back to summary |
|---|---|
| private void generateClassInitializer(ClassBuilder clb) Generate a static field and a static initializer that sets this field to an instance of the lambda | |
| generateConstructor | back to summary |
|---|---|
| private void generateConstructor(ClassBuilder clb) Generate the constructor for the class | |
| generateInnerClass | back to summary |
|---|---|
| private Class Generate a class file which implements the functional interface, define and return the class.
| |
| generateSerializationFriendlyMethods | back to summary |
|---|---|
| private void generateSerializationFriendlyMethods(ClassBuilder clb) Generate a writeReplace method that supports serialization | |
| generateSerializationHostileMethods | back to summary |
|---|---|
| private void generateSerializationHostileMethods(ClassBuilder clb) Generate a readObject/writeObject method that is hostile to serialization | |
| implClassDesc | back to summary |
|---|---|
| pack-priv static ClassDesc implClassDesc(Class<?> cls) | |
| invocationOpcode | back to summary |
|---|---|
| private Opcode invocationOpcode() throws InternalError | |
| lambdaClassName | back to summary |
|---|---|
| private static String lambdaClassName(Class<?> targetClass) | |
| methodDesc | back to summary |
|---|---|
| pack-priv static MethodTypeDesc methodDesc(MethodType mt) | |
| sanitizedTargetClassName | back to summary |
|---|---|
| private static String sanitizedTargetClassName(Class<?> targetClass) | |
| spinInnerClass | back to summary |
|---|---|
| private Class Spins the lambda proxy class. This first checks if a lambda proxy class can be loaded from CDS archive. Otherwise, generate the lambda proxy class. If CDS dumping is enabled, it registers the lambda proxy class for including into the CDS archive. | |
| Modifier and Type | Field and Description |
|---|---|
| pack-priv static final ClassDesc | |
| private static final ClassDesc | |
| private static final ClassDesc | |
| private static final ClassDesc | |
| pack-priv static final MethodTypeDesc | |
| pack-priv static final MethodTypeDesc | |
| private static final MethodTypeDesc | |
| private static final MethodTypeDesc | |
| private static final MethodTypeDesc | |
| private static final String | |
| private static final String | |
| private static final String |
| Access | Constructor and Description |
|---|---|
| private |
| CD_NotSerializableException | back to summary |
|---|---|
| pack-priv static final ClassDesc CD_NotSerializableException | |
| CD_ObjectInputStream | back to summary |
|---|---|
| private static final ClassDesc CD_ObjectInputStream | |
| CD_ObjectOutputStream | back to summary |
|---|---|
| private static final ClassDesc CD_ObjectOutputStream | |
| CD_SerializedLambda | back to summary |
|---|---|
| private static final ClassDesc CD_SerializedLambda | |
| MTD_CTOR_NOT_SERIALIZABLE_EXCEPTION | back to summary |
|---|---|
| pack-priv static final MethodTypeDesc MTD_CTOR_NOT_SERIALIZABLE_EXCEPTION | |
| MTD_CTOR_SERIALIZED_LAMBDA | back to summary |
|---|---|
| pack-priv static final MethodTypeDesc MTD_CTOR_SERIALIZED_LAMBDA | |
| MTD_Object | back to summary |
|---|---|
| private static final MethodTypeDesc MTD_Object | |
| MTD_void_ObjectInputStream | back to summary |
|---|---|
| private static final MethodTypeDesc MTD_void_ObjectInputStream | |
| MTD_void_ObjectOutputStream | back to summary |
|---|---|
| private static final MethodTypeDesc MTD_void_ObjectOutputStream | |
| NAME_METHOD_READ_OBJECT | back to summary |
|---|---|
| private static final String NAME_METHOD_READ_OBJECT | |
| NAME_METHOD_WRITE_OBJECT | back to summary |
|---|---|
| private static final String NAME_METHOD_WRITE_OBJECT | |
| NAME_METHOD_WRITE_REPLACE | back to summary |
|---|---|
| private static final String NAME_METHOD_WRITE_REPLACE | |
| SerializationSupport | back to summary |
|---|---|
| private SerializationSupport() | |