Made a code review.

This commit is contained in:
Christian P. MOMON 2020-01-22 19:37:28 +01:00
parent 4e52f3ebd6
commit 4d8d0f4fda
14 changed files with 113 additions and 52 deletions

View File

@ -1,3 +1,3 @@
#Build Number for ANT. Do not edit!
#Wed Jan 22 19:29:14 CET 2020
#Wed Jan 22 19:36:44 CET 2020
build.number=4

View File

@ -38,7 +38,7 @@ public final class SQLUtils
private static Logger logger = LoggerFactory.getLogger(SQLUtils.class);
/**
* Instantiates a new connector.
* Instantiates a new SQL utils.
*/
private SQLUtils()
{
@ -155,12 +155,19 @@ public final class SQLUtils
}
/**
*
* This method launch CLI.
*
* @param args
* necessary arguments
* Gets the connexion.
*
* @param serverUrl
* the server url
* @param databaseName
* the database name
* @param login
* the login
* @param password
* the password
* @return the connexion
* @throws AgirStatoolException
* the agir statool exception
*/
public static Connection getConnexion(final String serverUrl, final String databaseName, final String login, final String password) throws AgirStatoolException
{
@ -207,6 +214,17 @@ public final class SQLUtils
return result;
}
/**
* Gets the nullable long.
*
* @param resultSet
* the result set
* @param index
* the index
* @return the nullable long
* @throws SQLException
* the SQL exception
*/
public static Long getNullableLong(final ResultSet resultSet, final int index) throws SQLException
{
Long result;

View File

@ -224,13 +224,9 @@ public class AgirStatool
/**
* Fetch week concluded count.
*
* In Redmine database: closed_on when resolved, rejected or closed.
*
* @param project
* the project
* @param consolidated
* the consolidated
* @return the date count map
* @throws AgirStatoolException
* the agir statool exception
@ -311,8 +307,6 @@ public class AgirStatool
*
* @param project
* the project
* @param consolidated
* the consolidated
* @return the date count map
* @throws AgirStatoolException
* the agir statool exception
@ -389,9 +383,9 @@ public class AgirStatool
}
/**
* Gets the project all.
* Gets the root project.
*
* @return the project all
* @return the root project
* @throws AgirStatoolException
* the agir statool exception
*/
@ -693,10 +687,10 @@ public class AgirStatool
}
/**
* List projects.
* List projects with stats.
*
* @param consolidated
* the consolidated
* @param type
* the type
* @return the projects
* @throws AgirStatoolException
* the agir statool exception

View File

@ -286,9 +286,13 @@ public class AgirStatoolUtils
}
/**
* To human short.
*
* @param value
* the value
* @param defaultValue
* @return
* the default value
* @return the string
*/
public static String toHumanShort(final LocalDateTime value, final String defaultValue)
{

View File

@ -141,7 +141,9 @@ public class Project
}
/**
* @return
* Checks for issue.
*
* @return true, if successful
*/
public boolean hasIssue()
{

View File

@ -17,8 +17,10 @@ public class ProjectComparator implements Comparator<Project>
private Sorting sorting;
/**
*
* Instantiates a new project comparator.
*
* @param sorting
* the sorting
*/
public ProjectComparator(final Sorting sorting)
{
@ -41,7 +43,15 @@ public class ProjectComparator implements Comparator<Project>
}
/**
*
* Compare.
*
* @param alpha
* the alpha
* @param bravo
* the bravo
* @param sorting
* the sorting
* @return the int
*/
public static int compare(final Project alpha, final Project bravo, final Sorting sorting)
{
@ -74,9 +84,11 @@ public class ProjectComparator implements Comparator<Project>
}
/**
*
* Gets the id.
*
* @param source
* @return
* the source
* @return the id
*/
public static Long getId(final Project source)
{
@ -96,9 +108,11 @@ public class ProjectComparator implements Comparator<Project>
}
/**
*
* Gets the identifier.
*
* @param source
* @return
* the source
* @return the identifier
*/
public static String getIdentifier(final Project source)
{
@ -118,9 +132,11 @@ public class ProjectComparator implements Comparator<Project>
}
/**
*
* Gets the name.
*
* @param source
* @return
* the source
* @return the name
*/
public static String getName(final Project source)
{

View File

@ -40,8 +40,14 @@ public class ChartBarView
/**
* Builds the.
*
* @param projects
* the projects
* @param title
* the title
* @param labelTitle
* the label title
* @param labels
* the labels
* @param values
* the values
* @return the string
* @throws AgirStatoolException
* the agir statool exception

View File

@ -40,8 +40,14 @@ public class ChartPolarView
/**
* Builds the.
*
* @param projects
* the projects
* @param title
* the title
* @param labelTitle
* the label title
* @param labels
* the labels
* @param values
* the values
* @return the string
* @throws AgirStatoolException
* the agir statool exception

View File

@ -97,10 +97,12 @@ public class CreatedConcludedCountChartView
}
/**
* Builds the.
* Builds the full.
*
* @param projects
* the projects
* @param title
* the title
* @param project
* the project
* @return the string
* @throws AgirStatoolException
* the agir statool exception
@ -167,10 +169,15 @@ public class CreatedConcludedCountChartView
}
/**
* Builds the previous year.
*
* @param title
* the title
* @param project
* @return
* the project
* @return the string
* @throws AgirStatoolException
* the agir statool exception
*/
public static String buildPreviousYear(final String title, final Project project) throws AgirStatoolException
{

View File

@ -35,8 +35,10 @@ public class IssueStatChartView
/**
* Builds the.
*
* @param projects
* the projects
* @param title
* the title
* @param project
* the project
* @return the string
* @throws AgirStatoolException
* the agir statool exception
@ -64,8 +66,10 @@ public class IssueStatChartView
/**
* Builds the grouped.
*
* @param stats
* the stats
* @param title
* the title
* @param project
* the project
* @return the string
* @throws AgirStatoolException
* the agir statool exception

View File

@ -39,8 +39,8 @@ public class ProjectPage
/**
* Builds the.
*
* @param projects
* the projects
* @param project
* the project
* @return the string
* @throws AgirStatoolException
* the agir statool exception

View File

@ -42,8 +42,8 @@ public class ProjectsGroupedView
/**
* Builds the.
*
* @param projects
* the projects
* @param project
* the project
* @return the string
* @throws AgirStatoolException
* the agir statool exception

View File

@ -40,8 +40,8 @@ public class ProjectsRawView
/**
* Builds the.
*
* @param projects
* the projects
* @param project
* the project
* @return the string
* @throws AgirStatoolException
* the agir statool exception

View File

@ -34,10 +34,12 @@ public class UnassignedPolarChartView
private static Logger logger = LoggerFactory.getLogger(UnassignedPolarChartView.class);
/**
* Builds the grouped.
* Builds the.
*
* @param stats
* the stats
* @param title
* the title
* @param project
* the project
* @return the string
* @throws AgirStatoolException
* the agir statool exception
@ -64,10 +66,12 @@ public class UnassignedPolarChartView
}
/**
* Builds the.
* Builds the grouped.
*
* @param projects
* the projects
* @param title
* the title
* @param project
* the project
* @return the string
* @throws AgirStatoolException
* the agir statool exception