Instantly share code, notes, and snippets.

Embed
What would you like to do?
// No issues with this
private static class DecimalsRecordLayout extends CobolRecordLayout {
public DecimalsRecordLayout() {
super("decimals");
field("Price", "9(5)");
field("Quantity", "99v999");
field("Other", "999v99");
}
}
// Issues with this, exception below.
private static class DecimalsRecordLayout extends CobolRecordLayout {
public DecimalsRecordLayout() {
super("decimals");
field("Price", "9(5)");
field("Quantity", "9(2)v999");
field("Other", "999v99");
}
// java.lang.IllegalStateException: No match found
// at java.util.regex.Matcher.group(Matcher.java:468)
// at flapjack.cobol.util.CobolDecimalPatternParser.parseDecimalPlaces(CobolDecimalPatternParser.java:29)
// at flapjack.cobol.util.CobolDecimalTextValueConverter.fromTextToDomain(CobolDecimalTextValueConverter.java:34)
// at flapjack.util.AbstractTextValueConverter.toDomain(AbstractTextValueConverter.java:23)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment