Skip to content
Snippets Groups Projects
Commit 6a0f2930 authored by Jonas Blatt's avatar Jonas Blatt :ant:
Browse files

Merge branch 'feat/verifier' into 'develop'

Feat/verifier

See merge request jonasblatt/ma-jonasblatt-dmn-verifier!7
parents 4f347e35 877e89f8
No related branches found
No related tags found
No related merge requests found
...@@ -99,7 +99,7 @@ public class SimpleVDmnParser implements DmnModelInstanceWrapper { ...@@ -99,7 +99,7 @@ public class SimpleVDmnParser implements DmnModelInstanceWrapper {
VDmnDecisionImpl.Builder decisionBuilder = VDmnDecisionImpl.getBuilder().withDecisionId(id); VDmnDecisionImpl.Builder decisionBuilder = VDmnDecisionImpl.getBuilder().withDecisionId(id);
decisionBuilderMap.put(id, decisionBuilder); decisionBuilderMap.put(id, decisionBuilder);
// Add name, if present // Add name, if present
if (decision.getName() != null) { if (decision.getName() != null && !decision.getName().isEmpty()) {
decisionBuilder.withName(decision.getName()); decisionBuilder.withName(decision.getName());
} }
// Add DmnDecisionBuilder to definitionBuilder // Add DmnDecisionBuilder to definitionBuilder
...@@ -132,11 +132,12 @@ public class SimpleVDmnParser implements DmnModelInstanceWrapper { ...@@ -132,11 +132,12 @@ public class SimpleVDmnParser implements DmnModelInstanceWrapper {
.withInputExpressionId(new InputExpressionId(inputCol.getInputExpression().getId())) .withInputExpressionId(new InputExpressionId(inputCol.getInputExpression().getId()))
.withTypeRef(type); .withTypeRef(type);
// name // name
if (inputCol.getInputExpression().getText() != null) { if (inputCol.getInputExpression().getText() != null
&& !inputCol.getInputExpression().getText().getTextContent().isEmpty()) {
builder.withName(inputCol.getInputExpression().getText().getTextContent()); builder.withName(inputCol.getInputExpression().getText().getTextContent());
} }
// label // label
if (inputCol.getLabel() != null) { if (inputCol.getLabel() != null && !inputCol.getLabel().isEmpty()) {
builder.withLabel(inputCol.getLabel()); builder.withLabel(inputCol.getLabel());
} }
// Add Builder to builder list // Add Builder to builder list
...@@ -162,11 +163,11 @@ public class SimpleVDmnParser implements DmnModelInstanceWrapper { ...@@ -162,11 +163,11 @@ public class SimpleVDmnParser implements DmnModelInstanceWrapper {
.withOutputId(new OutputId(outputCol.getId())) .withOutputId(new OutputId(outputCol.getId()))
.withTypeRef(VTypeRef.getTypeRefFromName(outputCol.getTypeRef())); .withTypeRef(VTypeRef.getTypeRefFromName(outputCol.getTypeRef()));
// name // name
if (outputCol.getName() != null) { if (outputCol.getName() != null && !outputCol.getName().isEmpty()) {
builder.withName(outputCol.getName()); builder.withName(outputCol.getName());
} }
// label // label
if (outputCol.getLabel() != null) { if (outputCol.getLabel() != null && !outputCol.getLabel().isEmpty()) {
builder.withLabel(outputCol.getLabel()); builder.withLabel(outputCol.getLabel());
} }
// Add Builder to builder list // Add Builder to builder list
......
...@@ -55,14 +55,22 @@ public class Metric implements Serializable { ...@@ -55,14 +55,22 @@ public class Metric implements Serializable {
/ NANO_SECONDS_PER_SECOND; / NANO_SECONDS_PER_SECOND;
} }
/** /** Get the total execution time in ns. */
* Get the total execution time in ns.
*/
@JsonProperty("totalExecutionTime") @JsonProperty("totalExecutionTime")
public long getTotalExecutionTime() { public long getTotalExecutionTime() {
return executionTimes.stream().mapToLong(Long::longValue).sum(); return executionTimes.stream().mapToLong(Long::longValue).sum();
} }
/**
* Get the {@link VerificationType}.
*
* @return the {@link VerificationType}
*/
@JsonProperty("type")
public VerificationType getType() {
return type;
}
/** /**
* Get the total execution time in ms. * Get the total execution time in ms.
* *
......
# Configuration file # Configuration file
# Quarkus cors settings # Quarkus cors settings
quarkus.http.cors=true quarkus.http.cors=true
quarkus.http.cors.origins=http://localhost:8081 quarkus.http.cors.origins=http://localhost:8081,http://localhost:80
quarkus.http.cors.headers=accept, authorization, content-type, x-requested-with quarkus.http.cors.headers=accept,authorization,content-type,x-requested-with
quarkus.http.cors.methods=GET, POST, OPTIONS quarkus.http.cors.methods=GET, POST, OPTIONS
# Amount of threads for calculating the verifications # Amount of threads for calculating the verifications
verifier.threads=8 verifier.threads=8
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment