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

Merge branch 'bugfix/parsinglongvalues' into 'develop'

Resolve "Parsing long values not working???"

Closes #25

See merge request jonasblatt/ma-jonasblatt-dmn-verifier!51
parents d6e75048 92880396
No related branches found
No related tags found
No related merge requests found
......@@ -11,9 +11,11 @@ import java.util.Optional;
/**
* The combine creator implementation of {@link BoundaryBiCreaterType#APPEND} for {@link
* AbstractGrowingBoundary}. <br> The result is a new boundary with the combined range of both
* boundaries, or an empty optional, if the creation is not possible. Both boundaries are not in
* contact. <br> In: {@code b1: [10..30[; b2: [30..50]} <br> Out: {@code ]10..50[} <br>
* AbstractGrowingBoundary}. <br>
* The result is a new boundary with the combined range of both boundaries, or an empty optional, if
* the creation is not possible. Both boundaries are not in contact. <br>
* In: {@code b1: [10..30[; b2: [30..50]} <br>
* Out: {@code ]10..50[} <br>
*/
public class BiCreaterAppend extends AbstractBoundaryBiCreater<AbstractGrowingBoundary> {
......@@ -108,6 +110,7 @@ public class BiCreaterAppend extends AbstractBoundaryBiCreater<AbstractGrowingBo
long b2L = (long) b2.getLowerBound();
long b2U = (long) b2.getUpperBound();
if (b1U + 1 == b2L
&& b1.getMaxValue().compareTo(b1U) != 0
&& b1.getUpperBoundType() == INCLUSIVE
&& b2.getLowerBoundType() == INCLUSIVE) {
return Optional.of(
......@@ -117,6 +120,7 @@ public class BiCreaterAppend extends AbstractBoundaryBiCreater<AbstractGrowingBo
b1.getLowerBoundType(),
b2.getUpperBoundType()));
} else if (b2U + 1 == b1L
&& b2.getMaxValue().compareTo(b2U) != 0
&& b2.getUpperBoundType() == INCLUSIVE
&& b1.getLowerBoundType() == INCLUSIVE) {
return Optional.of(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment