Cleaned up Javadocs

This commit is contained in:
Erik C. Thauvin 2023-11-27 11:52:48 -08:00
parent 1090f06fdf
commit 6a1dc286da
6 changed files with 80 additions and 11 deletions

View file

@ -46,6 +46,8 @@ public class GeneratedVersion {
/**
* Returns the class name.
*
* @return the class name
*/
public String getClassName() {
return className;
@ -53,6 +55,8 @@ public class GeneratedVersion {
/**
* Returns the destination directory.
*
* @return the destination directory
*/
public File getDirectory() {
return directory;
@ -60,6 +64,8 @@ public class GeneratedVersion {
/**
* Returns the file extension.
*
* @return the file extension
*/
public String getExtension() {
return extension;
@ -67,6 +73,8 @@ public class GeneratedVersion {
/**
* Returns the package name.
*
* @return the package name
*/
public String getPackageName() {
return packageName;
@ -74,6 +82,8 @@ public class GeneratedVersion {
/**
* Returns the project.
*
* @return the project
*/
public BaseProject getProject() {
return project;
@ -81,6 +91,8 @@ public class GeneratedVersion {
/**
* Returns the project name.
*
* @return the project name
*/
public String getProjectName() {
return projectName;
@ -88,6 +100,8 @@ public class GeneratedVersion {
/**
* Returns the template.
*
* @return the template
*/
public File getTemplate() {
return template;
@ -95,6 +109,8 @@ public class GeneratedVersion {
/**
* Sets the class file.
*
* @param classFile the class file
*/
public void setClassFile(File classFile) {
this.classFile = classFile;
@ -102,6 +118,8 @@ public class GeneratedVersion {
/**
* Sets the class name.
*
* @param className the class name
*/
public void setClassName(String className) {
this.className = className;
@ -109,6 +127,8 @@ public class GeneratedVersion {
/**
* Set the destination directory.
*
* @param directory the destination directory
*/
public void setDirectory(File directory) {
this.directory = directory;
@ -116,6 +136,8 @@ public class GeneratedVersion {
/**
* Sets the file extension. (Default is: {@code .java})
*
* @param extension the file extension
*/
public void setExtension(String extension) {
this.extension = extension;
@ -123,6 +145,8 @@ public class GeneratedVersion {
/**
* Sets the package name.
*
* @param packageName the package name
*/
public void setPackageName(String packageName) {
this.packageName = packageName;
@ -130,6 +154,8 @@ public class GeneratedVersion {
/**
* Sets the project.
*
* @param project the project
*/
public void setProject(BaseProject project) {
this.project = project;
@ -137,6 +163,8 @@ public class GeneratedVersion {
/**
* Sets the project name.
*
* @param projectName the project name
*/
public void setProjectName(String projectName) {
this.projectName = projectName;
@ -144,6 +172,8 @@ public class GeneratedVersion {
/**
* Sets the template file.
*
* @param template the template
*/
public void setTemplate(File template) {
this.template = template;

View file

@ -53,6 +53,9 @@ public class GeneratedVersionOperation extends AbstractOperation<GeneratedVersio
/**
* Builds the template based on the {@link GeneratedVersion} data.
*
* @param gv the generated version
* @return the template
*/
public static Template buildTemplate(GeneratedVersion gv) {
Template template;
@ -114,6 +117,9 @@ public class GeneratedVersionOperation extends AbstractOperation<GeneratedVersio
/**
* Writes the project version class in the given directory.
*
* @param template the template
* @param gv the generated version
*/
public static void writeTemplate(Template template, GeneratedVersion gv) {
if (gv.getPackageName() != null) {
@ -149,6 +155,9 @@ public class GeneratedVersionOperation extends AbstractOperation<GeneratedVersio
/**
* Sets the class name.
*
* @param className the class name
* @return this operation instance
*/
public GeneratedVersionOperation className(String className) {
generatedVersion.setClassName(className);
@ -157,6 +166,9 @@ public class GeneratedVersionOperation extends AbstractOperation<GeneratedVersio
/**
* Sets the class template path.
*
* @param template the template path
* @return this operation instance
*/
public GeneratedVersionOperation classTemplate(File template) {
generatedVersion.setTemplate(template);
@ -165,6 +177,9 @@ public class GeneratedVersionOperation extends AbstractOperation<GeneratedVersio
/**
* Sets the destination directory.
*
* @param directory the destination directory
* @return this operation instance
*/
public GeneratedVersionOperation directory(File directory) {
generatedVersion.setDirectory(directory);
@ -186,6 +201,9 @@ public class GeneratedVersionOperation extends AbstractOperation<GeneratedVersio
/**
* Sets the file extension. (Default is: {@code .java})
*
* @param extension the file extension
* @return this operation instance
*/
public GeneratedVersionOperation extension(String extension) {
generatedVersion.setExtension(extension);
@ -194,6 +212,9 @@ public class GeneratedVersionOperation extends AbstractOperation<GeneratedVersio
/**
* Configure the operation from a {@link BaseProject}.
*
* @param project the project
* @return this operation instance
*/
public GeneratedVersionOperation fromProject(BaseProject project) {
generatedVersion.setProject(project);
@ -203,6 +224,9 @@ public class GeneratedVersionOperation extends AbstractOperation<GeneratedVersio
/**
* Sets the package name.
*
* @param packageName the package name
* @return this operation instance
*/
public GeneratedVersionOperation packageName(String packageName) {
generatedVersion.setPackageName(packageName);
@ -211,6 +235,9 @@ public class GeneratedVersionOperation extends AbstractOperation<GeneratedVersio
/**
* Sets the project name.
*
* @param projectName the project name
* @return this operation instance
*/
public GeneratedVersionOperation projectName(String projectName) {
generatedVersion.setProjectName(projectName);