Class Scaffolder
java.lang.Object
io.github.josemodi97.sageactive4j.scaffold.Scaffolder
Writes the example files for a
Framework. Shared, as source, by the
Maven plugin and the standalone Gradle plugin build, so the two can't
generate different code.
plain:sageactive4j/SageActiveExample.java, amainthat prints the user profile and the first customers.servlet/jakarta:sageactive4j/SageActiveServlet.java, browser sign-in at/sage/loginand/sage/callback.spring-boot2/spring-boot3:sageactive4j/SageController.java(/sage/accounting/accounts,/sage/sales/invoice) plussageactive4j.properties, which it loads.
force is set.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classstatic interfaceWhere the plugin's log output goes. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic List<Scaffolder.GeneratedFile>The filesframeworkgets, rendered.What the user still has to do, one line per step.write(List<Scaffolder.GeneratedFile> files, boolean force, Scaffolder.Log log) Writesfiles, skipping (and logging) any that exist unlessforceis set.
-
Field Details
-
PROPERTIES_FILE
- See Also:
-
-
Method Details
-
filesFor
public static List<Scaffolder.GeneratedFile> filesFor(Framework framework, Path javaSourceDir, Path resourceDir, String generator) The filesframeworkgets, rendered.- Parameters:
generator- how the user ran the generator, quoted in the file header (e.g.sageactive4j:init)
-
write
public static List<Path> write(List<Scaffolder.GeneratedFile> files, boolean force, Scaffolder.Log log) throws IOException Writesfiles, skipping (and logging) any that exist unlessforceis set.- Returns:
- the files actually written
- Throws:
IOException
-
nextSteps
What the user still has to do, one line per step.- Parameters:
version- the sageactive4j version to suggest, ornullartifactDeclared- whether the project already declares the needed artifact
-