--- a/src/jdk.jpackage/share/classes/jdk/jpackage/internal/DeployParams.java Mon Jun 17 15:38:04 2019 -0400
+++ b/src/jdk.jpackage/share/classes/jdk/jpackage/internal/DeployParams.java Thu Jun 20 14:13:50 2019 -0400
@@ -52,8 +52,7 @@
final List<RelativeFileSet> resources = new ArrayList<>();
- BundlerType bundleType = BundlerType.NONE;
- String targetFormat = null; //means any
+ String targetFormat = null; // means app-image
String licenseType;
String copyright;
String version;
@@ -250,10 +249,10 @@
Arguments.CLIOptions.INPUT.getId()) != null);
boolean hasModulePath = (bundlerArguments.get(
Arguments.CLIOptions.MODULE_PATH.getId()) != null);
- boolean runtimeInstaller = (BundlerType.INSTALLER == getBundleType()) &&
+ boolean runtimeInstaller = targetFormat != null &&
!hasAppImage && !hasModule && !hasMain && hasRuntimeImage;
- if (getBundleType() == BundlerType.IMAGE) {
+ if (targetFormat == null) {
// Module application requires --runtime-image or --module-path
if (hasModule) {
if (!hasModulePath && !hasRuntimeImage) {
@@ -266,7 +265,7 @@
"ERR_MissingArgument", "--input");
}
}
- } else if (getBundleType() == BundlerType.INSTALLER) {
+ } else {
if (!runtimeInstaller) {
if (hasModule) {
if (!hasModulePath && !hasRuntimeImage && !hasAppImage) {
@@ -342,14 +341,6 @@
return result;
}
- void setBundleType(BundlerType type) {
- bundleType = type;
- }
-
- BundlerType getBundleType() {
- return bundleType;
- }
-
void setTargetFormat(String t) {
targetFormat = t;
}
@@ -403,8 +394,6 @@
bundleParams.setApplicationClass(applicationClass);
bundleParams.setAppVersion(version);
- bundleParams.setType(bundleType);
- bundleParams.setBundleFormat(targetFormat);
bundleParams.setCopyright(copyright);
bundleParams.setJvmargs(jvmargs);