Updated ListParameter behavior

This commit is contained in:
Giancarlo Panichi 2022-11-15 15:47:32 +01:00
parent bd42395546
commit e8f986dfce
103 changed files with 42 additions and 44 deletions

8
.classpath Normal file → Executable file
View File

@ -1,12 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" output="target/data-miner-manager-cl-1.8.1-SNAPSHOT/WEB-INF/classes" path="src/main/java">
<classpathentry kind="src" output="target/data-miner-manager-cl-1.10.0-SNAPSHOT/WEB-INF/classes" path="src/main/java">
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry excluding="**" kind="src" output="target/data-miner-manager-cl-1.8.1-SNAPSHOT/WEB-INF/classes" path="src/main/resources">
<classpathentry excluding="**" kind="src" output="target/data-miner-manager-cl-1.10.0-SNAPSHOT/WEB-INF/classes" path="src/main/resources">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
@ -15,11 +15,13 @@
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
<attribute name="test" value="true"/>
</attributes>
</classpathentry>
<classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources">
<attributes>
<attribute name="maven.pomderived" value="true"/>
<attribute name="test" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
@ -33,5 +35,5 @@
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="target/data-miner-manager-cl-1.8.1-SNAPSHOT/WEB-INF/classes"/>
<classpathentry kind="output" path="target/data-miner-manager-cl-1.10.0-SNAPSHOT/WEB-INF/classes"/>
</classpath>

0
.gitignore vendored Normal file → Executable file
View File

0
.project Normal file → Executable file
View File

0
.settings/org.eclipse.core.resources.prefs Normal file → Executable file
View File

3
.settings/org.eclipse.jdt.core.prefs Normal file → Executable file
View File

@ -3,6 +3,9 @@ org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
org.eclipse.jdt.core.compiler.compliance=1.7
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore
org.eclipse.jdt.core.compiler.release=disabled
org.eclipse.jdt.core.compiler.source=1.7

0
.settings/org.eclipse.m2e.core.prefs Normal file → Executable file
View File

0
.settings/org.eclipse.wst.common.component Normal file → Executable file
View File

View File

0
.settings/org.eclipse.wst.validation.prefs Normal file → Executable file
View File

30
CHANGELOG.md Normal file → Executable file
View File

@ -1,13 +1,15 @@
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
# Changelog for "data-miner-manager-cl"
## [v1.9.0] - 2021-10-06
## [v1.10.0-SNAPSHOT] - 2022-10-27
### Features
- Added support to default value for ListParameter [#24026]
## [v1.9.0] - 2021-10-06
- Added cluster description in Service Info [#19213]
@ -15,8 +17,6 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
## [v1.8.0] - 2019-10-01
### Features
- Added service info [#12594]
- Added support to show log information [#11711]
- Added support to show files html, json, pdf, txt [#17106]
@ -28,8 +28,6 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
## [v1.7.0] - 2019-04-01
### Features
- Added location and zoom support [#11708]
- Added coordinates EPSG:4326 and EPSG:3857 support [#11710]
@ -37,24 +35,18 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
## [v1.6.0] - 2019-01-31
### Features
- Updated to support get operator by id with refresh
## [v1.5.0] - 2018-10-01
### Features
- Updated to support StorageHub[#11720]
## [v1.4.0] - 2018-06-01
### Features
- Updated to support netcdf files
- Added support for operators refresh[#11741]
@ -62,16 +54,12 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
## [v1.3.0] - 2017-06-12
### Features
- Support Java 8 compatibility [#8471]
## [v1.2.0] - 2017-05-01
### Features
- Updated to support DataMinerManagerWidget [#6078]
- Fixed load balancing [#7576]
@ -79,8 +67,6 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
## [v1.1.0] - 2017-03-20
### Features
- Updated Monitor interface
- Added encoded parameters in equivalent http request [#7167]
@ -88,9 +74,9 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
## [v1.0.0] - 2017-02-14
### Features
- first release
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

0
FUNDING.md Normal file → Executable file
View File

0
LICENSE.md Normal file → Executable file
View File

0
README.md Normal file → Executable file
View File

3
changelog.xml Normal file → Executable file
View File

@ -1,4 +1,7 @@
<ReleaseNotes>
<Changeset component="org.gcube.data.analysis.data-miner-manager-cl.1-10-0" date="2022-10-27">
<Change>Added support to default value for ListParameter [#24026]</Change>
</Changeset>
<Changeset component="org.gcube.data.analysis.data-miner-manager-cl.1-9-0" date="2021-10-06">
<Change>Added cluster description in Service Info [#19213]</Change>
</Changeset>

0
descriptor.xml Normal file → Executable file
View File

2
pom.xml Normal file → Executable file
View File

@ -11,7 +11,7 @@
<groupId>org.gcube.data.analysis</groupId>
<artifactId>data-miner-manager-cl</artifactId>
<version>1.9.0</version>
<version>1.10.0-SNAPSHOT</version>
<name>data-miner-manager-cl</name>
<description>DataMiner Manager Client Library</description>

0
profile.xml Normal file → Executable file
View File

View File

@ -75,7 +75,7 @@ public class WPS2DM {
converted = new ObjectParameter(id, title, String.class.getName(), " ");
else
converted = new ListParameter(id, title, String.class.getName(), SEPARATOR);
converted = new ListParameter(id, title, String.class.getName(), SEPARATOR, null);
return converted;
}
@ -160,7 +160,7 @@ public class WPS2DM {
String separator = matcher.group(1);
logger.debug("Matcher separator: " + separator);
converted = new ListParameter(id, title, guessedType, separator);
converted = new ListParameter(id, title, guessedType, separator,defaultValue);
} else {
if (title.contains("[WKT_")) {
logger.debug("WKT parameter: " + title);
@ -199,7 +199,7 @@ public class WPS2DM {
if (guessedType.compareTo(Boolean.class.getName()) == 0) {
converted = new ObjectParameter(id, title, guessedType, defaultValue);
} else {
converted = new ListParameter(id, title, String.class.getName(), SEPARATOR);
converted = new ListParameter(id, title, String.class.getName(), SEPARATOR, defaultValue);
}
}
@ -402,7 +402,7 @@ public class WPS2DM {
try {
String id = wpsType.getIdentifier().getStringValue();
String title = wpsType.getTitle() != null ? wpsType.getTitle().getStringValue() : "";
int minOcc = wpsType.getMinOccurs().intValue();
int maxOcc = wpsType.getMaxOccurs().intValue();
@ -413,7 +413,7 @@ public class WPS2DM {
// default
Parameter converted = new ObjectParameter(id, title, String.class.getName(), " ");
if (rangeOccs > 1)
converted = new ListParameter(id, title, String.class.getName(), SEPARATOR);
converted = new ListParameter(id, title, String.class.getName(), SEPARATOR, null);
// Bounding Boxes
if (wpsType.isSetBoundingBoxData()) {

View File

@ -14,6 +14,7 @@ public class ListParameter extends Parameter {
private static final long serialVersionUID = 5405965026753332225L;
private String type;
private String separator;
private String defaultValue;
/**
*
@ -25,19 +26,16 @@ public class ListParameter extends Parameter {
/**
*
* @param name
* name
* @param description
* description
* @param type
* type
* @param separator
* separator
* @param name name
* @param description description
* @param type type
* @param separator separator
*/
public ListParameter(String name, String description, String type, String separator) {
public ListParameter(String name, String description, String type, String separator, String defaultValue) {
super(name, ParameterType.LIST, description);
this.type = type;
this.separator = separator;
this.defaultValue = defaultValue;
}
/**
@ -48,8 +46,7 @@ public class ListParameter extends Parameter {
}
/**
* @param type
* the type to set
* @param type the type to set
*/
public void setType(String type) {
this.type = type;
@ -66,10 +63,17 @@ public class ListParameter extends Parameter {
this.separator = separator;
}
public String getDefaultValue() {
return defaultValue;
}
public void setDefaultValue(String defaultValue) {
this.defaultValue = defaultValue;
}
@Override
public String toString() {
return "ListParameter [type=" + type + ", value=" + value + ", separator=" + separator + ", name=" + name
+ ", description=" + description + ", typology=" + typology + "]";
return "ListParameter [type=" + type + ", separator=" + separator + ", defaultValue=" + defaultValue + "]";
}
}

Some files were not shown because too many files have changed in this diff Show More