R - the concrete ProjectRequest typepublic class ProjectGenerationInvoker<R extends ProjectRequest> extends Object
ProjectRequest and trigger project generation based on the request.| Modifier | Constructor and Description |
|---|---|
protected |
ProjectGenerationInvoker(org.springframework.context.ApplicationContext parentApplicationContext,
org.springframework.context.ApplicationEventPublisher eventPublisher,
ProjectRequestToDescriptionConverter<R> requestConverter) |
|
ProjectGenerationInvoker(org.springframework.context.ApplicationContext parentApplicationContext,
ProjectRequestToDescriptionConverter<R> requestConverter) |
| Modifier and Type | Method and Description |
|---|---|
void |
cleanTempFiles(Path dir)
Clean all the temporary files that are related to this root directory.
|
Path |
createDistributionFile(Path dir,
String extension)
Create a file in the same directory as the given directory using the directory name
and extension.
|
byte[] |
invokeBuildGeneration(R request)
Invokes the project generation API that knows how to just write the build file.
|
ProjectGenerationResult |
invokeProjectStructureGeneration(R request)
Invokes the project generation API that generates the entire project structure for
the specified
ProjectRequest. |
public ProjectGenerationInvoker(org.springframework.context.ApplicationContext parentApplicationContext,
ProjectRequestToDescriptionConverter<R> requestConverter)
protected ProjectGenerationInvoker(org.springframework.context.ApplicationContext parentApplicationContext,
org.springframework.context.ApplicationEventPublisher eventPublisher,
ProjectRequestToDescriptionConverter<R> requestConverter)
public ProjectGenerationResult invokeProjectStructureGeneration(R request)
ProjectRequest.request - the project requestProjectGenerationResultpublic byte[] invokeBuildGeneration(R request)
ProjectRequest.request - the project requestpublic Path createDistributionFile(Path dir, String extension)
dir - the directory used to determine the path and name of the new fileextension - the extension to use for the new filepublic void cleanTempFiles(Path dir)
dir - the directory to cleancreateDistributionFile(java.nio.file.Path, java.lang.String)Copyright © 2020 Pivotal Software, Inc.. All rights reserved.