Enum ClassInjector.UsingLookup.Dispatcher.ForLegacyVm

    • Constructor Detail

      • ForLegacyVm

        private ForLegacyVm()
    • Method Detail

      • values

        public static ClassInjector.UsingLookup.Dispatcher.ForLegacyVm[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (ClassInjector.UsingLookup.Dispatcher.ForLegacyVm c : ClassInjector.UsingLookup.Dispatcher.ForLegacyVm.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ClassInjector.UsingLookup.Dispatcher.ForLegacyVm valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • lookupType

        public java.lang.Class<?> lookupType​(java.lang.Object lookup)
        Returns the lookup type for a given method handle lookup.
        Specified by:
        lookupType in interface ClassInjector.UsingLookup.Dispatcher
        Parameters:
        lookup - The lookup instance.
        Returns:
        The lookup type.
      • lookupModes

        public int lookupModes​(java.lang.Object lookup)
        Returns a lookup objects lookup types.
        Specified by:
        lookupModes in interface ClassInjector.UsingLookup.Dispatcher
        Parameters:
        lookup - The lookup instance.
        Returns:
        The modifiers indicating the instance's lookup modes.
      • resolve

        public java.lang.Object resolve​(java.lang.Object lookup,
                                        java.lang.Class<?> type)
        Resolves the supplied lookup instance's access scope for the supplied type.
        Specified by:
        resolve in interface ClassInjector.UsingLookup.Dispatcher
        Parameters:
        lookup - The lookup to use.
        type - The type to resolve the scope for.
        Returns:
        An appropriate lookup instance.
      • defineClass

        public java.lang.Class<?> defineClass​(java.lang.Object lookup,
                                              byte[] binaryRepresentation)
        Defines a class.
        Specified by:
        defineClass in interface ClassInjector.UsingLookup.Dispatcher
        Parameters:
        lookup - The java.lang.invoke.MethodHandles$Lookup instance to use.
        binaryRepresentation - The defined class's binary representation.
        Returns:
        The defined class.