framework/start/src/org/ofbiz/base/start/Config.java
Config
has 22 methods (exceeds 20 allowed). Consider refactoring. Open
Open
public class Config {
public final InetAddress adminAddress;
public final String adminKey;
public final int adminPort;
Avoid deeply nested control flow statements. Open
Open
if ("dir".equals(type.getNodeValue())) {
classpath.addComponent(path.toString());
}
Avoid deeply nested control flow statements. Open
Open
for (File file: path.listFiles()) {
String fileName = file.getName().toLowerCase();
if (fileName.endsWith(".jar") || fileName.endsWith(".zip")) {
classpath.addComponent(file);
} else if (fileName.endsWith(nativeLibExt)) {
Avoid deeply nested control flow statements. Open
Open
if (containsNativeLibs) {
libraryPath.addComponent(path);
}
Consider simplifying this complex logical expression. Open
Open
if ("start-batch".equalsIgnoreCase(firstArg)
|| "start-debug".equalsIgnoreCase(firstArg)
|| "stop".equalsIgnoreCase(firstArg)
|| "-shutdown".equalsIgnoreCase(firstArg) // shutdown & status hack (was pre-existing to portoffset introduction, also useful with it)
|| "-shutdown-wait".equalsIgnoreCase(firstArg) // shutdown & status hack (SCIPIO)