Package org.springframework.aot.generate
Interface ClassGenerator
- All Known Implementing Classes:
GeneratedClasses
public interface ClassGenerator
Generates new
GeneratedClass
instances.- Since:
- 6.0
- Author:
- Phillip Webb
- See Also:
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic interface
Strategy used to generate the java file for the generated class. -
Method Summary
Modifier and TypeMethodDescriptiongetOrGenerateClass
(ClassGenerator.JavaFileGenerator javaFileGenerator, Class<?> target, String featureName) Get or generate a newGeneratedClass
for a given java file generator, target and feature name.getOrGenerateClass
(ClassGenerator.JavaFileGenerator javaFileGenerator, String target, String featureName) Get or generate a newGeneratedClass
for a given java file generator, target and feature name.
-
Method Details
-
getOrGenerateClass
GeneratedClass getOrGenerateClass(ClassGenerator.JavaFileGenerator javaFileGenerator, Class<?> target, String featureName) Get or generate a newGeneratedClass
for a given java file generator, target and feature name.- Parameters:
javaFileGenerator
- the java file generatortarget
- the target of the newly generated classfeatureName
- the name of the feature that the generated class supports- Returns:
- a
GeneratedClass
instance
-
getOrGenerateClass
GeneratedClass getOrGenerateClass(ClassGenerator.JavaFileGenerator javaFileGenerator, String target, String featureName) Get or generate a newGeneratedClass
for a given java file generator, target and feature name.- Parameters:
javaFileGenerator
- the java file generatortarget
- the target of the newly generated classfeatureName
- the name of the feature that the generated class supports- Returns:
- a
GeneratedClass
instance
-