Enum TypeResolutionStrategy.Lazy

    • Constructor Detail

      • Lazy

        private Lazy()
    • Method Detail

      • values

        public static TypeResolutionStrategy.Lazy[] 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 (TypeResolutionStrategy.Lazy c : TypeResolutionStrategy.Lazy.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static TypeResolutionStrategy.Lazy 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
      • injectedInto

        public TypeInitializer injectedInto​(TypeInitializer typeInitializer)
        Injects a type initializer into the supplied type initializer, if applicable. This way, a type resolution strategy is capable of injecting code into the generated class's initializer to inline the initialization.
        Specified by:
        injectedInto in interface TypeResolutionStrategy.Resolved
        Parameters:
        typeInitializer - The type initializer to potentially expend.
        Returns:
        A type initializer to apply for performing the represented type resolution.
      • initialize

        public <S extends java.lang.ClassLoader> java.util.Map<TypeDescription,​java.lang.Class<?>> initialize​(DynamicType dynamicType,
                                                                                                                    S classLoader,
                                                                                                                    ClassLoadingStrategy<? super S> classLoadingStrategy)
        Loads and initializes a dynamic type.
        Specified by:
        initialize in interface TypeResolutionStrategy.Resolved
        Type Parameters:
        S - The least specific type of class loader this strategy can apply to.
        Parameters:
        dynamicType - The dynamic type to initialize.
        classLoader - The class loader to use.
        classLoadingStrategy - The class loading strategy to use.
        Returns:
        A map of all type descriptions mapped to their representation as a loaded class.