diff --git a/.gitignore b/.gitignore index 102c9701..93a1ed90 100644 --- a/.gitignore +++ b/.gitignore @@ -16,3 +16,6 @@ esql-frontend/.project .settings/ .classpath .project +.idea +*.iml +sampleWorkspace/.scannerwork diff --git a/README.md b/README.md index 246059bb..73fd07ea 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ This open source plugin can be used to analyze the ESQL-sourcecode of IBM Websph ## Requirements -- SonarQube 6.7 +- SonarQube 7.9 ## Contributing @@ -32,6 +32,7 @@ This open source plugin can be used to analyze the ESQL-sourcecode of IBM Websph ## History +- 3.0.0 - Bugfixes, upgrade to sonar SonarQube 7.9 - 2.3.0 - Additional rules, upgrade to SonarQube 6.7, copy paste detector - 2.2.0 - Code coverage analysis - 2.1.0 - A few bugfixes and a lot more checks/rules @@ -43,7 +44,7 @@ This open source plugin can be used to analyze the ESQL-sourcecode of IBM Websph ## Credits -- EXXETA AG +- [EXXETA AG](http://exxeta.com) - See [Contributors](https://www.github.com/EXXETA/sonar-esql-plugin/graphs/contributors) ## License diff --git a/esql-checks-test/pom.xml b/esql-checks-test/pom.xml index 36c6dad1..49969e7e 100644 --- a/esql-checks-test/pom.xml +++ b/esql-checks-test/pom.xml @@ -3,7 +3,7 @@ com.exxeta.iss sonar-esql-plugin - 2.3.5 + 0.0.1-SNAPSHOT 4.0.0 @@ -37,7 +37,7 @@ org.mockito - mockito-all + mockito-core diff --git a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/CheckMessage.java b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/CheckMessage.java new file mode 100644 index 00000000..b8e1a595 --- /dev/null +++ b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/CheckMessage.java @@ -0,0 +1,82 @@ +package com.exxeta.iss.sonar.esql.checks.verifier; + +import java.text.MessageFormat; +import java.util.Arrays; + +public class CheckMessage { + private Integer line; + private Double cost; + private final Object check; + private final String defaultMessage; + private final Object[] messageArguments; + private Boolean bypassExclusion; + + public CheckMessage(Object check, String message, Object... messageArguments) { + this.check = check; + this.defaultMessage = message; + this.messageArguments = messageArguments; + } + + public void setLine(int line) { + this.line = line; + } + + + public Integer getLine() { + return line; + } + + public void setCost(double cost) { + this.cost = cost; + } + + public Double getCost() { + return cost; + } + + public void setBypassExclusion(boolean bypassExclusion) { + this.bypassExclusion = bypassExclusion; + } + + public boolean isBypassExclusion() { + return bypassExclusion != null && bypassExclusion; + } + + + public Object getCheck() { + return check; + } + + public String getDefaultMessage() { + return defaultMessage; + } + + public Object[] getMessageArguments() { + return messageArguments; + } + + + public String getText() { + return formatDefaultMessage(); + } + + @Override + public String toString() { + return "CheckMessage{" + + "line=" + line + + ", cost=" + cost + + ", check=" + check + + ", defaultMessage='" + defaultMessage + '\'' + + ", messageArguments=" + Arrays.toString(messageArguments) + + ", bypassExclusion=" + bypassExclusion + + '}'; + } + + public String formatDefaultMessage() { + if (messageArguments.length == 0) { + return defaultMessage; + } else { + return MessageFormat.format(defaultMessage, messageArguments); + } + } +} diff --git a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/CheckMessagesVerifier.java b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/CheckMessagesVerifier.java new file mode 100644 index 00000000..1fb9a602 --- /dev/null +++ b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/CheckMessagesVerifier.java @@ -0,0 +1,117 @@ +package com.exxeta.iss.sonar.esql.checks.verifier; + +import com.google.common.collect.Ordering; +import org.hamcrest.Matcher; +import com.google.common.base.Objects; + +import javax.annotation.Nullable; +import java.util.Collection; +import java.util.Comparator; +import java.util.Iterator; + +import static org.junit.Assert.assertThat; + +/** + * This class was copy&pasted from sslr-squid-bridge to avoid dependency on it + *

+ * Helper class for testing checks without having to deploy them on a Sonar instance. + * It can be used as following: + *

{@code
+ * CheckMessagesVerifier.verify(messages)
+ *   .next().atLine(1).withMessage("foo")
+ *   .next().atLine(2).withMessage("bar")
+ *   .noMore();
+ * }
+ * Strictly speaking this is just a wrapper over collection of {@link CheckMessage}, + * which guarantees order of traversal. + * + * @since sslr-squid-bridge 2.1 + */ +public final class CheckMessagesVerifier { + + private final Iterator iterator; + private CheckMessage current; + + private static final Comparator ORDERING = (left, right) -> { + if (Objects.equal(left.getLine(), right.getLine())) { + return left.getDefaultMessage().compareTo(right.getDefaultMessage()); + } else if (left.getLine() == null) { + return -1; + } else if (right.getLine() == null) { + return 1; + } else { + return left.getLine().compareTo(right.getLine()); + } + }; + + private CheckMessagesVerifier(Collection messages) { + iterator = Ordering.from(ORDERING).sortedCopy(messages).iterator(); + } + + public static CheckMessagesVerifier verify(Collection messages) { + return new CheckMessagesVerifier(messages); + } + + public CheckMessagesVerifier next() { + if (!iterator.hasNext()) { + throw new AssertionError("\nExpected violation"); + } + current = iterator.next(); + return this; + } + + public void noMore() { + if (iterator.hasNext()) { + CheckMessage next = iterator.next(); + throw new AssertionError("\nNo more violations expected\ngot: at line " + next.getLine()); + } + } + + private void checkStateOfCurrent() { + if (current == null) { + throw new IllegalStateException("Prior to this method you should call next()"); + } + } + + public CheckMessagesVerifier atLine(@Nullable Integer expectedLine) { + checkStateOfCurrent(); + if (!Objects.equal(expectedLine, current.getLine())) { + throw assertionError(expectedLine, current.getLine()); + } + return this; + } + + public CheckMessagesVerifier withMessage(String expectedMessage) { + checkStateOfCurrent(); + String actual = current.getText(); + if (!actual.equals(expectedMessage)) { + throw assertionError("\"" + expectedMessage + "\"", "\"" + actual + "\""); + } + return this; + } + + /** + * Note that this method requires JUnit and Hamcrest. + */ + CheckMessagesVerifier withMessageThat(Matcher matcher) { + checkStateOfCurrent(); + String actual = current.getText(); + assertThat(actual, matcher); + return this; + } + + /** + * @since sslr-squid-bridge 2.3 + */ + CheckMessagesVerifier withCost(Double expectedCost) { + checkStateOfCurrent(); + if (!Objects.equal(expectedCost, current.getCost())) { + throw assertionError(expectedCost, current.getCost()); + } + return this; + } + + private static AssertionError assertionError(@Nullable Object expected, @Nullable Object actual) { + return new AssertionError("\nExpected: " + expected + "\ngot: " + actual); + } +} diff --git a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/EsqlCheckVerifier.java b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/EsqlCheckVerifier.java index 638e2f6d..a7837d8b 100644 --- a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/EsqlCheckVerifier.java +++ b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/EsqlCheckVerifier.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -26,7 +26,6 @@ import java.util.List; import org.sonar.api.batch.fs.InputFile; -import org.sonar.squidbridge.checks.CheckMessagesVerifier; import com.exxeta.iss.sonar.esql.api.EsqlCheck; import com.exxeta.iss.sonar.esql.api.visitors.EsqlVisitorContext; diff --git a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/ExpectedIssuesParser.java b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/ExpectedIssuesParser.java index e113f3ac..603f3a72 100644 --- a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/ExpectedIssuesParser.java +++ b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/ExpectedIssuesParser.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TestIssue.java b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TestIssue.java index eee4d80b..227a0a0e 100644 --- a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TestIssue.java +++ b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TestIssue.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TestUtils.java b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TestUtils.java index 4facd338..cf8eb1c0 100644 --- a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TestUtils.java +++ b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TestUtils.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TreeCheckTest.java b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TreeCheckTest.java index a4c9579a..efd92660 100644 --- a/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TreeCheckTest.java +++ b/esql-checks-test/src/main/java/com/exxeta/iss/sonar/esql/checks/verifier/TreeCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -22,7 +22,6 @@ import java.util.List; import org.sonar.api.batch.fs.InputFile; -import org.sonar.squidbridge.api.CheckMessage; import com.exxeta.iss.sonar.esql.api.EsqlCheck; import com.exxeta.iss.sonar.esql.api.visitors.EsqlVisitorContext; diff --git a/esql-checks-test/src/test/java/com/exxeta/iss/sonar/esql/checks/verifier/EsqlCheckVerifierTest.java b/esql-checks-test/src/test/java/com/exxeta/iss/sonar/esql/checks/verifier/EsqlCheckVerifierTest.java index 599914fb..9a8ddc7b 100644 --- a/esql-checks-test/src/test/java/com/exxeta/iss/sonar/esql/checks/verifier/EsqlCheckVerifierTest.java +++ b/esql-checks-test/src/test/java/com/exxeta/iss/sonar/esql/checks/verifier/EsqlCheckVerifierTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/pom.xml b/esql-checks/pom.xml index 8d7230b0..a8290bad 100644 --- a/esql-checks/pom.xml +++ b/esql-checks/pom.xml @@ -6,7 +6,7 @@ com.exxeta.iss sonar-esql-plugin - 2.3.5 + 0.0.1-SNAPSHOT esql-checks diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/AbstractDoNotUseFunctionCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/AbstractDoNotUseFunctionCheck.java index 5d7d680c..440313cb 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/AbstractDoNotUseFunctionCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/AbstractDoNotUseFunctionCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BinaryOperatorSeparatedBySpaceCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BinaryOperatorSeparatedBySpaceCheck.java index 5bc3e126..11d885d9 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BinaryOperatorSeparatedBySpaceCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BinaryOperatorSeparatedBySpaceCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BlankLineBeforeCommentsCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BlankLineBeforeCommentsCheck.java index ee7f5090..44ef620a 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BlankLineBeforeCommentsCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BlankLineBeforeCommentsCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -55,4 +55,4 @@ public void visitProgram(ProgramTree tree) { } } } -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanEqualityComparisonCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanEqualityComparisonCheck.java new file mode 100644 index 00000000..f6a99c7d --- /dev/null +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanEqualityComparisonCheck.java @@ -0,0 +1,62 @@ +/* + * Sonar ESQL Plugin + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG + * http://www.exxeta.com + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.exxeta.iss.sonar.esql.check; + +import com.exxeta.iss.sonar.esql.api.tree.Tree.Kind; +import com.exxeta.iss.sonar.esql.api.tree.expression.BinaryExpressionTree; +import com.exxeta.iss.sonar.esql.api.tree.expression.ExpressionTree; +import com.exxeta.iss.sonar.esql.api.tree.expression.ParenthesisedExpressionTree; +import com.exxeta.iss.sonar.esql.api.tree.expression.UnaryExpressionTree; +import com.exxeta.iss.sonar.esql.api.visitors.DoubleDispatchVisitorCheck; +import org.sonar.check.Rule; + +@Rule(key = "BooleanEqualityComparison") +public class BooleanEqualityComparisonCheck extends DoubleDispatchVisitorCheck { + private static final String MESSAGE_REFACTOR = "Refactor the code to avoid using this boolean literal."; + private static final String MESSAGE_SIMPLIFY = "Simplify this unnecessary boolean operation."; + + @Override + public void visitUnaryExpression(UnaryExpressionTree tree) { + if (tree.is(Kind.LOGICAL_COMPLEMENT)) { + visitExpression(tree.expression(), MESSAGE_SIMPLIFY); + } + + super.visitUnaryExpression(tree); + } + + + @Override + public void visitBinaryExpression(BinaryExpressionTree tree) { + if (tree.is(Kind.EQUAL_TO, Kind.NOT_EQUAL_TO)) { + visitExpression(tree.leftOperand(), MESSAGE_REFACTOR); + visitExpression(tree.rightOperand(), MESSAGE_REFACTOR); + } + + super.visitBinaryExpression(tree); + } + + private void visitExpression(ExpressionTree expression, String message) { + if (expression.is(Kind.PARENTHESISED_EXPRESSION)) { + visitExpression(((ParenthesisedExpressionTree) expression).expression(), message); + } + + if (expression.is(Kind.BOOLEAN_LITERAL)) { + addIssue(expression, message); + } + } +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanInversionCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanInversionCheck.java index 44117ca6..2babc8f6 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanInversionCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanInversionCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanLiteralCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanLiteralCheck.java index 2ef0ae5c..53de2d91 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanLiteralCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/BooleanLiteralCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CardinalityInLoopCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CardinalityInLoopCheck.java index 98cbe865..25b8a61f 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CardinalityInLoopCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CardinalityInLoopCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseAtLeastThreeWhenCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseAtLeastThreeWhenCheck.java index beae3796..5f4c56f8 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseAtLeastThreeWhenCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseAtLeastThreeWhenCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseWithTooManyWhensCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseWithTooManyWhensCheck.java index f0e34cbd..d37b77b6 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseWithTooManyWhensCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseWithTooManyWhensCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseWithoutElseCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseWithoutElseCheck.java index 0178a510..06295878 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseWithoutElseCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CaseWithoutElseCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CheckList.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CheckList.java index ca150bf1..49af1101 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CheckList.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CheckList.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -63,6 +63,7 @@ public static List getChecks() { IfConditionalAlwaysTrueOrFalseCheck.class, DuplicateConditionIfElseAndCaseWhensCheck.class, BooleanInversionCheck.class, + BooleanEqualityComparisonCheck.class, HardCodedCredentialsCheck.class, HardcodedIpCheck.class, HardcodedURICheck.class, @@ -108,7 +109,8 @@ public static List getChecks() { CommentsCheck.class, DeclareCombineCheck.class, BinaryOperatorSeparatedBySpaceCheck.class, - TrailingWhitespaceCheck.class + TrailingWhitespaceCheck.class, + ImmediatelyReturnedVariableCheck.class @@ -126,12 +128,6 @@ The process is invoking itself. This may be a circular reference(SI) IdenticalOperandOnBinaryExpressionCheck -- Unreachable code after THROW or RETURN - -- Unused variable - - - Uppercase keywords - - IF/ELSEIF should be CASE @@ -139,4 +135,4 @@ The process is invoking itself. This may be a circular reference(SI) ); } -} +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CheckUtils.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CheckUtils.java index 26dcc87f..3222847f 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CheckUtils.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CheckUtils.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -156,4 +156,4 @@ public static Integer findLineInText(List textLines, String line) /* changes Ends here (sapna singh) */ -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CommentRegularExpressionCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CommentRegularExpressionCheck.java index 8c9051f5..c7aca015 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CommentRegularExpressionCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CommentRegularExpressionCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -35,7 +35,6 @@ import com.google.common.collect.ImmutableSet; @Rule( key = "CommentRegularExpression" ) -@RuleTemplate public class CommentRegularExpressionCheck extends SubscriptionVisitorCheck { private static final String DEFAULT_REGULAR_EXPRESSION = ""; @@ -96,4 +95,4 @@ public Set nodesToVisit() { return ImmutableSet.of(Kind.TOKEN); } -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CommentedCodeCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CommentedCodeCheck.java index c98fcf6b..302ad113 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CommentedCodeCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CommentedCodeCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ConstantNameCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ConstantNameCheck.java index efc93d75..834517b4 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ConstantNameCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ConstantNameCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CyclomaticComplexityCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CyclomaticComplexityCheck.java index e4695594..92cce37b 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CyclomaticComplexityCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/CyclomaticComplexityCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DeleteFromWithoutWhereCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DeleteFromWithoutWhereCheck.java index c4cd4ce1..99b27478 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DeleteFromWithoutWhereCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DeleteFromWithoutWhereCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DeprecatedMethodCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DeprecatedMethodCheck.java index 11b2e1c1..0860506d 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DeprecatedMethodCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DeprecatedMethodCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DuplicateConditionIfElseAndCaseWhensCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DuplicateConditionIfElseAndCaseWhensCheck.java index a3f59d02..dedf934b 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DuplicateConditionIfElseAndCaseWhensCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/DuplicateConditionIfElseAndCaseWhensCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ElseIfWithoutElseCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ElseIfWithoutElseCheck.java index 87222aba..eb6b599e 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ElseIfWithoutElseCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ElseIfWithoutElseCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyBlockCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyBlockCheck.java index 28e012e5..dd31cab9 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyBlockCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyBlockCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyFileCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyFileCheck.java index 5670ac79..63adec93 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyFileCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyFileCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyMainFunctionCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyMainFunctionCheck.java index 0c365638..43067e31 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyMainFunctionCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EmptyMainFunctionCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EvalCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EvalCheck.java index 95352d35..8437177a 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EvalCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/EvalCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FileHeaderCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FileHeaderCheck.java index 557eca8b..724ab2cc 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FileHeaderCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FileHeaderCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FileNameCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FileNameCheck.java index f1ab7251..bb6235c4 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FileNameCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FileNameCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FilterNodeHaveOnlyOneReturnCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FilterNodeHaveOnlyOneReturnCheck.java index d2a798ae..74ec48fd 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FilterNodeHaveOnlyOneReturnCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FilterNodeHaveOnlyOneReturnCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FilterNodeModifyMessageCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FilterNodeModifyMessageCheck.java index e56b1b6d..2a18a6d3 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FilterNodeModifyMessageCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FilterNodeModifyMessageCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FunctionNameCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FunctionNameCheck.java index 9bd6ce65..a511f9ad 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FunctionNameCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FunctionNameCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FunctionProcedureLengthCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FunctionProcedureLengthCheck.java index 7ee5cff9..f7cf3dbe 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FunctionProcedureLengthCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/FunctionProcedureLengthCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardCodedCredentialsCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardCodedCredentialsCheck.java index fe48e243..dde14fc0 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardCodedCredentialsCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardCodedCredentialsCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -39,14 +39,14 @@ @Rule(key = "HardCodedCredentials") public class HardCodedCredentialsCheck extends DoubleDispatchVisitorCheck { - private static final String PWD_TRANSLATION = "password|passwd|pwd|achinsinsi|adgangskode|codice|contrasena|contrasenya|contrasinal|cynfrinair|facal-faire|facalfaire|" + private static final String CREEDENTIAL_TRANSLATION = "password|passwd|pwd|achinsinsi|adgangskode|codice|contrasena|contrasenya|contrasinal|cynfrinair|facal-faire|facalfaire|" + "fjaleklaim|focalfaire|geslo|haslo|heslo|iphasiwedi|jelszo|kalmarsirri|katalaluan|katasandi|kennwort|kode|kupuhipa|loluszais|losen|losenord|lozinka|" + "lykilorth|mathkau|modpas|motdepasse|olelohuna|oroigbaniwole|parol|parola|parole|parool|pasahitza|pasiwedhi|passe|passord|passwort|" + "passwuert|paswoodu|phasewete|salasana|sandi|senha|sifre|sifreya|slaptazois|tenimiafina|upufaalilolilo|wachtwoord|wachtwurd|wagwoord"; - private static final Pattern PASSWORD_LITERAL_PATTERN = Pattern.compile("(" + PWD_TRANSLATION + ")=\\S.", + private static final Pattern PASSWORD_LITERAL_PATTERN = Pattern.compile("(" + CREEDENTIAL_TRANSLATION + ")=\\S.", Pattern.CASE_INSENSITIVE); - private static final Pattern PASSWORD_VARIABLE_PATTERN = Pattern.compile("(" + PWD_TRANSLATION + ")", + private static final Pattern PASSWORD_VARIABLE_PATTERN = Pattern.compile("(" + CREEDENTIAL_TRANSLATION + ")", Pattern.CASE_INSENSITIVE); @Override diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardcodedIpCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardcodedIpCheck.java index dca77b71..723bcb2a 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardcodedIpCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardcodedIpCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardcodedURICheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardcodedURICheck.java index 1995cf94..4db5c620 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardcodedURICheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/HardcodedURICheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IdenticalExpressionOnBinaryOperatorCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IdenticalExpressionOnBinaryOperatorCheck.java index 3d2922dc..038d8326 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IdenticalExpressionOnBinaryOperatorCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IdenticalExpressionOnBinaryOperatorCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IfConditionalAlwaysTrueOrFalseCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IfConditionalAlwaysTrueOrFalseCheck.java index b7f43927..1673faf8 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IfConditionalAlwaysTrueOrFalseCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IfConditionalAlwaysTrueOrFalseCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -65,4 +65,4 @@ public void visitElseifClause(ElseifClauseTree tree) { super.visitElseifClause(tree); } -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ImmediatelyReturnedVariableCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ImmediatelyReturnedVariableCheck.java new file mode 100644 index 00000000..553cee72 --- /dev/null +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ImmediatelyReturnedVariableCheck.java @@ -0,0 +1,75 @@ +package com.exxeta.iss.sonar.esql.check; + +import com.exxeta.iss.sonar.esql.api.tree.Tree.Kind; +import com.exxeta.iss.sonar.esql.api.tree.expression.ExpressionTree; +import com.exxeta.iss.sonar.esql.api.tree.expression.IdentifierTree; +import com.exxeta.iss.sonar.esql.api.tree.statement.DeclareStatementTree; +import com.exxeta.iss.sonar.esql.api.tree.statement.ReturnStatementTree; +import com.exxeta.iss.sonar.esql.api.tree.statement.StatementTree; +import com.exxeta.iss.sonar.esql.api.tree.statement.StatementsTree; +import com.exxeta.iss.sonar.esql.api.visitors.DoubleDispatchVisitorCheck; +import com.exxeta.iss.sonar.esql.tree.impl.SeparatedList; +import org.sonar.check.Rule; + +import javax.annotation.Nullable; +import java.util.List; + +@Rule(key = "ImmediatelyReturnedVariable") +public class ImmediatelyReturnedVariableCheck extends DoubleDispatchVisitorCheck { + private static final String MESSAGE = "Immediately return this expression instead of assigning it to the temporary variable \"%s\"."; + + @Override + public void visitStatements(StatementsTree tree) { + List statements = tree.statements(); + + if (statements.size() > 1) { + + StatementTree lastButOneStatement = statements.get(statements.size() - 2); + StatementTree lastStatement = statements.get(statements.size() - 1); + + if (lastButOneStatement.is(Kind.DECLARE_STATEMENT)) { + checkStatements(((DeclareStatementTree) lastButOneStatement), lastStatement); + } + } + + super.visitStatements(tree); + } + + private void checkStatements(DeclareStatementTree variableDeclaration, StatementTree lastStatement) { + SeparatedList variables = variableDeclaration.nameList(); + + if (variables.size() == 1 && variableDeclaration.initialValueExpression() != null) { + IdentifierTree identifier = variables.get(0); + + String name = identifier.name(); + + if (returnsVariableInLastStatement(lastStatement, name)) { + addIssue(variableDeclaration.initialValueExpression(), String.format(MESSAGE, name)); + + } + } + } + + + private static boolean returnsVariableInLastStatement(StatementTree lastStatement, String variableName) { + if (lastStatement.is(Kind.RETURN_STATEMENT)) { + ReturnStatementTree returnStatement = (ReturnStatementTree) lastStatement; + + return isVariable(returnStatement.expression(), variableName); + } + + return false; + } + + + private static boolean isVariable(@Nullable ExpressionTree expressionTree, String variableName) { + if (expressionTree != null && expressionTree.is(Kind.IDENTIFIER_REFERENCE)) { + String thrownName = ((IdentifierTree) expressionTree).name(); + return thrownName.equals(variableName); + } + + return false; + } + + +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/InitializeVariablesCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/InitializeVariablesCheck.java index bcfbee20..ed9c0736 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/InitializeVariablesCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/InitializeVariablesCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/InsertBlankLineBetweenFuncProcCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/InsertBlankLineBetweenFuncProcCheck.java index 537d5d48..e63342f4 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/InsertBlankLineBetweenFuncProcCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/InsertBlankLineBetweenFuncProcCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IterateStatementCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IterateStatementCheck.java index a1b3d347..8bc30898 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IterateStatementCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/IterateStatementCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -31,4 +31,4 @@ public void visitIterateStatement (IterateStatementTree tree){ addIssue(new LineIssue(this, tree, "Avoid using ITERATE statement.")); } -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/KeyWordCaseCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/KeyWordCaseCheck.java index cacc702c..0c327f3c 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/KeyWordCaseCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/KeyWordCaseCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/LineLengthCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/LineLengthCheck.java index fdba0d8f..c576b6ad 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/LineLengthCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/LineLengthCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/LoopWithoutLeaveCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/LoopWithoutLeaveCheck.java index 509cecd3..19f72aba 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/LoopWithoutLeaveCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/LoopWithoutLeaveCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/MissingNewlineAtEndOfFileCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/MissingNewlineAtEndOfFileCheck.java index c7bb891f..9fe51a34 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/MissingNewlineAtEndOfFileCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/MissingNewlineAtEndOfFileCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ModuleNameCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ModuleNameCheck.java index 3987a6f2..b78fb26b 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ModuleNameCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ModuleNameCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NavigatingTreeCouldBeReferenceCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NavigatingTreeCouldBeReferenceCheck.java index a44785e2..f2c21ab8 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NavigatingTreeCouldBeReferenceCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NavigatingTreeCouldBeReferenceCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NestedIfDepthCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NestedIfDepthCheck.java index b634d324..7dbcc90a 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NestedIfDepthCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NestedIfDepthCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NonReservedKeywordCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NonReservedKeywordCheck.java index 95518b9b..baa2b7ff 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NonReservedKeywordCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/NonReservedKeywordCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/OneStatementPerLineCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/OneStatementPerLineCheck.java index bc80f2b9..4bfe6aab 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/OneStatementPerLineCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/OneStatementPerLineCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -116,4 +116,4 @@ private void addIssue(List statementsAtLine) { -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ParameterWithDirectionCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ParameterWithDirectionCheck.java index 5535c88d..73bd485d 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ParameterWithDirectionCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ParameterWithDirectionCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ParsingErrorCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ParsingErrorCheck.java index b56859a0..a69deab5 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ParsingErrorCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ParsingErrorCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PassThruStatementCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PassThruStatementCheck.java index 0e0f18ba..849cd177 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PassThruStatementCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PassThruStatementCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ProcedureNameCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ProcedureNameCheck.java index de6ad7e6..7408f8a9 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ProcedureNameCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ProcedureNameCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ProcessInvokingItselfCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ProcessInvokingItselfCheck.java index 578d3125..adad3343 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ProcessInvokingItselfCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/ProcessInvokingItselfCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PropagateConsistencyCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PropagateConsistencyCheck.java index 8d0d34bf..bf0e46d9 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PropagateConsistencyCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PropagateConsistencyCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -195,4 +195,4 @@ private static String getTerminalName(ExpressionTree expression) { return target; } } -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PropagateToLabelCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PropagateToLabelCheck.java index 6e5978fb..7805871a 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PropagateToLabelCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/PropagateToLabelCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/RoutineCommentsCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/RoutineCommentsCheck.java index 134bf5b1..659f7694 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/RoutineCommentsCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/RoutineCommentsCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/RoutineWithExcessiveReturnsCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/RoutineWithExcessiveReturnsCheck.java index aa394055..56fb9a79 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/RoutineWithExcessiveReturnsCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/RoutineWithExcessiveReturnsCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SelectAllCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SelectAllCheck.java index 904a29a7..1a7d1be9 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SelectAllCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SelectAllCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SelfAssignmentCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SelfAssignmentCheck.java index a674c2f4..a38eaa1c 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SelfAssignmentCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SelfAssignmentCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SleepCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SleepCheck.java index 8ea839e0..78b67a18 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SleepCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SleepCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SubElementNameCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SubElementNameCheck.java index 57cf5fdf..c57b2726 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SubElementNameCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/SubElementNameCheck.java @@ -1,14 +1,14 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -18,47 +18,59 @@ package com.exxeta.iss.sonar.esql.check; import com.exxeta.iss.sonar.esql.api.tree.FieldReferenceTree; +import com.exxeta.iss.sonar.esql.api.tree.PathElementTree; import com.exxeta.iss.sonar.esql.api.tree.statement.SetStatementTree; -import org.sonar.check.Rule; - import com.exxeta.iss.sonar.esql.api.visitors.DoubleDispatchVisitorCheck; +import org.sonar.check.Rule; /** * This java class is created to implement the logic to check sub-elements * should be in UpperCamel-case and elements containing simple value should be * in lowercase. - * - * @author sapna singh * + * @author sapna singh */ @Rule(key = "SubElementName") public class SubElementNameCheck extends DoubleDispatchVisitorCheck { - private static final String MESSAGE = "sub-elements should be in UpperCamel-case and elements containing simple value should be in lowercase."; + private static final String MESSAGE = "sub-elements should be in UpperCamel-case and elements containing simple value should be in lowercase."; + + private static final String UPPERCASE_FORMAT = "^[A-Z][a-zA-Z0-9]*$"; + private static final String LOWERCASE_FORMAT = "^[a-z][a-zA-Z0-9]*$"; + + @Override + public void visitSetStatement(SetStatementTree tree) { + boolean isValid = true; + if (tree.variableReference() instanceof FieldReferenceTree) { + FieldReferenceTree fieldRef = (FieldReferenceTree) tree.variableReference(); + if ("Environment".equalsIgnoreCase(fieldRef.pathElement().name().name().name())) { + int subElementsSize = fieldRef.pathElements().size(); + if (subElementsSize > 0) { + for (int i = 0; i < subElementsSize - 1; i++) { + if (!matches(fieldRef.pathElements().get(i), UPPERCASE_FORMAT)) { + isValid = false; + } + } + PathElementTree lastElement = fieldRef.pathElements().get(subElementsSize - 1); + if (!matches(lastElement, LOWERCASE_FORMAT)) { + isValid = false; + } + + } - private static final String UPPERCASE_FORMAT = "^[A-Z][a-zA-Z0-9]*$"; - private static final String LOWERCASE_FORMAT = "^[a-z][a-zA-Z0-9]*$"; + } + } + if (!isValid) { + addIssue(tree, MESSAGE); + } + } - @Override - public void visitSetStatement(SetStatementTree tree) { - if (tree.variableReference() instanceof FieldReferenceTree) { - FieldReferenceTree fieldRef = (FieldReferenceTree) tree.variableReference(); - if ("Environment".equalsIgnoreCase(fieldRef.pathElement().name().name().name())) { - int subElementsSize = fieldRef.pathElements().size(); - if (subElementsSize > 0) { - for (int i = 0; i < subElementsSize - 1; i++) { - String subElement = fieldRef.pathElements().get(i).name().name().name(); - if (!subElement.matches(UPPERCASE_FORMAT)) { - addIssue(tree, MESSAGE); - } - } - String lastElement = fieldRef.pathElements().get(subElementsSize - 1).name().name().name(); - if (!lastElement.matches(LOWERCASE_FORMAT)) { - addIssue(tree, MESSAGE); - } - } - } - } - } -} \ No newline at end of file + private boolean matches(PathElementTree element, String format) { + if (element.name()!=null && element.name().name() != null && element.name().name().name() != null) { + return element.name().name().name().matches(format); + } else { + return true; + } + } +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/Tags.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/Tags.java index 322aa70b..b6e5bd85 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/Tags.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/Tags.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyIterateOrLeaveInLoopCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyIterateOrLeaveInLoopCheck.java index 15015ae6..2e013ce2 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyIterateOrLeaveInLoopCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyIterateOrLeaveInLoopCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -171,4 +171,4 @@ private void leaveScopeAndCheckNumberOfJump(SyntaxToken loopKeyword) { } -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyLinesInFileCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyLinesInFileCheck.java index f439f50e..a93e970f 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyLinesInFileCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyLinesInFileCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyParametersCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyParametersCheck.java index 1c724a0c..fae1d546 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyParametersCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TooManyParametersCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TrailingCommentsCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TrailingCommentsCheck.java index 4cb0745d..54b30676 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TrailingCommentsCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TrailingCommentsCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -85,4 +85,4 @@ public void setLegalCommentPattern(String pattern) { this.legalCommentPattern = pattern; } -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TrailingWhitespaceCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TrailingWhitespaceCheck.java index 20e39b9f..ff86e6c1 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TrailingWhitespaceCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/TrailingWhitespaceCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -58,4 +58,4 @@ public void visitFile(Tree scriptTree) { } -} \ No newline at end of file +} diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UndocumentedModuleCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UndocumentedModuleCheck.java index a9762e0b..1050e3ca 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UndocumentedModuleCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UndocumentedModuleCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UndocumentedRoutineCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UndocumentedRoutineCheck.java index 98a4594d..b3a545b0 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UndocumentedRoutineCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UndocumentedRoutineCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnknownMessageDomainCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnknownMessageDomainCheck.java index 0c7487c8..bbf5844f 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnknownMessageDomainCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnknownMessageDomainCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnreachableCodeCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnreachableCodeCheck.java index 65a4b6c1..461a97fa 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnreachableCodeCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnreachableCodeCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnusedRoutineCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnusedRoutineCheck.java index 67cef6fd..1084c6a3 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnusedRoutineCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnusedRoutineCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnusedVariableCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnusedVariableCheck.java index 3f752947..33bbd94d 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnusedVariableCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UnusedVariableCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UseBrokerSchemaCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UseBrokerSchemaCheck.java index f443de14..744c3049 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UseBrokerSchemaCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UseBrokerSchemaCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UselessParenthesesCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UselessParenthesesCheck.java index e4caefd1..07b42e20 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UselessParenthesesCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/UselessParenthesesCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/VariableNameCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/VariableNameCheck.java index 022e7778..26ce17c7 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/VariableNameCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/VariableNameCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/VariablesSubtreeCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/VariablesSubtreeCheck.java index e340c346..80221f6d 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/VariablesSubtreeCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/VariablesSubtreeCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/XmlnscDomainCheck.java b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/XmlnscDomainCheck.java index 6cc831c5..05bac0ad 100644 --- a/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/XmlnscDomainCheck.java +++ b/esql-checks/src/main/java/com/exxeta/iss/sonar/esql/check/XmlnscDomainCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql.properties b/esql-checks/src/main/resources/org/sonar/l10n/esql.properties deleted file mode 100644 index f84ae1cd..00000000 --- a/esql-checks/src/main/resources/org/sonar/l10n/esql.properties +++ /dev/null @@ -1,59 +0,0 @@ -rule.esql.FileName.name=File names should comply with a naming convention -rule.esql.FileName.param.format=regular expression -rule.esql.FunctionName.name=Function names should comply with a naming convention -rule.esql.FunctionName.param.format=regular expression -rule.esql.IterateStatement.name=Avoid using ITERATE statement. -rule.esql.LineLength.name=Maximum authorized line length exceeded -rule.esql.LineLength.param.maximumLineLength=The maximum authorized line length -rule.esql.ModuleName.name=Module names should comply with a naming convention -rule.esql.ModuleName.param.format=regular expression -rule.esql.NestedIfDepth.name=Avoid deeply nested if statements -rule.esql.NestedIfDepth.param.maximumNestingLevel=Allowed nesting depth -rule.esql.NonReservedKeyword.name=ESQL keywords should not be identifiers -rule.esql.OneStatementPerLine.name=Do not use more that one statement per line -rule.esql.ParsingError.name=ESQL parser failure -rule.esql.ProcedureName.name=Procedure names should comply with a naming convention -rule.esql.ProcedureName.param.format=regular expression -rule.esql.TooManyIterateOrLeaveInLoop.name=Loops should not contain more than a single ITERATE or LEAVE statement. -rule.esql.TooManyLinesInFile.name=Files should not have too many lines -rule.esql.TooManyLinesInFile.param.maximum=The maximum of lines -rule.esql.UseBrokerSchema.name=Files should not be in the DEFAULT schema -rule.esql.VariableName.name=Variable names should comply with a naming convention -rule.esql.VariableName.param.format=regular expression -rule.esql.PropagateToLabel.name=Do not use PROPAGATE TO LABEL. -rule.esql.ConstantName.name=Constant names should comply with a naming convention -rule.esql.ConstantName.param.format=regular expression -rule.esql.SpaceAroundEqualSign.name=Space should be given around = sign -rule.esql.KeyWordCaseCheck.name=Keywords should be in UPPERCASE -rule.esql.CyclomaticComplexity.name=Cyclomatic Complexity is higher then the threshold -rule.esql.CaseStatementWithSingleWhen.name=CASE statement with Single WHEN should replace by IF statement -rule.esql.EXTERNALVariableInitialised.name=External Variable should be initialized. -rule.esql.PassThruStatement.name=Use parameter markers '?' when using the PASSTHRU statement in ESQL. -rule.esql.AvoidNestedIf.name=Avoid nested IF statements: use ELSEIF or CASE WHEN clauses to get quicker drop-out. -rule.esql.MeaningfulVariable.name=Declaration of variable/counters name should be meaningful. -rule.esql.SubElementName.name=Sub elements naming convention Check. -rule.esql.FunctionProcedureLength.name=Function or Procedure is longer than the threshold. -rule.esql.FilterNodeModifyMessage.name=The filter node cannot modify the message. -rule.esql.FilterNodeHaveOnlyOneReturn.name=The filter node may only have one return value. -rule.esql.MessageDomainNotvalid.name=The message domain may not be valid. -rule.esql.NavigatingTreeCouldBeReference.name=Navigating message tree could be replaced by a reference. -rule.esql.UnusedVariable.name=Remove the unused Variable. -rule.esql.DeprecatedMethod.name=Deprecated methods should not be used. -rule.esql.BinaryOperatorSepratedBySpace.name=All binary operators should be separated from their operands by spaces. -rule.esql.InsertBlankLineBetweenFuncProc.name=Insert one blank line between functions and procedures. -rule.esql.BlankLineBeforeComments.name=Insert one blank line before a block or single-line comment. -rule.esql.BlankLineBeforeComments.name=A blank space should follow each comma in any ESQL statement that makes use of commas outside of a string literal. -rule.esql.ProcessInvokingItself.name=Process invoking itself. -rule.esql.FunctionComments.name=Each Function should have comments. -rule.esql.ProcedureComments.name=Each Procedure should have comments. -rule.esql.FileHeaderComments.name=Each ESQL file should contains header information. -rule.esql.PropagateConsistencyCheck.name=Compute node connections should be consistent. -rule.esql.UnreachableCode.name=Code is unreachable following RETURN or THROW statement -rule.esql.ConditionBraces.name=Use braces for conditions as it gives more readability to code. -rule.esql.TrailingComments.name=The line contains both code and comments. Trailing comments are discouraged. -rule.esql.CommentedOutEsqlCode.name=Esql code has been commented out.It should be removed before code checkin. -rule.esql.MultipleStatements.name=Multiple statements on the same line. -rule.esql.Comments.name=Include comment within the range of every 20 lines of code. -rule.esql.DeclareCombine.name=If more than one variable of same datatype is found uninitialised then declare could be combined. - - diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/BooleanEqualityComparison.html b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/BooleanEqualityComparison.html new file mode 100644 index 00000000..26de9025 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/BooleanEqualityComparison.html @@ -0,0 +1,16 @@ +

Boolean literals should be avoided in comparison expressions = and <> to improve code readability.

+

This rule also reports on redundant boolean operations.

+

Noncompliant Code Example

+
+
+
+IF someValue = TRUE THEN /* ... */ END IF;
+IF someValue <> TRUE THEN /* ... */ END IF;
+doSomething(NOT FALSE);
+
+

Compliant Solution

+
+IF someValue THEN /* ... */ END IF;
+IF NOT someBooleanValue THEN /* ... */ END IF;
+doSomething(TRUE);
+
diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/BooleanEqualityComparison.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/BooleanEqualityComparison.json new file mode 100644 index 00000000..99cac296 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/BooleanEqualityComparison.json @@ -0,0 +1,14 @@ +{ + "title": "Boolean literals should not be used in comparisons", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "5min" + }, + "tags": [ + "clumsy" + ], + "defaultSeverity": "Minor", + "sqKey": "BooleanEqualityComparison" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ConstantName.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ConstantName.json new file mode 100644 index 00000000..cc405f0c --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ConstantName.json @@ -0,0 +1,13 @@ +{ + "title": "Constant names should comply with a naming convention", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "5min" + }, + "tags": [ + "convention" + ], + "defaultSeverity": "Minor" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/FileName.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/FileName.json new file mode 100644 index 00000000..48657cba --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/FileName.json @@ -0,0 +1,13 @@ +{ + "title": "File names should comply with a naming convention", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "5min" + }, + "tags": [ + "convention" + ], + "defaultSeverity": "Minor" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/FunctionName.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/FunctionName.json new file mode 100644 index 00000000..f2ce8125 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/FunctionName.json @@ -0,0 +1,13 @@ +{ + "title": "Function names should comply with a naming convention", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "5min" + }, + "tags": [ + "convention" + ], + "defaultSeverity": "Minor" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ImmediatelyReturnedVariable.html b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ImmediatelyReturnedVariable.html new file mode 100644 index 00000000..5f02bbc1 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ImmediatelyReturnedVariable.html @@ -0,0 +1,17 @@ +

Declaring a variable only to immediately return it is a bad practice.

+

Some developers argue that the practice improves code readability, because it enables them to explicitly name what is being returned. However, this + variable is an internal implementation detail that is not exposed to the callers of the method. The method name should be sufficient for callers to + know exactly what will be returned.

+

Noncompliant Code Example

+
+CREATE FUNCTION computeDurationInMilliseconds() RETURNS INTEGER {
+  DECLARE duration INTEGER (((hours * 60) + minutes) * 60 + seconds ) * 1000 ;
+  RETURN duration;
+}
+
+

Compliant Solution

+
+CREATE FUNCTION  computeDurationInMilliseconds() RETURNS INTEGER {
+  RETURN (((hours * 60) + minutes) * 60 + seconds ) * 1000 ;
+}
+
diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ImmediatelyReturnedVariable.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ImmediatelyReturnedVariable.json new file mode 100644 index 00000000..f078ca1c --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ImmediatelyReturnedVariable.json @@ -0,0 +1,15 @@ +{ + "title": "Local variables should not be declared and then immediately returned", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "2min" + }, + "tags": [ + "clumsy" + ], + "defaultSeverity": "Minor", + "ruleSpecification": "RSPEC-1488", + "sqKey": "ImmediatelyReturnedVariable" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/IterateStatement.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/IterateStatement.json new file mode 100644 index 00000000..d5f384ba --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/IterateStatement.json @@ -0,0 +1,15 @@ +{ + "title": "\"ITERATE\" should not be used", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "1h" + }, + "tags": [ + "bad-practice" + ], + "defaultSeverity": "Minor", + "sqKey": "IterateStatement", + "scope": "Main" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/LineLength.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/LineLength.json new file mode 100644 index 00000000..fb8759c7 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/LineLength.json @@ -0,0 +1,15 @@ +{ + "title": "Lines should not be too long", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "1min" + }, + "tags": [ + "convention" + ], + "defaultSeverity": "Major", + "sqKey": "LineLength", + "scope": "All" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ModuleName.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ModuleName.json new file mode 100644 index 00000000..d3f8ab31 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ModuleName.json @@ -0,0 +1,13 @@ +{ + "title": "Module names should comply with a naming convention", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "5min" + }, + "tags": [ + "convention" + ], + "defaultSeverity": "Minor" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/NestedIfDepth.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/NestedIfDepth.json new file mode 100644 index 00000000..32dcaa21 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/NestedIfDepth.json @@ -0,0 +1,15 @@ +{ + "title": "Control flow statements \"IF\", \"FOR\", \"WHILE\", \"SWITCH\" should not be nested too deeply", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "10min" + }, + "tags": [ + "brain-overload" + ], + "defaultSeverity": "Critical", + "sqKey": "NestedIfDepth", + "scope": "All" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/NonReservedKeyword.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/NonReservedKeyword.json new file mode 100644 index 00000000..4ace9a9d --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/NonReservedKeyword.json @@ -0,0 +1,16 @@ +{ + "title": "\"non reserved words\" should not be used as identifiers", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "5min" + }, + "tags": [ + "lock-in", + "pitfall" + ], + "defaultSeverity": "Blocker", + "sqKey": "NonReservedWords", + "scope": "Main" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ParsingError.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ParsingError.json new file mode 100644 index 00000000..99cd1ceb --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ParsingError.json @@ -0,0 +1,15 @@ +{ + "title": "ESQL parser failure", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "30min" + }, + "tags": [ + "suspicious" + ], + "defaultSeverity": "Major", + "sqKey": "ParsingError", + "scope": "All" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/PassThruStatment.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/PassThruStatement.json similarity index 100% rename from esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/PassThruStatment.json rename to esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/PassThruStatement.json diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ProcedureName.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ProcedureName.json new file mode 100644 index 00000000..e068f3c4 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/ProcedureName.json @@ -0,0 +1,13 @@ +{ + "title": "Procedure names should comply with a naming convention", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "5min" + }, + "tags": [ + "convention" + ], + "defaultSeverity": "Minor" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/PropagateToLabel.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/PropagateToLabel.json new file mode 100644 index 00000000..d962706f --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/PropagateToLabel.json @@ -0,0 +1,15 @@ +{ + "title": "\"PROPAGATE TO LABEL\" should not be used", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "1h" + }, + "tags": [ + "bad-practice" + ], + "defaultSeverity": "Minor", + "sqKey": "PropagateToLabel", + "scope": "Main" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/TooManyIterateOrLeaveInLoop.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/TooManyIterateOrLeaveInLoop.json new file mode 100644 index 00000000..edd60442 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/TooManyIterateOrLeaveInLoop.json @@ -0,0 +1,16 @@ +{ + "title": "Loops should not contain more than a single \"ITERATE\" or \"LEAVE\" statement", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Linear", + "linearDesc": "per extra [\"iterate\"|\"ITERATE\" or \"leave\"|\"LEAVE\"] statement", + "linearFactor": "20min" + }, + "tags": [ + "brain-overload" + ], + "defaultSeverity": "Minor", + "sqKey": "TooManyIterateOrLeaveInLoop", + "scope": "All" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/TooManyLinesInFile.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/TooManyLinesInFile.json new file mode 100644 index 00000000..1cd9cfaf --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/TooManyLinesInFile.json @@ -0,0 +1,15 @@ +{ + "title": "Files should not have too many lines of code", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "1h" + }, + "tags": [ + "brain-overload" + ], + "defaultSeverity": "Major", + "sqKey": "TooManyLinesInFile", + "scope": "All" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/UseBrokerSchema.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/UseBrokerSchema.json new file mode 100644 index 00000000..8544fd80 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/UseBrokerSchema.json @@ -0,0 +1,15 @@ +{ + "title": "BROKER SCHEMA should should be used", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "1h" + }, + "tags": [ + "brain-overload" + ], + "defaultSeverity": "Major", + "sqKey": "UseBrokerSchema", + "scope": "All" +} diff --git a/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/VariableName.json b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/VariableName.json new file mode 100644 index 00000000..8de046e5 --- /dev/null +++ b/esql-checks/src/main/resources/org/sonar/l10n/esql/rules/esql/VariableName.json @@ -0,0 +1,13 @@ +{ + "title": "Variable names should comply with a naming convention", + "type": "CODE_SMELL", + "status": "ready", + "remediation": { + "func": "Constant\/Issue", + "constantCost": "5min" + }, + "tags": [ + "convention" + ], + "defaultSeverity": "Minor" +} diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BinaryOperatorSeparatedBySpaceCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BinaryOperatorSeparatedBySpaceCheckTest.java index ee95d6aa..30d3e204 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BinaryOperatorSeparatedBySpaceCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BinaryOperatorSeparatedBySpaceCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BlankLineBeforeCommentsCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BlankLineBeforeCommentsCheckTest.java index 25e64488..4edc8c9d 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BlankLineBeforeCommentsCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BlankLineBeforeCommentsCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanEqualityComparisonCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanEqualityComparisonCheckTest.java new file mode 100644 index 00000000..29d05638 --- /dev/null +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanEqualityComparisonCheckTest.java @@ -0,0 +1,30 @@ +/* + * Sonar ESQL Plugin + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG + * http://www.exxeta.com + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.exxeta.iss.sonar.esql.check; + +import com.exxeta.iss.sonar.esql.checks.verifier.EsqlCheckVerifier; +import org.junit.Test; + +import java.io.File; + +public class BooleanEqualityComparisonCheckTest { + @Test + public void test() { + EsqlCheckVerifier.verify(new BooleanEqualityComparisonCheck(), new File("src/test/resources/booleanEqualityComparison.esql")); + } +} diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanInversionCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanInversionCheckTest.java index cc40754f..d315bc5e 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanInversionCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanInversionCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanLiteralCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanLiteralCheckTest.java index 96e76e0f..df1cd2ce 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanLiteralCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/BooleanLiteralCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CardinalityInLoopCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CardinalityInLoopCheckTest.java index 02b5e50e..1d7e641a 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CardinalityInLoopCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CardinalityInLoopCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseAtLeastThreeWhenCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseAtLeastThreeWhenCheckTest.java index 756ca3f6..a5d59b9e 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseAtLeastThreeWhenCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseAtLeastThreeWhenCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseWithTooManyWhensCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseWithTooManyWhensCheckTest.java index dea91f47..f87d0cb6 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseWithTooManyWhensCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseWithTooManyWhensCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseWithoutElseCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseWithoutElseCheckTest.java index b3987197..63b27385 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseWithoutElseCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CaseWithoutElseCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CheckListTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CheckListTest.java index 2eda36b7..143b7ab6 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CheckListTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CheckListTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CommentRegularExpressionCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CommentRegularExpressionCheckTest.java index 00bf1743..de4d6b54 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CommentRegularExpressionCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CommentRegularExpressionCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CommentedCodeCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CommentedCodeCheckTest.java index b8f4e729..2e46ea9f 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CommentedCodeCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CommentedCodeCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ConstantNameCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ConstantNameCheckTest.java index affac0d3..ccc36c31 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ConstantNameCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ConstantNameCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CyclomaticComplexityCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CyclomaticComplexityCheckTest.java index 80222375..3f9d6185 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CyclomaticComplexityCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/CyclomaticComplexityCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DeleteFromWithoutWhereCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DeleteFromWithoutWhereCheckTest.java index 1e292ebd..d3169e90 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DeleteFromWithoutWhereCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DeleteFromWithoutWhereCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DeprecatedMethodCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DeprecatedMethodCheckTest.java index 8cb66525..f5631942 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DeprecatedMethodCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DeprecatedMethodCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DuplicateConditionIfElseAndCaseWhensCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DuplicateConditionIfElseAndCaseWhensCheckTest.java index 4fc986f7..1b6d1d81 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DuplicateConditionIfElseAndCaseWhensCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/DuplicateConditionIfElseAndCaseWhensCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ElseIfWithoutElseCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ElseIfWithoutElseCheckTest.java index 644024fb..44ba7bf8 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ElseIfWithoutElseCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ElseIfWithoutElseCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyBlockCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyBlockCheckTest.java index b5cbc0bf..ab75b1eb 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyBlockCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyBlockCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyFileCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyFileCheckTest.java index 476fc662..6d92e733 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyFileCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyFileCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyMainFunctionCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyMainFunctionCheckTest.java index a263cbbb..dbe02f64 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyMainFunctionCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EmptyMainFunctionCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EvalCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EvalCheckTest.java index 2eb2d2ca..679d2a2f 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EvalCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/EvalCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FileHeaderCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FileHeaderCheckTest.java index 20f2e94b..f68d500a 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FileHeaderCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FileHeaderCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -119,4 +119,4 @@ private static EsqlCheck checkPlainText(String format) { check.headerFormat = format; return check; } - } \ No newline at end of file + } diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FileNameCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FileNameCheckTest.java index 762d2285..0e91a776 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FileNameCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FileNameCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FilterNodeHaveOnlyOneReturnCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FilterNodeHaveOnlyOneReturnCheckTest.java index 5044c079..12c7ab2d 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FilterNodeHaveOnlyOneReturnCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FilterNodeHaveOnlyOneReturnCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FilterNodeModifyMessageCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FilterNodeModifyMessageCheckTest.java index 8cd7994a..6397f831 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FilterNodeModifyMessageCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FilterNodeModifyMessageCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FunctionNameCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FunctionNameCheckTest.java index e6e784f9..c8347735 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FunctionNameCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FunctionNameCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FunctionProcedureLengthCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FunctionProcedureLengthCheckTest.java index 2cf59d2d..51fcb12d 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FunctionProcedureLengthCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/FunctionProcedureLengthCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardCodedCredentialsCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardCodedCredentialsCheckTest.java index 0505c61d..bf646299 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardCodedCredentialsCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardCodedCredentialsCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardcodedIpCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardcodedIpCheckTest.java index 8b3d3280..22a8366e 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardcodedIpCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardcodedIpCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardcodedURICheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardcodedURICheckTest.java index d6b0af6f..c400d6ba 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardcodedURICheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/HardcodedURICheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IdenticalExpressionOnBinaryOperatorCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IdenticalExpressionOnBinaryOperatorCheckTest.java index 84c770da..5b276ae8 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IdenticalExpressionOnBinaryOperatorCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IdenticalExpressionOnBinaryOperatorCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IfConditionalAlwaysTrueOrFalseCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IfConditionalAlwaysTrueOrFalseCheckTest.java index f3d56a82..06b46290 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IfConditionalAlwaysTrueOrFalseCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IfConditionalAlwaysTrueOrFalseCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ImmediatelyReturnedVariableCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ImmediatelyReturnedVariableCheckTest.java new file mode 100644 index 00000000..947a6b15 --- /dev/null +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ImmediatelyReturnedVariableCheckTest.java @@ -0,0 +1,15 @@ +package com.exxeta.iss.sonar.esql.check; + +import com.exxeta.iss.sonar.esql.checks.verifier.EsqlCheckVerifier; +import org.junit.Test; + +import java.io.File; + +import static org.junit.Assert.*; + +public class ImmediatelyReturnedVariableCheckTest { + @Test + public void test() { + EsqlCheckVerifier.verify(new ImmediatelyReturnedVariableCheck(), new File("src/test/resources/ImmediatelyReturnedVariable.esql")); + } +} diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/InitializeVariablesCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/InitializeVariablesCheckTest.java index 0000c927..7937bcf4 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/InitializeVariablesCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/InitializeVariablesCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/InsertBlankLineBetweenFuncProcCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/InsertBlankLineBetweenFuncProcCheckTest.java index ce374197..e1f9d7c7 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/InsertBlankLineBetweenFuncProcCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/InsertBlankLineBetweenFuncProcCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IterateStatementCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IterateStatementCheckTest.java index 75821649..a462251f 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IterateStatementCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/IterateStatementCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/KeyWordCaseCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/KeyWordCaseCheckTest.java index f336965c..8e95b288 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/KeyWordCaseCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/KeyWordCaseCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/LineLengthCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/LineLengthCheckTest.java index 7a19a5d2..e7cdc36a 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/LineLengthCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/LineLengthCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/LoopWithoutLeaveCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/LoopWithoutLeaveCheckTest.java index 3a66d9a4..6b413fc3 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/LoopWithoutLeaveCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/LoopWithoutLeaveCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/MissingNewlineAtEndOfFileCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/MissingNewlineAtEndOfFileCheckTest.java index 7bb71cb6..36338d4c 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/MissingNewlineAtEndOfFileCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/MissingNewlineAtEndOfFileCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ModuleNameCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ModuleNameCheckTest.java index c6955fbd..6dbfa0c8 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ModuleNameCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ModuleNameCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NavigatingTreeCouldBeReferenceCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NavigatingTreeCouldBeReferenceCheckTest.java index 443dc989..78bd9d6a 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NavigatingTreeCouldBeReferenceCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NavigatingTreeCouldBeReferenceCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NestedIfDepthCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NestedIfDepthCheckTest.java index 720a11f3..eaa824e3 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NestedIfDepthCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NestedIfDepthCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NonReservedKeywordCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NonReservedKeywordCheckTest.java index e5e02d54..cb898961 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NonReservedKeywordCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/NonReservedKeywordCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/OneStatementPerLineCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/OneStatementPerLineCheckTest.java index 099d6332..a27df420 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/OneStatementPerLineCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/OneStatementPerLineCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ParameterWithDirectionCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ParameterWithDirectionCheckTest.java index 85b002e4..7f5c6a20 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ParameterWithDirectionCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ParameterWithDirectionCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PassThruStatementCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PassThruStatementCheckTest.java index aae4c1cf..f0c9c91d 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PassThruStatementCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PassThruStatementCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ProcedureNameCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ProcedureNameCheckTest.java index ff4d3cfe..05065c38 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ProcedureNameCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ProcedureNameCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ProcessInvokingItselfCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ProcessInvokingItselfCheckTest.java index 742efc64..7473f6e9 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ProcessInvokingItselfCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/ProcessInvokingItselfCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PropagateConsistencyCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PropagateConsistencyCheckTest.java index f2d7596d..414245cf 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PropagateConsistencyCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PropagateConsistencyCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -34,4 +34,4 @@ public void test() { } -} \ No newline at end of file +} diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PropagateToLabelCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PropagateToLabelCheckTest.java index 319e914b..9404bef0 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PropagateToLabelCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/PropagateToLabelCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/RoutineCommentsCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/RoutineCommentsCheckTest.java index 33ae2922..9f9ac2fe 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/RoutineCommentsCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/RoutineCommentsCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/RoutineWithExcessiveReturnsCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/RoutineWithExcessiveReturnsCheckTest.java index d51d1405..485a39f3 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/RoutineWithExcessiveReturnsCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/RoutineWithExcessiveReturnsCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SelectAllCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SelectAllCheckTest.java index 1d2a5e45..ffadfebf 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SelectAllCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SelectAllCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SelfAssignmentCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SelfAssignmentCheckTest.java index 538d67ef..58d6ca80 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SelfAssignmentCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SelfAssignmentCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SleepCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SleepCheckTest.java index f0385bc8..b0351286 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SleepCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SleepCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SubElementNameCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SubElementNameCheckTest.java index e47c7a4c..33b61017 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SubElementNameCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/SubElementNameCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyIterateOrLeaveInLoopCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyIterateOrLeaveInLoopCheckTest.java index fba515e5..83fad379 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyIterateOrLeaveInLoopCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyIterateOrLeaveInLoopCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyLinesInFileCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyLinesInFileCheckTest.java index 365d651e..634231d9 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyLinesInFileCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyLinesInFileCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyParametersCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyParametersCheckTest.java index d7ef5fa0..52d85c27 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyParametersCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/TooManyParametersCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UndocumentedModuleCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UndocumentedModuleCheckTest.java index 5122811c..75e08228 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UndocumentedModuleCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UndocumentedModuleCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UndocumentedRoutineCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UndocumentedRoutineCheckTest.java index 18ca945b..c1c66604 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UndocumentedRoutineCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UndocumentedRoutineCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnknownMessageDomainCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnknownMessageDomainCheckTest.java index 84f92e05..35f5614c 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnknownMessageDomainCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnknownMessageDomainCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnreachableCodeCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnreachableCodeCheckTest.java index b801f284..d74d9f08 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnreachableCodeCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnreachableCodeCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnusedRoutineCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnusedRoutineCheckTest.java index 69e9706b..2f736baa 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnusedRoutineCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnusedRoutineCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -54,4 +54,4 @@ public void functions() throws Exception { .noMore(); } -} \ No newline at end of file +} diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnusedVariableCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnusedVariableCheckTest.java index a339f75b..0921592e 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnusedVariableCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UnusedVariableCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -38,6 +38,7 @@ public void test() { .next().atLine(11).withMessage("Remove the unused 'envRef' variable.") .next().atLine(33).withMessage("Remove the unused 'inReturn' variable.") + .next().atLine(35).withMessage("Remove the unused 'qst' variable.") .noMore(); } diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UseBrokerSchemaCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UseBrokerSchemaCheckTest.java index 3db2562f..34a9c69d 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UseBrokerSchemaCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UseBrokerSchemaCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UselessParenthesesCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UselessParenthesesCheckTest.java index a3409deb..5b57620e 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UselessParenthesesCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/UselessParenthesesCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/VariableNameCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/VariableNameCheckTest.java index 4fe0dfaf..6dcb0802 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/VariableNameCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/VariableNameCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/VariablesSubtreeCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/VariablesSubtreeCheckTest.java index 9e1e4d4e..38fbef5e 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/VariablesSubtreeCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/VariablesSubtreeCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/XmlnscDomainCheckTest.java b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/XmlnscDomainCheckTest.java index e3243dee..427f1050 100644 --- a/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/XmlnscDomainCheckTest.java +++ b/esql-checks/src/test/java/com/exxeta/iss/sonar/esql/check/XmlnscDomainCheckTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-checks/src/test/resources/ImmediatelyReturnedVariable.esql b/esql-checks/src/test/resources/ImmediatelyReturnedVariable.esql new file mode 100644 index 00000000..4ebecb99 --- /dev/null +++ b/esql-checks/src/test/resources/ImmediatelyReturnedVariable.esql @@ -0,0 +1,56 @@ +CREATE PROCEDURE var_returned() BEGIN + DECLARE x INTEGER 42; -- Noncompliant {{Immediately return this expression instead of assigning it to the temporary variable "x".}} +-- ^^ + return x; +END; + +CREATE PROCEDURE const_returned() BEGIN + DECLARE x CONSTANT INTEGER 42; -- Noncompliant + return x; +END; + +CREATE PROCEDURE code_before_declaration() BEGIN + CALL foo(); + DECLARE x INTEGER 42; -- Noncompliant + return x; +END; + +CREATE PROCEDURE code_between_declaration_and_return() BEGIN + DECLARE x INTEGER 42; -- OK + CALL foo(); + return x; +END; + +CREATE PROCEDURE return_expression() BEGIN + DECLARE x INTEGER 42; + return x + 5; +END; + +CREATE PROCEDURE return_without_value() BEGIN + DECLARE x INTEGER 42; + return; +END; + +CREATE PROCEDURE no_init_value() BEGIN + DECLARE x INTEGER; + return x; +END; + +CREATE PROCEDURE different_variable_returned() BEGIN + DECLARE y INTEGER 42; + return x; +END; + +CREATE PROCEDURE only_return() BEGIN + return 42; +END; + +CREATE PROCEDURE two_variables_declared() BEGIN + DECLARE x, y INTEGER 42; + return x; +END; + +CREATE PROCEDURE not_return_statement() BEGIN + DECLARE x INTEGER 42; + CALL foo(x); +END; diff --git a/esql-checks/src/test/resources/SubElementName.esql b/esql-checks/src/test/resources/SubElementName.esql index a24899de..110a8db9 100644 --- a/esql-checks/src/test/resources/SubElementName.esql +++ b/esql-checks/src/test/resources/SubElementName.esql @@ -13,7 +13,8 @@ CREATE COMPUTE MODULE Module1 MQ. DestinationData. msgId; - + SET Environment.{abc}='ABC'; + SET Environment='ABC'; END; diff --git a/esql-checks/src/test/resources/UnusedVariable.esql b/esql-checks/src/test/resources/UnusedVariable.esql index 42897db2..8e6bcdca 100644 --- a/esql-checks/src/test/resources/UnusedVariable.esql +++ b/esql-checks/src/test/resources/UnusedVariable.esql @@ -26,10 +26,14 @@ CrEATE COMPUTE MODULE responseTransformation SET refEnv.serviceOperationName = InputRoot.SOAP.Context.operation; SET refEnv.operationId = EVAL(Environment.LogData.serviceOperationName); END; - + CREATE PROCEDURE B() BEGIN DECLARE inputRef REFERENCE TO InputRoot; DECLARE inReturn REFERENCE TO inputRef.a; + + DECLARE qst NAMESPACE 'http://www.ww.ru/types/QST'; + DECLARE qsp NAMESPACE 'http://www.ww.ru/types/QSP'; + SET OutputRoot.XMLNSC.qsp:Request = ''; END; END MOdULE; \ No newline at end of file diff --git a/esql-checks/src/test/resources/booleanEqualityComparison.esql b/esql-checks/src/test/resources/booleanEqualityComparison.esql new file mode 100644 index 00000000..36e71c2b --- /dev/null +++ b/esql-checks/src/test/resources/booleanEqualityComparison.esql @@ -0,0 +1,20 @@ +CREATE PROCEDURE bool() + BEGIN + +IF NOT TRUE THEN END IF; -- Noncompliant {{Simplify this unnecessary boolean operation.}} +IF NOT FALSE THEN END IF; -- Noncompliant + +IF a = FALSE THEN END IF; -- Noncompliant {{Refactor the code to avoid using this boolean literal.}} +-- ^^^^^ +IF a = TRUE THEN END IF; -- Noncompliant +IF a <> false THEN END IF; -- Noncompliant {{Refactor the code to avoid using this boolean literal.}} +IF a <> TRUE THEN END IF; -- Noncompliant +IF TRUE = a THEN END IF; -- Noncompliant +IF FALSE = a THEN END IF; -- Noncompliant +IF TRUE <> a THEN END IF; -- Noncompliant +IF FALSE <> a THEN END IF; -- Noncompliant +IF a = foo(true) THEN END IF; -- OK +IF NOT (TRUE) THEN END IF; -- Noncompliant +IF a = (FALSE) THEN END IF; -- Noncompliant + + END; diff --git a/esql-checks/src/test/resources/bugfixes.esql b/esql-checks/src/test/resources/bugfixes.esql index 9ec5a852..3f9e6b26 100644 --- a/esql-checks/src/test/resources/bugfixes.esql +++ b/esql-checks/src/test/resources/bugfixes.esql @@ -145,3 +145,20 @@ CREATE COMPUTE MODULE "TEST_ success" END; END MODULE; +CREATE COMPUTE MODULE "TEST_ success" + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + -- Issue #106 + DECLARE STANDARD_CHARSET_RANGE CONSTANT ROW ROW( + LIST { + ROW('ABCDEFGHIJKLMNOPQRSTUVWXYZ' AS "[A-Z]"), + ROW('abcdefghijklmnopqrstuvwxyz' AS "[a-z]"), + ROW('АБВГДЕЁЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ' AS "[А-Я]"), + ROW('абвгдеёжзийклмнопрстуфхцчшщъыьэюя' AS "[а-я]"), + ROW('0123456789' AS "[0-9]") + } AS ranges[] + ); + RETURN TRUE; + END; +END MODULE; + diff --git a/esql-code-coverage/pom.xml b/esql-code-coverage/pom.xml index 391813ba..b7f5d609 100644 --- a/esql-code-coverage/pom.xml +++ b/esql-code-coverage/pom.xml @@ -6,7 +6,7 @@ com.exxeta.iss sonar-esql-plugin - 2.3.5 + 0.0.1-SNAPSHOT esql-code-coverage @@ -55,13 +55,6 @@ - - org.sonarsource.sonarqube - sonar-plugin-api - ${sonar.version} - test-jar - test - junit junit @@ -69,7 +62,7 @@ org.mockito - mockito-all + mockito-core test diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/AbstractAnalyzer.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/AbstractAnalyzer.java index bb3b5ae2..ab388e95 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/AbstractAnalyzer.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/AbstractAnalyzer.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/CodeCoverageExtension.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/CodeCoverageExtension.java index a3833dd2..344673eb 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/CodeCoverageExtension.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/CodeCoverageExtension.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/CodePosition.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/CodePosition.java index 771b0bfe..9733664a 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/CodePosition.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/CodePosition.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/ExecutionDataVisitor.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/ExecutionDataVisitor.java index a6c3a50b..debbace1 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/ExecutionDataVisitor.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/ExecutionDataVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/LineExecutionData.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/LineExecutionData.java index 2bfc481e..13b0b632 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/LineExecutionData.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/LineExecutionData.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/ModuleExecutionData.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/ModuleExecutionData.java index 7e95dfba..f53ff6d9 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/ModuleExecutionData.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/ModuleExecutionData.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/TraceFileReader.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/TraceFileReader.java index ba56441d..75e8aec6 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/TraceFileReader.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/TraceFileReader.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -86,7 +86,7 @@ private void readXML() { UserTraceLog userTraceLog = parseTraceXml(); for (UserTraceType trace : userTraceLog.getUserTraceOrInformation()){ - if (trace.getFunction().endsWith("::execute")){ + if (trace.getFunction().endsWith("::execute") && trace.getInsert().size()>2){ String function = trace.getInsert().get(0).getValue(); function = function.substring(1, function.length()-1); String relativeLine = trace.getInsert().get(1).getValue(); @@ -95,7 +95,7 @@ private void readXML() { statement=statement.substring(1, statement.length()-1); String schemaAndModuleName=""; if (function.contains(".")) { - schemaAndModuleName = function.substring(0, function.lastIndexOf('.')).trim(); + schemaAndModuleName = function.trim(); } addExecution(function, relativeLine, statement, schemaAndModuleName); } diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/TraceSensor.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/TraceSensor.java index 6f6293d2..4b8f4c6a 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/TraceSensor.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/codecoverage/TraceSensor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/InsertType.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/InsertType.java index 4ca24ad9..f28ad1c8 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/InsertType.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/InsertType.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/UserTraceLog.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/UserTraceLog.java index c7e94935..3e7e609f 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/UserTraceLog.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/UserTraceLog.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/UserTraceType.java b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/UserTraceType.java index 4a97a62f..dc47a08b 100644 --- a/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/UserTraceType.java +++ b/esql-code-coverage/src/main/java/com/exxeta/iss/sonar/esql/trace/UserTraceType.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/CodeCoverageExtensionTest.java b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/CodeCoverageExtensionTest.java index 707ce594..fd8e8f1c 100644 --- a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/CodeCoverageExtensionTest.java +++ b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/CodeCoverageExtensionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/CodePositionTest.java b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/CodePositionTest.java index 0fabe5da..2cbb69f7 100644 --- a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/CodePositionTest.java +++ b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/CodePositionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/LineExecutionDataTest.java b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/LineExecutionDataTest.java index 6c948388..121060c1 100644 --- a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/LineExecutionDataTest.java +++ b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/LineExecutionDataTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/TraceFileReaderTest.java b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/TraceFileReaderTest.java index ca4ecdeb..657064ac 100644 --- a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/TraceFileReaderTest.java +++ b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/TraceFileReaderTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -86,9 +86,9 @@ public void visitModuleExecution(ModuleExecutionData data) { TraceFileReader reader = new TraceFileReader(new File("src/test/resources/codecoverage/trace.xml")) .readTrace(visitor); - assertEquals(1, reader.getModuleCount()); + assertEquals(2, reader.getModuleCount()); assertNull(reader.getModuleExecutionData("")); - assertEquals(7, reader.getModuleExecutionData(".Test_Compute").size()); + assertEquals(5, reader.getModuleExecutionData(".Test_Compute.Main").size()); } @@ -132,4 +132,15 @@ public void jaxBTest() throws JAXBException { } + @Test + public void indexOutOfBounds112() throws JAXBException { + new TraceFileReader(new File("src/test/resources/codecoverage/tests/usertrace_112.xml")).readTrace(new ExecutionDataVisitor(){ + + @Override + public void visitModuleExecution(ModuleExecutionData data) { + + } + }); + } + } diff --git a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/TraceSensorTest.java b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/TraceSensorTest.java index 02b1ba06..4d014f40 100644 --- a/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/TraceSensorTest.java +++ b/esql-code-coverage/src/test/java/com/exxeta/iss/sonar/esql/codecoverage/TraceSensorTest.java @@ -27,7 +27,7 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-code-coverage/src/test/resources/codecoverage/tests/usertrace_112.xml b/esql-code-coverage/src/test/resources/codecoverage/tests/usertrace_112.xml new file mode 100644 index 00000000..c728a62e --- /dev/null +++ b/esql-code-coverage/src/test/resources/codecoverage/tests/usertrace_112.xml @@ -0,0 +1,7752 @@ + + + + 'Properties' + 0 + 364 + gen.fulfillment_request_3.HTTP Input + + + 'HTTPInputHeader' + 364 + 852 + 'WSINPHDR' + gen.fulfillment_request_3.HTTP Input + + + 'gen.fulfillment_request_3.HTTP Input' + 'out' + gen.fulfillment_request_3.HTTP Input + + + gen.fulfillment_request_3.Route To Label + + + gen.fulfillment_request_3.post (Label) + + + gen.fulfillment_request_3.post (Implementation).Input + + + '.token_API_URL' + '1.1' + 'DECLARE token_API_URL EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.token_Authorization' + '1.1' + 'DECLARE token_Authorization EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.API_ClientId' + '1.1' + 'DECLARE API_ClientId EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.REPLY_TO_QUEUE' + '1.1' + 'DECLARE REPLY_TO_QUEUE EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.COMP_CODES_API_URL' + '1.1' + 'DECLARE COMP_CODES_API_URL EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_SERVER_NAME' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_SERVER_NAME EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_FROM_ADDR' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_FROM_ADDR EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_SUBJECT' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_SUBJECT EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_REPLYTO' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_REPLYTO EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_ATTCH_FILENAME' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_ATTCH_FILENAME EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_FLAG' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_FLAG EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.mqmft.xsi' + '1.1' + 'DECLARE xsi SHARED NAMESPACE 'http://www.w3.org/2001/XMLSchema-instance';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'JSON' + 1216 + 1541 + 'JSON' + gen.fulfillment_request_3.HTTP Input + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '4.3' + 'DECLARE AddTextValue CHARACTER;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '5.3' + 'DECLARE pattern CHARACTER '#,##0.00';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '8.3' + 'IF NOT EXISTS(InputRoot.JSON.Data[]) THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.JSON.Data[]' + 'LIST... First Element Type=16777216 NameSpace='' Name='Data' Value=NULL' + 'InputRoot.JSON.Data[]' + + + + 'TRUE' + 'EXISTS(InputRoot.JSON.Data[])' + + + + 'NOT TRUE' + 'FALSE' + 'NOT EXISTS(InputRoot.JSON.Data[])' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '12.3' + 'DECLARE cSiteCode CHARACTER COALESCE(InputLocalEnvironment.REST.Input.Parameters.siteCode, InputRoot.HTTPInputHeader.Sitecode);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputLocalEnvironment.REST.Input.Parameters.siteCode' + ''NBEU'' + 'InputLocalEnvironment.REST.Input.Parameters.siteCode' + + + + 'COALESCE('NBEU')' + ''NBEU'' + 'COALESCE(InputLocalEnvironment.REST.Input.Parameters.siteCode, InputRoot.HTTPInputHeader.Sitecode)' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '13.3' + 'SET cSiteCode = COALESCE(cSiteCode, InputLocalEnvironment.HTTP.Input.QueryString.siteCode);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + 'COALESCE('NBEU')' + ''NBEU'' + 'COALESCE(cSiteCode, InputLocalEnvironment.HTTP.Input.QueryString.siteCode)' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '14.3' + 'IF cSiteCode IS NULL OR cSiteCode = '' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + 'FALSE' + 'cSiteCode IS NULL' + + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + ''NBEU' = ''' + 'FALSE' + 'cSiteCode = ''' + + + + 'FALSE OR FALSE' + 'FALSE' + 'cSiteCode IS NULL OR cSiteCode = ''' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '18.3' + 'SET Environment.cSiteCode = cSiteCode;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + ''NBEU'' + 'Environment.cSiteCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '21.3' + 'DECLARE cPayloadPrefix CHARACTER;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '22.3' + 'SET cPayloadPrefix = com.nb.mqmft.GetPropertyForSiteCode(cSiteCode, 'PayloadPrefix');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.mqmft.GetPropertyForSiteCode(cSiteCode, 'PayloadPrefix')' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + 'com.nb.iib.util.SingleSiteCodeParmLookup.getTargetMFTDetails' + ''NBEU', 'PayloadPrefix'' + ''NBEU', 'PayloadPrefix'' + 'NULL' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '23.3' + 'IF cPayloadPrefix IS NULL OR cPayloadPrefix = '' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cPayloadPrefix' + 'NULL' + 'cPayloadPrefix' + + + + 'TRUE' + 'cPayloadPrefix IS NULL' + + + + 'TRUE OR X' + 'TRUE' + 'cPayloadPrefix IS NULL OR cPayloadPrefix = ''' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '24.4' + 'SET cPayloadPrefix = cSiteCode;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '28.3' + 'SET OutputLocalEnvironment.Variables.CompanyCode = com.nb.mqmft.GetPropertyForSiteCode(cSiteCode, 'CompanyCode');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.mqmft.GetPropertyForSiteCode(cSiteCode, 'CompanyCode')' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + 'com.nb.iib.util.SingleSiteCodeParmLookup.getTargetMFTDetails' + ''NBEU', 'CompanyCode'' + ''NBEU', 'CompanyCode'' + ''NB'' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''NB'' + 'OutputLocalEnvironment.Variables.CompanyCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '31.3' + 'SET OutputRoot.Properties = InputRoot.Properties;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.Properties' + 'ROW... Root Element Type=16777216 NameSpace='' Name='Properties' Value=NULL' + 'InputRoot.Properties' + + + + 'InputRoot.Properties' + 'OutputRoot.Properties' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '32.3' + 'DECLARE cCustomDesignId CHARACTER;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '33.3' + 'DECLARE rproductsRef REFERENCE TO InputRoot.JSON.Data.itemList.products;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '34.3' + 'DECLARE cOrderNumber CHARACTER InputRoot.JSON.Data.orderNumber;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.JSON.Data.orderNumber' + ''E300179204-15'' + 'InputRoot.JSON.Data.orderNumber' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '36.3' + 'SET Environment.Variables.cCompositeCompany = compositeFieldForCompany(OutputLocalEnvironment.Variables.CompanyCode, InputRoot.JSON.Data.billToAccount, InputRoot.JSON.Data.shippingDetail.accountLocationNumber);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'compositeFieldForCompany(OutputLocalEnvironment.Variables.CompanyCode, InputRoot.JSON.Data.billToAccount, InputRoot.JSON.Data.shippingDetail.accountLocationNumber)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'OutputLocalEnvironment.Variables.CompanyCode' + ''NB'' + 'OutputLocalEnvironment.Variables.CompanyCode' + + + + 'InputRoot.JSON.Data.billToAccount' + ''WEB-DE'' + 'InputRoot.JSON.Data.billToAccount' + + + + 'InputRoot.JSON.Data.shippingDetail.accountLocationNumber' + ''000'' + 'InputRoot.JSON.Data.shippingDetail.accountLocationNumber' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.compositeFieldForCompany' + '3.2' + 'IF LENGTH(billToAccount) < 8 THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'billToAccount' + ''WEB-DE'' + 'billToAccount' + + + + 'LENGTH('WEB-DE')' + '6' + 'LENGTH(billToAccount)' + + + + '6 < 8' + 'TRUE' + 'LENGTH(billToAccount) < 8' + + + + '.compositeFieldForCompany' + '4.5' + 'DECLARE cLengthOfAccNum INTEGER LENGTH(billToAccount);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'billToAccount' + ''WEB-DE'' + 'billToAccount' + + + + 'LENGTH('WEB-DE')' + '6' + 'LENGTH(billToAccount)' + + + + '.compositeFieldForCompany' + '5.5' + 'DECLARE cNumOfSpacesNeeded INTEGER 8 - cLengthOfAccNum;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cLengthOfAccNum' + '6' + 'cLengthOfAccNum' + + + + '8 - 6' + '2' + '8 - cLengthOfAccNum' + + + + 'WHILE cNumOfSpacesNeeded > 0 DO ... END WHILE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cNumOfSpacesNeeded' + '2' + 'cNumOfSpacesNeeded' + + + + '2 > 0' + 'TRUE' + 'cNumOfSpacesNeeded > 0' + + + + '.compositeFieldForCompany' + '7.6' + 'SET billToAccount = billToAccount || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'billToAccount' + ''WEB-DE'' + 'billToAccount' + + + + ''WEB-DE' || ' '' + ''WEB-DE '' + 'billToAccount || ' '' + + + + '.compositeFieldForCompany' + '8.6' + 'SET cNumOfSpacesNeeded = cNumOfSpacesNeeded - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cNumOfSpacesNeeded' + '2' + 'cNumOfSpacesNeeded' + + + + '2 - 1' + '1' + 'cNumOfSpacesNeeded - 1' + + + + 'cNumOfSpacesNeeded' + '1' + 'cNumOfSpacesNeeded' + + + + '1 > 0' + 'TRUE' + 'cNumOfSpacesNeeded > 0' + + + + '.compositeFieldForCompany' + '7.6' + 'SET billToAccount = billToAccount || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'billToAccount' + ''WEB-DE '' + 'billToAccount' + + + + ''WEB-DE ' || ' '' + ''WEB-DE '' + 'billToAccount || ' '' + + + + '.compositeFieldForCompany' + '8.6' + 'SET cNumOfSpacesNeeded = cNumOfSpacesNeeded - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cNumOfSpacesNeeded' + '1' + 'cNumOfSpacesNeeded' + + + + '1 - 1' + '0' + 'cNumOfSpacesNeeded - 1' + + + + 'cNumOfSpacesNeeded' + '0' + 'cNumOfSpacesNeeded' + + + + '0 > 0' + 'FALSE' + 'cNumOfSpacesNeeded > 0' + + + + '.compositeFieldForCompany' + '11.2' + 'RETURN COALESCE(companyCode, '') || COALESCE(billToAccount, '') || COALESCE(accountLocationNumber, '');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'companyCode' + ''NB'' + 'companyCode' + + + + 'COALESCE('NB')' + ''NB'' + 'COALESCE(companyCode, '')' + + + + 'billToAccount' + ''WEB-DE '' + 'billToAccount' + + + + 'COALESCE('WEB-DE ')' + ''WEB-DE '' + 'COALESCE(billToAccount, '')' + + + + ''NB' || 'WEB-DE '' + ''NBWEB-DE '' + 'COALESCE(companyCode, '') || COALESCE(billToAccount, '')' + + + + 'accountLocationNumber' + ''000'' + 'accountLocationNumber' + + + + 'COALESCE('000')' + ''000'' + 'COALESCE(accountLocationNumber, '')' + + + + ''NBWEB-DE ' || '000'' + ''NBWEB-DE 000'' + 'COALESCE(companyCode, '') || COALESCE(billToAccount, '') || COALESCE(accountLocationNumber, '')' + + + + ''NBWEB-DE 000'' + 'Environment.Variables.cCompositeCompany' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '37.3' + 'DECLARE X INTEGER 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '39.3' + 'IF InputRoot.JSON.Data.processingType = 'PZ' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.JSON.Data.processingType' + 'ROW... Root Element Type=50331648 NameSpace='' Name='processingType' Value='ST'' + 'InputRoot.JSON.Data.processingType' + + + + 'ROW... Root Element Type=50331648 NameSpace='' Name='processingType' Value='ST' = 'PZ'' + 'FALSE' + 'InputRoot.JSON.Data.processingType = 'PZ'' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '42.3' + 'IF InputRoot.JSON.Data.processingType = 'ST' AND cSiteCode = 'NBEU' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.JSON.Data.processingType' + 'ROW... Root Element Type=50331648 NameSpace='' Name='processingType' Value='ST'' + 'InputRoot.JSON.Data.processingType' + + + + 'ROW... Root Element Type=50331648 NameSpace='' Name='processingType' Value='ST' = 'ST'' + 'TRUE' + 'InputRoot.JSON.Data.processingType = 'ST'' + + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + ''NBEU' = 'NBEU'' + 'TRUE' + 'cSiteCode = 'NBEU'' + + + + 'TRUE AND TRUE' + 'TRUE' + 'InputRoot.JSON.Data.processingType = 'ST' AND cSiteCode = 'NBEU'' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '43.4' + 'SET OutputRoot.JSON.Data.shippingDetail.accountLocationNumber = '007';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''007'' + 'OutputRoot.JSON.Data.shippingDetail.accountLocationNumber' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '45.3' + 'IF InputRoot.JSON.Data.processingType = 'ST' AND cSiteCode = 'NBUK' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.JSON.Data.processingType' + 'ROW... Root Element Type=50331648 NameSpace='' Name='processingType' Value='ST'' + 'InputRoot.JSON.Data.processingType' + + + + 'ROW... Root Element Type=50331648 NameSpace='' Name='processingType' Value='ST' = 'ST'' + 'TRUE' + 'InputRoot.JSON.Data.processingType = 'ST'' + + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + ''NBEU' = 'NBUK'' + 'FALSE' + 'cSiteCode = 'NBUK'' + + + + 'TRUE AND FALSE' + 'FALSE' + 'InputRoot.JSON.Data.processingType = 'ST' AND cSiteCode = 'NBUK'' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '49.3' + 'SET Environment.Variables.orderDate = com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate(InputRoot.JSON.Data.orderDate);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate(InputRoot.JSON.Data.orderDate)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.JSON.Data.orderDate' + ''2019-02-18'' + 'InputRoot.JSON.Data.orderDate' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate' + '4.2' + 'DECLARE tempDateTime TIMESTAMP;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate' + '5.2' + 'IF LENGTH(tDeliveryDate) = 10 THEN... ELSEIF LENGTH(tDeliveryDate) = 20 THEN... ELSEIF LENGTH(tDeliveryDate) = 23 THEN... ELSE... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'tDeliveryDate' + ''2019-02-18'' + 'tDeliveryDate' + + + + 'LENGTH('2019-02-18')' + '10' + 'LENGTH(tDeliveryDate)' + + + + '10 = 10' + 'TRUE' + 'LENGTH(tDeliveryDate) = 10' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate' + '6.3' + 'SET tempDateTime = CAST(tDeliveryDate AS TIMESTAMP FORMAT 'YYYY-MM-dd');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'tDeliveryDate' + ''2019-02-18'' + 'tDeliveryDate' + + + + 'CAST('2019-02-18' AS TIMESTAMP FORMAT 'YYYY-MM-dd' )' + 'TIMESTAMP '2019-02-18 13:23:07.737752'' + 'CAST(tDeliveryDate AS TIMESTAMP FORMAT 'YYYY-MM-dd')' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate' + '14.2' + 'RETURN '1' || CAST(tempDateTime AS CHARACTER FORMAT 'YYMMdd');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'tempDateTime' + 'TIMESTAMP '2019-02-18 13:23:07.737752'' + 'tempDateTime' + + + + 'CAST(TIMESTAMP '2019-02-18 13:23:07.737752' AS CHARACTER FORMAT 'YYMMdd' )' + ''190218'' + 'CAST(tempDateTime AS CHARACTER FORMAT 'YYMMdd')' + + + + ''1' || '190218'' + ''1190218'' + ''1' || CAST(tempDateTime AS CHARACTER FORMAT 'YYMMdd')' + + + + ''1190218'' + 'Environment.Variables.orderDate' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '50.3' + 'SET Environment.Variables.shipNotBeforeDate = com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate(InputRoot.JSON.Data.shippingDetail.shipNotBeforeDate);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate(InputRoot.JSON.Data.shippingDetail.shipNotBeforeDate)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 5 + + + + 'InputRoot.JSON.Data.shippingDetail.shipNotBeforeDate' + 'NULL' + 'InputRoot.JSON.Data.shippingDetail.shipNotBeforeDate' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate' + '4.2' + 'DECLARE tempDateTime TIMESTAMP;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate' + '5.2' + 'IF LENGTH(tDeliveryDate) = 10 THEN... ELSEIF LENGTH(tDeliveryDate) = 20 THEN... ELSEIF LENGTH(tDeliveryDate) = 23 THEN... ELSE... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'tDeliveryDate' + 'NULL' + 'tDeliveryDate' + + + + 'LENGTH(NULL)' + 'NULL' + 'LENGTH(tDeliveryDate)' + + + + 'NULL = 10' + 'NULL' + 'LENGTH(tDeliveryDate) = 10' + + + + 'tDeliveryDate' + 'NULL' + 'tDeliveryDate' + + + + 'LENGTH(NULL)' + 'NULL' + 'LENGTH(tDeliveryDate)' + + + + 'NULL = 20' + 'NULL' + 'LENGTH(tDeliveryDate) = 20' + + + + 'tDeliveryDate' + 'NULL' + 'tDeliveryDate' + + + + 'LENGTH(NULL)' + 'NULL' + 'LENGTH(tDeliveryDate)' + + + + 'NULL = 23' + 'NULL' + 'LENGTH(tDeliveryDate) = 23' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate' + '12.3' + 'SET tempDateTime = CAST(tDeliveryDate AS TIMESTAMP FORMAT 'YYYY-MM-dd'T'HH:mm:ss.SSS'Z');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'tDeliveryDate' + 'NULL' + 'tDeliveryDate' + + + + 'CAST(NULL AS TIMESTAMP FORMAT 'YYYY-MM-dd'T'HH:mm:ss.SSS'Z' )' + 'NULL' + 'CAST(tDeliveryDate AS TIMESTAMP FORMAT 'YYYY-MM-dd'T'HH:mm:ss.SSS'Z')' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.reformatDateToAuroraCenturyDate' + '14.2' + 'RETURN '1' || CAST(tempDateTime AS CHARACTER FORMAT 'YYMMdd');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'tempDateTime' + 'NULL' + 'tempDateTime' + + + + 'CAST(NULL AS CHARACTER FORMAT 'YYMMdd' )' + 'NULL' + 'CAST(tempDateTime AS CHARACTER FORMAT 'YYMMdd')' + + + + ''1' || NULL' + 'NULL' + ''1' || CAST(tempDateTime AS CHARACTER FORMAT 'YYMMdd')' + + + + 'Environment.Variables.shipNotBeforeDate' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '52.3' + 'SET Environment.Variables.cCompositeCompany = compositeFieldForCompany(OutputLocalEnvironment.Variables.CompanyCode, InputRoot.JSON.Data.billToAccount, OutputRoot.JSON.Data.shippingDetail.accountLocationNumber);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'compositeFieldForCompany(OutputLocalEnvironment.Variables.CompanyCode, InputRoot.JSON.Data.billToAccount, OutputRoot.JSON.Data.shippingDetail.accountLocationNumber)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'OutputLocalEnvironment.Variables.CompanyCode' + ''NB'' + 'OutputLocalEnvironment.Variables.CompanyCode' + + + + 'InputRoot.JSON.Data.billToAccount' + ''WEB-DE'' + 'InputRoot.JSON.Data.billToAccount' + + + + 'OutputRoot.JSON.Data.shippingDetail.accountLocationNumber' + ''007'' + 'OutputRoot.JSON.Data.shippingDetail.accountLocationNumber' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.compositeFieldForCompany' + '3.2' + 'IF LENGTH(billToAccount) < 8 THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'billToAccount' + ''WEB-DE'' + 'billToAccount' + + + + 'LENGTH('WEB-DE')' + '6' + 'LENGTH(billToAccount)' + + + + '6 < 8' + 'TRUE' + 'LENGTH(billToAccount) < 8' + + + + '.compositeFieldForCompany' + '4.5' + 'DECLARE cLengthOfAccNum INTEGER LENGTH(billToAccount);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'billToAccount' + ''WEB-DE'' + 'billToAccount' + + + + 'LENGTH('WEB-DE')' + '6' + 'LENGTH(billToAccount)' + + + + '.compositeFieldForCompany' + '5.5' + 'DECLARE cNumOfSpacesNeeded INTEGER 8 - cLengthOfAccNum;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cLengthOfAccNum' + '6' + 'cLengthOfAccNum' + + + + '8 - 6' + '2' + '8 - cLengthOfAccNum' + + + + 'WHILE cNumOfSpacesNeeded > 0 DO ... END WHILE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cNumOfSpacesNeeded' + '2' + 'cNumOfSpacesNeeded' + + + + '2 > 0' + 'TRUE' + 'cNumOfSpacesNeeded > 0' + + + + '.compositeFieldForCompany' + '7.6' + 'SET billToAccount = billToAccount || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'billToAccount' + ''WEB-DE'' + 'billToAccount' + + + + ''WEB-DE' || ' '' + ''WEB-DE '' + 'billToAccount || ' '' + + + + '.compositeFieldForCompany' + '8.6' + 'SET cNumOfSpacesNeeded = cNumOfSpacesNeeded - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cNumOfSpacesNeeded' + '2' + 'cNumOfSpacesNeeded' + + + + '2 - 1' + '1' + 'cNumOfSpacesNeeded - 1' + + + + 'cNumOfSpacesNeeded' + '1' + 'cNumOfSpacesNeeded' + + + + '1 > 0' + 'TRUE' + 'cNumOfSpacesNeeded > 0' + + + + '.compositeFieldForCompany' + '7.6' + 'SET billToAccount = billToAccount || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'billToAccount' + ''WEB-DE '' + 'billToAccount' + + + + ''WEB-DE ' || ' '' + ''WEB-DE '' + 'billToAccount || ' '' + + + + '.compositeFieldForCompany' + '8.6' + 'SET cNumOfSpacesNeeded = cNumOfSpacesNeeded - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cNumOfSpacesNeeded' + '1' + 'cNumOfSpacesNeeded' + + + + '1 - 1' + '0' + 'cNumOfSpacesNeeded - 1' + + + + 'cNumOfSpacesNeeded' + '0' + 'cNumOfSpacesNeeded' + + + + '0 > 0' + 'FALSE' + 'cNumOfSpacesNeeded > 0' + + + + '.compositeFieldForCompany' + '11.2' + 'RETURN COALESCE(companyCode, '') || COALESCE(billToAccount, '') || COALESCE(accountLocationNumber, '');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'companyCode' + ''NB'' + 'companyCode' + + + + 'COALESCE('NB')' + ''NB'' + 'COALESCE(companyCode, '')' + + + + 'billToAccount' + ''WEB-DE '' + 'billToAccount' + + + + 'COALESCE('WEB-DE ')' + ''WEB-DE '' + 'COALESCE(billToAccount, '')' + + + + ''NB' || 'WEB-DE '' + ''NBWEB-DE '' + 'COALESCE(companyCode, '') || COALESCE(billToAccount, '')' + + + + 'accountLocationNumber' + ''007'' + 'accountLocationNumber' + + + + 'COALESCE('007')' + ''007'' + 'COALESCE(accountLocationNumber, '')' + + + + ''NBWEB-DE ' || '007'' + ''NBWEB-DE 007'' + 'COALESCE(companyCode, '') || COALESCE(billToAccount, '') || COALESCE(accountLocationNumber, '')' + + + + ''NBWEB-DE 007'' + 'Environment.Variables.cCompositeCompany' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '55.4' + 'FOR rItemRef AS rproductsRef.Item[] DO ... END FOR;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '56.5' + 'IF Environment.Variables.shipNotBeforeDate IS NULL THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 3 + + + + 'Environment.Variables.shipNotBeforeDate' + 'NULL' + 'Environment.Variables.shipNotBeforeDate' + + + + 'TRUE' + 'Environment.Variables.shipNotBeforeDate IS NULL' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '59.5' + 'SET Environment.Variables.item[X].quantity = com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraInteger(CAST(rproductsRef.Item[X].quantity AS CHARACTER), 3);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraInteger(CAST(rproductsRef.Item[X].quantity AS CHARACTER), 3)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '1' + 'X' + + + + 'X' + '1' + 'X' + + + + 'rproductsRef.Item[1].quantity' + '1' + 'rproductsRef.Item[X].quantity' + + + + 'CAST(1 AS CHARACTER)' + ''1'' + 'CAST(rproductsRef.Item[X].quantity AS CHARACTER)' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'WHILE NumberOfDecimals > 0 DO ... END WHILE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'NumberOfDecimals' + '3' + 'NumberOfDecimals' + + + + '3 > 0' + 'TRUE' + 'NumberOfDecimals > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraInteger' + '4.3' + 'SET Num1 = Num1 || '0';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Num1' + ''1'' + 'Num1' + + + + ''1' || '0'' + ''10'' + 'Num1 || '0'' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraInteger' + '5.3' + 'SET NumberOfDecimals = NumberOfDecimals - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'NumberOfDecimals' + '3' + 'NumberOfDecimals' + + + + '3 - 1' + '2' + 'NumberOfDecimals - 1' + + + + 'NumberOfDecimals' + '2' + 'NumberOfDecimals' + + + + '2 > 0' + 'TRUE' + 'NumberOfDecimals > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraInteger' + '4.3' + 'SET Num1 = Num1 || '0';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Num1' + ''10'' + 'Num1' + + + + ''10' || '0'' + ''100'' + 'Num1 || '0'' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraInteger' + '5.3' + 'SET NumberOfDecimals = NumberOfDecimals - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'NumberOfDecimals' + '2' + 'NumberOfDecimals' + + + + '2 - 1' + '1' + 'NumberOfDecimals - 1' + + + + 'NumberOfDecimals' + '1' + 'NumberOfDecimals' + + + + '1 > 0' + 'TRUE' + 'NumberOfDecimals > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraInteger' + '4.3' + 'SET Num1 = Num1 || '0';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Num1' + ''100'' + 'Num1' + + + + ''100' || '0'' + ''1000'' + 'Num1 || '0'' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraInteger' + '5.3' + 'SET NumberOfDecimals = NumberOfDecimals - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'NumberOfDecimals' + '1' + 'NumberOfDecimals' + + + + '1 - 1' + '0' + 'NumberOfDecimals - 1' + + + + 'NumberOfDecimals' + '0' + 'NumberOfDecimals' + + + + '0 > 0' + 'FALSE' + 'NumberOfDecimals > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraInteger' + '7.2' + 'RETURN Num1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Num1' + ''1000'' + 'Num1' + + + + 'X' + '1' + 'X' + + + + ''1000'' + 'Environment.Variables.item[X].quantity' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '60.5' + 'SET Environment.Variables.item[X].itemTaxTot = CAST(rproductsRef.Item[X].itemTaxTotal AS CHARACTER);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '1' + 'X' + + + + 3 + + + + 'X' + '1' + 'X' + + + + 'rproductsRef.Item[1].itemTaxTotal' + 'NULL' + 'rproductsRef.Item[X].itemTaxTotal' + + + + 'CAST(NULL AS CHARACTER)' + 'NULL' + 'CAST(rproductsRef.Item[X].itemTaxTotal AS CHARACTER)' + + + + 'X' + '1' + 'X' + + + + 'Environment.Variables.item[X].itemTaxTot' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '61.5' + 'SET Environment.Variables.item[X].delDate = reformatDate(InputRoot.JSON.Data.shippingDetail.deliveryDate, rproductsRef.Item[X].lineId);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'reformatDate(InputRoot.JSON.Data.shippingDetail.deliveryDate, rproductsRef.Item[X].lineId)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.JSON.Data.shippingDetail.deliveryDate' + ''2019-02-28 00:00:00'' + 'InputRoot.JSON.Data.shippingDetail.deliveryDate' + + + + 'X' + '1' + 'X' + + + + 'X' + '1' + 'X' + + + + 'rproductsRef.Item[1].lineId' + '1' + 'rproductsRef.Item[X].lineId' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.reformatDate' + '3.2' + 'DECLARE tempDateTime TIMESTAMP;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.reformatDate' + '4.3' + 'SET cLineId = cLineId - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cLineId' + '1' + 'cLineId' + + + + '1 - 1' + '0' + 'cLineId - 1' + + + + '.reformatDate' + '5.3' + 'SET tempDateTime = CAST(tDeliveryDate AS TIMESTAMP FORMAT 'YYYY-MM-dd HH:mm:SS') + CAST(cLineId AS INTERVAL DAY);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'tDeliveryDate' + ''2019-02-28 00:00:00'' + 'tDeliveryDate' + + + + 'CAST('2019-02-28 00:00:00' AS TIMESTAMP FORMAT 'YYYY-MM-dd HH:mm:SS' )' + 'TIMESTAMP '2019-02-28 00:00:00'' + 'CAST(tDeliveryDate AS TIMESTAMP FORMAT 'YYYY-MM-dd HH:mm:SS')' + + + + 'cLineId' + '0' + 'cLineId' + + + + 'CAST(0 AS INTERVAL DAY)' + 'INTERVAL '0' DAY' + 'CAST(cLineId AS INTERVAL DAY)' + + + + 'TIMESTAMP '2019-02-28 00:00:00' + INTERVAL '0' DAY' + 'TIMESTAMP '2019-02-28 00:00:00'' + 'CAST(tDeliveryDate AS TIMESTAMP FORMAT 'YYYY-MM-dd HH:mm:SS') + CAST(cLineId AS INTERVAL DAY)' + + + + '.reformatDate' + '6.3' + 'RETURN '1' || SUBSTRING(CAST(tempDateTime AS CHARACTER FORMAT 'YYYYMMdd') FROM 3 FOR 6);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'tempDateTime' + 'TIMESTAMP '2019-02-28 00:00:00'' + 'tempDateTime' + + + + 'CAST(TIMESTAMP '2019-02-28 00:00:00' AS CHARACTER FORMAT 'YYYYMMdd' )' + ''20190228'' + 'CAST(tempDateTime AS CHARACTER FORMAT 'YYYYMMdd')' + + + + 'SUBSTRING('20190228' FROM 3 FOR 6)' + ''190228'' + 'SUBSTRING(CAST(tempDateTime AS CHARACTER FORMAT 'YYYYMMdd') FROM 3 FOR 6)' + + + + ''1' || '190228'' + ''1190228'' + ''1' || SUBSTRING(CAST(tempDateTime AS CHARACTER FORMAT 'YYYYMMdd') FROM 3 FOR 6)' + + + + 'X' + '1' + 'X' + + + + ''1190228'' + 'Environment.Variables.item[X].delDate' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '62.5' + 'SET Environment.Variables.item[X].sku = com.nb.esb.iib.cmn.util.esql.utilities.compositeFieldForSKU(rproductsRef.Item[X].sku.style, rproductsRef.Item[X].sku.widthOrColor, rproductsRef.Item[X].sku.size);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.compositeFieldForSKU(rproductsRef.Item[X].sku.style, rproductsRef.Item[X].sku.widthOrColor, rproductsRef.Item[X].sku.size)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '1' + 'X' + + + + 'X' + '1' + 'X' + + + + 'rproductsRef.Item[1].sku.style' + ''MS831015'' + 'rproductsRef.Item[X].sku.style' + + + + 'X' + '1' + 'X' + + + + 'X' + '1' + 'X' + + + + 'rproductsRef.Item[1].sku.widthOrColor' + ''CTR'' + 'rproductsRef.Item[X].sku.widthOrColor' + + + + 'X' + '1' + 'X' + + + + 'X' + '1' + 'X' + + + + 'rproductsRef.Item[1].sku.size' + ''M'' + 'rproductsRef.Item[X].sku.size' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.compositeFieldForSKU' + '4.2' + 'IF LENGTH(Style) < 9 THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Style' + ''MS831015'' + 'Style' + + + + 'LENGTH('MS831015')' + '8' + 'LENGTH(Style)' + + + + '8 < 9' + 'TRUE' + 'LENGTH(Style) < 9' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.compositeFieldForSKU' + '5.3' + 'DECLARE cLengthOfStyle INTEGER LENGTH(Style);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Style' + ''MS831015'' + 'Style' + + + + 'LENGTH('MS831015')' + '8' + 'LENGTH(Style)' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.compositeFieldForSKU' + '6.3' + 'DECLARE cNumOfSpacesNeeded INTEGER 9 - cLengthOfStyle;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cLengthOfStyle' + '8' + 'cLengthOfStyle' + + + + '9 - 8' + '1' + '9 - cLengthOfStyle' + + + + 'WHILE cNumOfSpacesNeeded > 0 DO ... END WHILE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cNumOfSpacesNeeded' + '1' + 'cNumOfSpacesNeeded' + + + + '1 > 0' + 'TRUE' + 'cNumOfSpacesNeeded > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.compositeFieldForSKU' + '8.4' + 'SET Style = Style || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Style' + ''MS831015'' + 'Style' + + + + ''MS831015' || ' '' + ''MS831015 '' + 'Style || ' '' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.compositeFieldForSKU' + '9.4' + 'SET cNumOfSpacesNeeded = cNumOfSpacesNeeded - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cNumOfSpacesNeeded' + '1' + 'cNumOfSpacesNeeded' + + + + '1 - 1' + '0' + 'cNumOfSpacesNeeded - 1' + + + + 'cNumOfSpacesNeeded' + '0' + 'cNumOfSpacesNeeded' + + + + '0 > 0' + 'FALSE' + 'cNumOfSpacesNeeded > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.compositeFieldForSKU' + '12.2' + 'IF LENGTH(Color) < 3 THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Color' + ''CTR'' + 'Color' + + + + 'LENGTH('CTR')' + '3' + 'LENGTH(Color)' + + + + '3 < 3' + 'FALSE' + 'LENGTH(Color) < 3' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.compositeFieldForSKU' + '20.2' + 'RETURN COALESCE(Style, '') || COALESCE(Color, '') || COALESCE(Size, '');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Style' + ''MS831015 '' + 'Style' + + + + 'COALESCE('MS831015 ')' + ''MS831015 '' + 'COALESCE(Style, '')' + + + + 'Color' + ''CTR'' + 'Color' + + + + 'COALESCE('CTR')' + ''CTR'' + 'COALESCE(Color, '')' + + + + ''MS831015 ' || 'CTR'' + ''MS831015 CTR'' + 'COALESCE(Style, '') || COALESCE(Color, '')' + + + + 'Size' + ''M'' + 'Size' + + + + 'COALESCE('M')' + ''M'' + 'COALESCE(Size, '')' + + + + ''MS831015 CTR' || 'M'' + ''MS831015 CTRM'' + 'COALESCE(Style, '') || COALESCE(Color, '') || COALESCE(Size, '')' + + + + 'X' + '1' + 'X' + + + + ''MS831015 CTRM'' + 'Environment.Variables.item[X].sku' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '63.5' + 'SET Environment.Variables.item[X].ppu = com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal(CAST(rproductsRef.Item[X].pricePerUnit AS CHARACTER FORMAT pattern), 3);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal(CAST(rproductsRef.Item[X].pricePerUnit AS CHARACTER FORMAT pattern), 3)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '1' + 'X' + + + + 'X' + '1' + 'X' + + + + 'rproductsRef.Item[1].pricePerUnit' + '34' + 'rproductsRef.Item[X].pricePerUnit' + + + + 'pattern' + ''#,##0.00'' + 'pattern' + + + + 'CAST(34 AS CHARACTER FORMAT '#,##0.00' )' + ''34.00'' + 'CAST(rproductsRef.Item[X].pricePerUnit AS CHARACTER FORMAT pattern)' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal' + '3.2' + 'DECLARE Predec CHARACTER SUBSTRING(Num1 BEFORE '.');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Num1' + ''34.00'' + 'Num1' + + + + 'SUBSTRING('34.00' BEFORE '.')' + ''34'' + 'SUBSTRING(Num1 BEFORE '.')' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal' + '4.2' + 'DECLARE Postdec CHARACTER SUBSTRING(Num1 AFTER '.');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Num1' + ''34.00'' + 'Num1' + + + + 'SUBSTRING('34.00' AFTER '.')' + ''00'' + 'SUBSTRING(Num1 AFTER '.')' + + + + 'WHILE NumberOfDecimals > 0 DO ... END WHILE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'NumberOfDecimals' + '3' + 'NumberOfDecimals' + + + + '3 > 0' + 'TRUE' + 'NumberOfDecimals > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal' + '6.3' + 'SET Postdec = Postdec || '0';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Postdec' + ''00'' + 'Postdec' + + + + ''00' || '0'' + ''000'' + 'Postdec || '0'' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal' + '7.3' + 'SET NumberOfDecimals = NumberOfDecimals - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'NumberOfDecimals' + '3' + 'NumberOfDecimals' + + + + '3 - 1' + '2' + 'NumberOfDecimals - 1' + + + + 'NumberOfDecimals' + '2' + 'NumberOfDecimals' + + + + '2 > 0' + 'TRUE' + 'NumberOfDecimals > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal' + '6.3' + 'SET Postdec = Postdec || '0';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Postdec' + ''000'' + 'Postdec' + + + + ''000' || '0'' + ''0000'' + 'Postdec || '0'' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal' + '7.3' + 'SET NumberOfDecimals = NumberOfDecimals - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'NumberOfDecimals' + '2' + 'NumberOfDecimals' + + + + '2 - 1' + '1' + 'NumberOfDecimals - 1' + + + + 'NumberOfDecimals' + '1' + 'NumberOfDecimals' + + + + '1 > 0' + 'TRUE' + 'NumberOfDecimals > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal' + '6.3' + 'SET Postdec = Postdec || '0';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Postdec' + ''0000'' + 'Postdec' + + + + ''0000' || '0'' + ''00000'' + 'Postdec || '0'' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal' + '7.3' + 'SET NumberOfDecimals = NumberOfDecimals - 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'NumberOfDecimals' + '1' + 'NumberOfDecimals' + + + + '1 - 1' + '0' + 'NumberOfDecimals - 1' + + + + 'NumberOfDecimals' + '0' + 'NumberOfDecimals' + + + + '0 > 0' + 'FALSE' + 'NumberOfDecimals > 0' + + + + 'com.nb.esb.iib.cmn.util.esql.utilities.convertToAuroraDecimal' + '9.2' + 'RETURN COALESCE(Predec, '') || COALESCE(Postdec, '');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Predec' + ''34'' + 'Predec' + + + + 'COALESCE('34')' + ''34'' + 'COALESCE(Predec, '')' + + + + 'Postdec' + ''00000'' + 'Postdec' + + + + 'COALESCE('00000')' + ''00000'' + 'COALESCE(Postdec, '')' + + + + ''34' || '00000'' + ''3400000'' + 'COALESCE(Predec, '') || COALESCE(Postdec, '')' + + + + 'X' + '1' + 'X' + + + + ''3400000'' + 'Environment.Variables.item[X].ppu' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '64.5' + 'SET cCustomDesignId = rItemRef.customDesignId;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rItemRef.customDesignId' + '' '' + 'rItemRef.customDesignId' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '65.5' + 'SET Environment.Variables.NumberOfOrderLines = COALESCE(Environment.Variables.NumberOfOrderLines, 0) + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 3 + + + + 'Environment.Variables.NumberOfOrderLines' + 'NULL' + 'Environment.Variables.NumberOfOrderLines' + + + + 'COALESCE(NULL, 0)' + '0' + 'COALESCE(Environment.Variables.NumberOfOrderLines, 0)' + + + + '0 + 1' + '1' + 'COALESCE(Environment.Variables.NumberOfOrderLines, 0) + 1' + + + + '1' + 'Environment.Variables.NumberOfOrderLines' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '66.5' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '1' + 'X' + + + + '1 + 1' + '2' + 'X + 1' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '70.3' + 'CALL CopyMessageHeaders();' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'CopyMessageHeaders()' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.CopyMessageHeaders' + '2.3' + 'DECLARE I INTEGER 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.CopyMessageHeaders' + '3.3' + 'DECLARE J INTEGER;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.CopyMessageHeaders' + '4.3' + 'SET J = CARDINALITY(InputRoot.*:*[]);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.*:*[]' + 'LIST... First Element Type=16777216 NameSpace='' Name='Properties' Value=NULL' + 'InputRoot.*:*[]' + + + + '3' + 'CARDINALITY(InputRoot.*:*[])' + + + + 'WHILE I < J DO ... END WHILE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'I' + '1' + 'I' + + + + 'J' + '3' + 'J' + + + + '1 < 3' + 'TRUE' + 'I < J' + + + + '.post_FullFillmentReq_Route_Compute.CopyMessageHeaders' + '6.4' + 'SET OutputRoot.*:*[I] = InputRoot.*:*[I];' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'I' + '1' + 'I' + + + + 'I' + '1' + 'I' + + + + 'InputRoot.*:*[1]' + 'ROW... Root Element Type=16777216 NameSpace='' Name='Properties' Value=NULL' + 'InputRoot.*:*[I]' + + + + 'I' + '1' + 'I' + + + + 'InputRoot.*:*[I]' + 'OutputRoot.*:*[I]' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.CopyMessageHeaders' + '7.4' + 'SET I = I + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'I' + '1' + 'I' + + + + '1 + 1' + '2' + 'I + 1' + + + + 'I' + '2' + 'I' + + + + 'J' + '3' + 'J' + + + + '2 < 3' + 'TRUE' + 'I < J' + + + + '.post_FullFillmentReq_Route_Compute.CopyMessageHeaders' + '6.4' + 'SET OutputRoot.*:*[I] = InputRoot.*:*[I];' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'I' + '2' + 'I' + + + + 'I' + '2' + 'I' + + + + 'InputRoot.*:*[2]' + 'ROW... Root Element Type=16777216 NameSpace='' Name='HTTPInputHeader' Value=NULL' + 'InputRoot.*:*[I]' + + + + 'I' + '2' + 'I' + + + + 'InputRoot.*:*[I]' + 'OutputRoot.*:*[I]' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.CopyMessageHeaders' + '7.4' + 'SET I = I + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'I' + '2' + 'I' + + + + '2 + 1' + '3' + 'I + 1' + + + + 'I' + '3' + 'I' + + + + 'J' + '3' + 'J' + + + + '3 < 3' + 'FALSE' + 'I < J' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '71.3' + 'CALL CopyEntireMessage();' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'CopyEntireMessage()' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.CopyEntireMessage' + '2.3' + 'SET OutputRoot = InputRoot;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot' + 'ROW... Root Element Type=16777216 NameSpace='' Name='Root' Value=NULL' + 'InputRoot' + + + + 'InputRoot' + 'OutputRoot' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '74.6' + 'SET OutputLocalEnvironment.UniquenessId = SUBSTRING(UUIDASCHAR FROM 1 FOR 4) || SUBSTRING(UUIDASCHAR FROM 2 FOR 4) || SUBSTRING(UUIDASCHAR FROM 3 FOR 2);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''effb1c05-85a1-4d25-995d-1ae69f8cd627'' + 'UUIDASCHAR' + + + + 'SUBSTRING('effb1c05-85a1-4d25-995d-1ae69f8cd627' FROM 1 FOR 4)' + ''effb'' + 'SUBSTRING(UUIDASCHAR FROM 1 FOR 4)' + + + + ''fca92634-9de0-47b5-8173-b660dca1ce7d'' + 'UUIDASCHAR' + + + + 'SUBSTRING('fca92634-9de0-47b5-8173-b660dca1ce7d' FROM 2 FOR 4)' + ''ca92'' + 'SUBSTRING(UUIDASCHAR FROM 2 FOR 4)' + + + + ''effb' || 'ca92'' + ''effbca92'' + 'SUBSTRING(UUIDASCHAR FROM 1 FOR 4) || SUBSTRING(UUIDASCHAR FROM 2 FOR 4)' + + + + ''7707d64d-9f1a-4eca-bd36-6b1d18d6c49d'' + 'UUIDASCHAR' + + + + 'SUBSTRING('7707d64d-9f1a-4eca-bd36-6b1d18d6c49d' FROM 3 FOR 2)' + ''07'' + 'SUBSTRING(UUIDASCHAR FROM 3 FOR 2)' + + + + ''effbca92' || '07'' + ''effbca9207'' + 'SUBSTRING(UUIDASCHAR FROM 1 FOR 4) || SUBSTRING(UUIDASCHAR FROM 2 FOR 4) || SUBSTRING(UUIDASCHAR FROM 3 FOR 2)' + + + + ''effbca9207'' + 'OutputLocalEnvironment.UniquenessId' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '75.3' + 'SET Environment.UniquenessId = OutputLocalEnvironment.UniquenessId;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'OutputLocalEnvironment.UniquenessId' + 'ROW... Root Element Type=50331648 NameSpace='' Name='UniquenessId' Value='effbca9207'' + 'OutputLocalEnvironment.UniquenessId' + + + + 'OutputLocalEnvironment.UniquenessId' + 'Environment.UniquenessId' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '78.3' + 'SET Environment.payLoadGroupID = CAST(Environment.UniquenessId || '0000' || Environment.UniquenessId AS BLOB) || CAST(Environment.UniquenessId || '0000' || Environment.UniquenessId AS BLOB);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Environment.UniquenessId' + ''effbca9207'' + 'Environment.UniquenessId' + + + + ''effbca9207' || '0000'' + ''effbca92070000'' + 'Environment.UniquenessId || '0000'' + + + + 'Environment.UniquenessId' + ''effbca9207'' + 'Environment.UniquenessId' + + + + ''effbca92070000' || 'effbca9207'' + ''effbca92070000effbca9207'' + 'Environment.UniquenessId || '0000' || Environment.UniquenessId' + + + + 'CAST('effbca92070000effbca9207' AS BLOB)' + 'X'effbca92070000effbca9207'' + 'CAST(Environment.UniquenessId || '0000' || Environment.UniquenessId AS BLOB)' + + + + 'Environment.UniquenessId' + ''effbca9207'' + 'Environment.UniquenessId' + + + + ''effbca9207' || '0000'' + ''effbca92070000'' + 'Environment.UniquenessId || '0000'' + + + + 'Environment.UniquenessId' + ''effbca9207'' + 'Environment.UniquenessId' + + + + ''effbca92070000' || 'effbca9207'' + ''effbca92070000effbca9207'' + 'Environment.UniquenessId || '0000' || Environment.UniquenessId' + + + + 'CAST('effbca92070000effbca9207' AS BLOB)' + 'X'effbca92070000effbca9207'' + 'CAST(Environment.UniquenessId || '0000' || Environment.UniquenessId AS BLOB)' + + + + 'X'effbca92070000effbca9207' || X'effbca92070000effbca9207'' + 'X'effbca92070000effbca9207effbca92070000effbca9207'' + 'CAST(Environment.UniquenessId || '0000' || Environment.UniquenessId AS BLOB) || CAST(Environment.UniquenessId || '0000' || Environment.UniquenessId AS BLOB)' + + + + 'X'effbca92070000effbca9207effbca92070000effbca9207'' + 'Environment.payLoadGroupID' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '79.3' + 'SET Environment.metaDataGroupID = CAST(Environment.UniquenessId || '1111' || Environment.UniquenessId AS BLOB) || CAST(Environment.UniquenessId || '0000' || Environment.UniquenessId AS BLOB);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Environment.UniquenessId' + ''effbca9207'' + 'Environment.UniquenessId' + + + + ''effbca9207' || '1111'' + ''effbca92071111'' + 'Environment.UniquenessId || '1111'' + + + + 'Environment.UniquenessId' + ''effbca9207'' + 'Environment.UniquenessId' + + + + ''effbca92071111' || 'effbca9207'' + ''effbca92071111effbca9207'' + 'Environment.UniquenessId || '1111' || Environment.UniquenessId' + + + + 'CAST('effbca92071111effbca9207' AS BLOB)' + 'X'effbca92071111effbca9207'' + 'CAST(Environment.UniquenessId || '1111' || Environment.UniquenessId AS BLOB)' + + + + 'Environment.UniquenessId' + ''effbca9207'' + 'Environment.UniquenessId' + + + + ''effbca9207' || '0000'' + ''effbca92070000'' + 'Environment.UniquenessId || '0000'' + + + + 'Environment.UniquenessId' + ''effbca9207'' + 'Environment.UniquenessId' + + + + ''effbca92070000' || 'effbca9207'' + ''effbca92070000effbca9207'' + 'Environment.UniquenessId || '0000' || Environment.UniquenessId' + + + + 'CAST('effbca92070000effbca9207' AS BLOB)' + 'X'effbca92070000effbca9207'' + 'CAST(Environment.UniquenessId || '0000' || Environment.UniquenessId AS BLOB)' + + + + 'X'effbca92071111effbca9207' || X'effbca92070000effbca9207'' + 'X'effbca92071111effbca9207effbca92070000effbca9207'' + 'CAST(Environment.UniquenessId || '1111' || Environment.UniquenessId AS BLOB) || CAST(Environment.UniquenessId || '0000' || Environment.UniquenessId AS BLOB)' + + + + 'X'effbca92071111effbca9207effbca92070000effbca9207'' + 'Environment.metaDataGroupID' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '80.3' + 'SET Environment.messageType = 'payLoad';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''payLoad'' + 'Environment.messageType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '82.3' + 'SET AddTextValue = com.nb.mqmft.GetPropertyForSiteCode(Environment.cSiteCode, 'TextValue');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.mqmft.GetPropertyForSiteCode(Environment.cSiteCode, 'TextValue')' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Environment.cSiteCode' + ''NBEU'' + 'Environment.cSiteCode' + + + + 'com.nb.iib.util.SingleSiteCodeParmLookup.getTargetMFTDetails' + ''NBEU', 'TextValue'' + ''NBEU', 'TextValue'' + ''HTOI'' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '84.3' + 'SET OutputRoot.JSON.Data.shippingDetail.consumer.language = com.nb.esb.iib.cmn.ord.util.IsoLanguageCodeToUpsCode(InputRoot.JSON.Data.shippingDetail.consumer.language);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.IsoLanguageCodeToUpsCode(InputRoot.JSON.Data.shippingDetail.consumer.language)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputRoot.JSON.Data.shippingDetail.consumer.language' + ''eng'' + 'InputRoot.JSON.Data.shippingDetail.consumer.language' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.IsoLanguageCodeToUpsCode' + '3.3' + 'DECLARE upsCode CHARACTER;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.IsoLanguageCodeToUpsCode' + '4.3' + 'DECLARE CaseBool BOOLEAN TRUE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.IsoLanguageCodeToUpsCode' + '6.3' + 'CASE CaseBool WHEN isoCode = 'cze' THEN ... WHEN isoCode = 'ces' THEN ... WHEN isoCode = 'dut' THEN ... WHEN isoCode = 'nld' THEN ... WHEN isoCode = 'eng' THEN ... WHEN isoCode = 'fre' THEN ... WHEN isoCode = 'fra' THEN ... WHEN isoCode = 'ger' THEN ... WHEN isoCode = 'deu' THEN ... WHEN isoCode = 'hun' THEN ... WHEN isoCode = 'ita' THEN ... WHEN isoCode = 'pol' THEN ... WHEN isoCode = 'por' THEN ... WHEN isoCode = 'rum' THEN ... WHEN isoCode = 'ron' THEN ... WHEN isoCode = 'rus' THEN ... WHEN isoCode = 'spa' THEN ... WHEN isoCode = 'tur' THEN ... END CASE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'CaseBool' + 'TRUE' + 'CaseBool' + + + + 'isoCode' + ''eng'' + 'isoCode' + + + + ''eng' = 'cze'' + 'FALSE' + 'isoCode = 'cze'' + + + + 'isoCode' + ''eng'' + 'isoCode' + + + + ''eng' = 'ces'' + 'FALSE' + 'isoCode = 'ces'' + + + + 'isoCode' + ''eng'' + 'isoCode' + + + + ''eng' = 'dut'' + 'FALSE' + 'isoCode = 'dut'' + + + + 'isoCode' + ''eng'' + 'isoCode' + + + + ''eng' = 'nld'' + 'FALSE' + 'isoCode = 'nld'' + + + + 'isoCode' + ''eng'' + 'isoCode' + + + + ''eng' = 'eng'' + 'TRUE' + 'isoCode = 'eng'' + + + + 'com.nb.esb.iib.cmn.ord.util.IsoLanguageCodeToUpsCode' + '16.4' + 'SET upsCode = 'ENG';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.IsoLanguageCodeToUpsCode' + '44.3' + 'RETURN upsCode;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'upsCode' + ''ENG'' + 'upsCode' + + + + ''ENG'' + 'OutputRoot.JSON.Data.shippingDetail.consumer.language' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '86.3' + 'CALL com.nb.esb.iib.cmn.ord.util.additionalTextFiller(AddTextValue, OutputRoot.JSON.Data, Environment);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller(AddTextValue, OutputRoot.JSON.Data, Environment)' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'AddTextValue' + ''HTOI'' + 'AddTextValue' + + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '3.2' + 'DECLARE CodeValue CHARACTER;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '4.2' + 'DECLARE X INTEGER 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '5.2' + 'SET CodeValue = SUBSTRING(textValue FROM 1 FOR 2);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 1 FOR 2)' + ''HT'' + 'SUBSTRING(textValue FROM 1 FOR 2)' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '7.2' + 'IF CodeValue = 'HT' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'CodeValue' + ''HT'' + 'CodeValue' + + + + ''HT' = 'HT'' + 'TRUE' + 'CodeValue = 'HT'' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '8.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '1' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '9.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '1' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '10.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT01' || rOrder.salesOrderData.taxTotal || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.salesOrderData.taxTotal' + ''623'' + 'rOrder.salesOrderData.taxTotal' + + + + ''HT01' || '623'' + ''HT01623'' + ''HT01' || rOrder.salesOrderData.taxTotal' + + + + ''HT01623' || ' '' + ''HT01623 '' + ''HT01' || rOrder.salesOrderData.taxTotal || ' '' + + + + 'X' + '1' + 'X' + + + + ''HT01623 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '11.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '1' + 'X' + + + + '1 + 1' + '2' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '12.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '2' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '13.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '2' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '14.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT02' || rOrder.salesOrderData.discountCode || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.salesOrderData.discountCode' + '' '' + 'rOrder.salesOrderData.discountCode' + + + + ''HT02' || ' '' + ''HT02 '' + ''HT02' || rOrder.salesOrderData.discountCode' + + + + ''HT02 ' || ' '' + ''HT02 '' + ''HT02' || rOrder.salesOrderData.discountCode || ' '' + + + + 'X' + '2' + 'X' + + + + ''HT02 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '15.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '2' + 'X' + + + + '2 + 1' + '3' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '16.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '3' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '17.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '3' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '18.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT03' || rOrder.salesOrderData.discountTotal || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.salesOrderData.discountTotal' + '' '' + 'rOrder.salesOrderData.discountTotal' + + + + ''HT03' || ' '' + ''HT03 '' + ''HT03' || rOrder.salesOrderData.discountTotal' + + + + ''HT03 ' || ' '' + ''HT03 '' + ''HT03' || rOrder.salesOrderData.discountTotal || ' '' + + + + 'X' + '3' + 'X' + + + + ''HT03 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '19.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '3' + 'X' + + + + '3 + 1' + '4' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '20.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '4' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '21.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '4' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '22.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT04' || rOrder.shippingDetail.shipCode || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 3 + + + + 'rOrder.shippingDetail.shipCode' + 'NULL' + 'rOrder.shippingDetail.shipCode' + + + + ''HT04' || NULL' + 'NULL' + ''HT04' || rOrder.shippingDetail.shipCode' + + + + 'NULL || ' '' + 'NULL' + ''HT04' || rOrder.shippingDetail.shipCode || ' '' + + + + 'X' + '4' + 'X' + + + + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '23.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '4' + 'X' + + + + '4 + 1' + '5' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '24.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '5' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '25.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '5' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '26.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT05' || rOrder.salesOrderData.freightCost || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.salesOrderData.freightCost' + ''500'' + 'rOrder.salesOrderData.freightCost' + + + + ''HT05' || '500'' + ''HT05500'' + ''HT05' || rOrder.salesOrderData.freightCost' + + + + ''HT05500' || ' '' + ''HT05500 '' + ''HT05' || rOrder.salesOrderData.freightCost || ' '' + + + + 'X' + '5' + 'X' + + + + ''HT05500 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '27.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '5' + 'X' + + + + '5 + 1' + '6' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '28.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '6' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '29.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '6' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '30.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT06' || rOrder.itemList.products.Item[1].warehouse || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.itemList.products.Item[1].warehouse' + ''UW'' + 'rOrder.itemList.products.Item[1].warehouse' + + + + ''HT06' || 'UW'' + ''HT06UW'' + ''HT06' || rOrder.itemList.products.Item[1].warehouse' + + + + ''HT06UW' || ' '' + ''HT06UW '' + ''HT06' || rOrder.itemList.products.Item[1].warehouse || ' '' + + + + 'X' + '6' + 'X' + + + + ''HT06UW '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '31.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '6' + 'X' + + + + '6 + 1' + '7' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '32.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '7' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '33.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '7' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '34.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT07' || rOrder.shippingDetail.address.phone1 || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.address.phone1' + ''+43 9999999999'' + 'rOrder.shippingDetail.address.phone1' + + + + ''HT07' || '+43 9999999999'' + ''HT07+43 9999999999'' + ''HT07' || rOrder.shippingDetail.address.phone1' + + + + ''HT07+43 9999999999' || ' '' + ''HT07+43 9999999999 '' + ''HT07' || rOrder.shippingDetail.address.phone1 || ' '' + + + + 'X' + '7' + 'X' + + + + ''HT07+43 9999999999 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '35.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '7' + 'X' + + + + '7 + 1' + '8' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '36.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '8' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '37.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '8' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '38.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT08' || rOrder.shippingDetail.address.email || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.address.email' + ''Test@Email.com'' + 'rOrder.shippingDetail.address.email' + + + + ''HT08' || 'Test@Email.com'' + ''HT08Test@Email.com'' + ''HT08' || rOrder.shippingDetail.address.email' + + + + ''HT08Test@Email.com' || ' '' + ''HT08Test@Email.com '' + ''HT08' || rOrder.shippingDetail.address.email || ' '' + + + + 'X' + '8' + 'X' + + + + ''HT08Test@Email.com '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '39.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '8' + 'X' + + + + '8 + 1' + '9' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '40.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '9' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '41.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '9' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '42.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT09' || rOrder.shippingDetail.address.phone1CountryCode || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.address.phone1CountryCode' + '' '' + 'rOrder.shippingDetail.address.phone1CountryCode' + + + + ''HT09' || ' '' + ''HT09 '' + ''HT09' || rOrder.shippingDetail.address.phone1CountryCode' + + + + ''HT09 ' || ' '' + ''HT09 '' + ''HT09' || rOrder.shippingDetail.address.phone1CountryCode || ' '' + + + + 'X' + '9' + 'X' + + + + ''HT09 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '43.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '9' + 'X' + + + + '9 + 1' + '10' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '44.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '10' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '45.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '10' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '46.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT10' || rOrder.shippingDetail.carrierAccessPoint || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.carrierAccessPoint' + '' '' + 'rOrder.shippingDetail.carrierAccessPoint' + + + + ''HT10' || ' '' + ''HT10 '' + ''HT10' || rOrder.shippingDetail.carrierAccessPoint' + + + + ''HT10 ' || ' '' + ''HT10 '' + ''HT10' || rOrder.shippingDetail.carrierAccessPoint || ' '' + + + + 'X' + '10' + 'X' + + + + ''HT10 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '47.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '10' + 'X' + + + + '10 + 1' + '11' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '48.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '11' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '49.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '11' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '50.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT11' || rOrder.shippingDetail.packingSlip.Item[1].upsService || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.packingSlip.Item[1].upsService' + ''UPS_Standard_DE'' + 'rOrder.shippingDetail.packingSlip.Item[1].upsService' + + + + ''HT11' || 'UPS_Standard_DE'' + ''HT11UPS_Standard_DE'' + ''HT11' || rOrder.shippingDetail.packingSlip.Item[1].upsService' + + + + ''HT11UPS_Standard_DE' || ' '' + ''HT11UPS_Standard_DE '' + ''HT11' || rOrder.shippingDetail.packingSlip.Item[1].upsService || ' '' + + + + 'X' + '11' + 'X' + + + + ''HT11UPS_Standard_DE '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '51.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '11' + 'X' + + + + '11 + 1' + '12' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '52.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '12' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '53.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '12' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '54.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT12' || rOrder.shippingDetail.consumer.language || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.consumer.language' + ''ENG'' + 'rOrder.shippingDetail.consumer.language' + + + + ''HT12' || 'ENG'' + ''HT12ENG'' + ''HT12' || rOrder.shippingDetail.consumer.language' + + + + ''HT12ENG' || ' '' + ''HT12ENG '' + ''HT12' || rOrder.shippingDetail.consumer.language || ' '' + + + + 'X' + '12' + 'X' + + + + ''HT12ENG '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '55.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '12' + 'X' + + + + '12 + 1' + '13' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '56.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '13' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '57.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '13' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '58.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT13' || rOrder.shippingDetail.consumer.billToAddress.businessName || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.consumer.billToAddress.businessName' + ''Germany JLD'' + 'rOrder.shippingDetail.consumer.billToAddress.businessName' + + + + ''HT13' || 'Germany JLD'' + ''HT13Germany JLD'' + ''HT13' || rOrder.shippingDetail.consumer.billToAddress.businessName' + + + + ''HT13Germany JLD' || ' '' + ''HT13Germany JLD '' + ''HT13' || rOrder.shippingDetail.consumer.billToAddress.businessName || ' '' + + + + 'X' + '13' + 'X' + + + + ''HT13Germany JLD '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '59.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '13' + 'X' + + + + '13 + 1' + '14' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '60.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '14' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '61.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '14' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '62.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT14' || rOrder.shippingDetail.consumer.billToAddress.postalCode || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.consumer.billToAddress.postalCode' + ''10785'' + 'rOrder.shippingDetail.consumer.billToAddress.postalCode' + + + + ''HT14' || '10785'' + ''HT1410785'' + ''HT14' || rOrder.shippingDetail.consumer.billToAddress.postalCode' + + + + ''HT1410785' || ' '' + ''HT1410785 '' + ''HT14' || rOrder.shippingDetail.consumer.billToAddress.postalCode || ' '' + + + + 'X' + '14' + 'X' + + + + ''HT1410785 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '63.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '14' + 'X' + + + + '14 + 1' + '15' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '64.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '15' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '65.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '15' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '66.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT15' || rOrder.shippingDetail.consumer.billToAddress.address1 || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.consumer.billToAddress.address1' + ''Veveří 2215/123'' + 'rOrder.shippingDetail.consumer.billToAddress.address1' + + + + ''HT15' || 'Veveří 2215/123'' + ''HT15Veveří 2215/123'' + ''HT15' || rOrder.shippingDetail.consumer.billToAddress.address1' + + + + ''HT15Veveří 2215/123' || ' '' + ''HT15Veveří 2215/123 '' + ''HT15' || rOrder.shippingDetail.consumer.billToAddress.address1 || ' '' + + + + 'X' + '15' + 'X' + + + + ''HT15Veveří 2215/123 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '67.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '15' + 'X' + + + + '15 + 1' + '16' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '68.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '16' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '69.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '16' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '70.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT16' || rOrder.shippingDetail.consumer.billToAddress.address2 || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.consumer.billToAddress.address2' + ''Brno-Žabovřesky'' + 'rOrder.shippingDetail.consumer.billToAddress.address2' + + + + ''HT16' || 'Brno-Žabovřesky'' + ''HT16Brno-Žabovřesky'' + ''HT16' || rOrder.shippingDetail.consumer.billToAddress.address2' + + + + ''HT16Brno-Žabovřesky' || ' '' + ''HT16Brno-Žabovřesky '' + ''HT16' || rOrder.shippingDetail.consumer.billToAddress.address2 || ' '' + + + + 'X' + '16' + 'X' + + + + ''HT16Brno-Žabovřesky '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '71.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '16' + 'X' + + + + '16 + 1' + '17' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '72.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '17' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '73.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '17' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '74.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT17' || rOrder.shippingDetail.consumer.billToAddress.country || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.consumer.billToAddress.country' + ''DE'' + 'rOrder.shippingDetail.consumer.billToAddress.country' + + + + ''HT17' || 'DE'' + ''HT17DE'' + ''HT17' || rOrder.shippingDetail.consumer.billToAddress.country' + + + + ''HT17DE' || ' '' + ''HT17DE '' + ''HT17' || rOrder.shippingDetail.consumer.billToAddress.country || ' '' + + + + 'X' + '17' + 'X' + + + + ''HT17DE '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '75.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '17' + 'X' + + + + '17 + 1' + '18' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '76.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '18' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '77.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '18' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '78.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT18' || rOrder.shippingDetail.consumer.billToAddress.city || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.consumer.billToAddress.city' + ''Berlin'' + 'rOrder.shippingDetail.consumer.billToAddress.city' + + + + ''HT18' || 'Berlin'' + ''HT18Berlin'' + ''HT18' || rOrder.shippingDetail.consumer.billToAddress.city' + + + + ''HT18Berlin' || ' '' + ''HT18Berlin '' + ''HT18' || rOrder.shippingDetail.consumer.billToAddress.city || ' '' + + + + 'X' + '18' + 'X' + + + + ''HT18Berlin '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '79.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '18' + 'X' + + + + '18 + 1' + '19' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '80.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '19' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '81.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '19' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '82.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT19' || rOrder.shippingDetail.consumer.billToAddress.businessName || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.consumer.billToAddress.businessName' + ''Germany JLD'' + 'rOrder.shippingDetail.consumer.billToAddress.businessName' + + + + ''HT19' || 'Germany JLD'' + ''HT19Germany JLD'' + ''HT19' || rOrder.shippingDetail.consumer.billToAddress.businessName' + + + + ''HT19Germany JLD' || ' '' + ''HT19Germany JLD '' + ''HT19' || rOrder.shippingDetail.consumer.billToAddress.businessName || ' '' + + + + 'X' + '19' + 'X' + + + + ''HT19Germany JLD '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '83.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '19' + 'X' + + + + '19 + 1' + '20' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '84.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '20' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '85.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '20' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '86.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT20' || rOrder.shippingDetail.consumer.billToAddress.phone1 || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'rOrder.shippingDetail.consumer.billToAddress.phone1' + ''+43 9999999999'' + 'rOrder.shippingDetail.consumer.billToAddress.phone1' + + + + ''HT20' || '+43 9999999999'' + ''HT20+43 9999999999'' + ''HT20' || rOrder.shippingDetail.consumer.billToAddress.phone1' + + + + ''HT20+43 9999999999' || ' '' + ''HT20+43 9999999999 '' + ''HT20' || rOrder.shippingDetail.consumer.billToAddress.phone1 || ' '' + + + + 'X' + '20' + 'X' + + + + ''HT20+43 9999999999 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '87.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '20' + 'X' + + + + '20 + 1' + '21' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '88.3' + 'SET Environment.Variables.rAdditionalText[X].TextType = SUBSTRING(textValue FROM 3 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 3 FOR 1)' + ''O'' + 'SUBSTRING(textValue FROM 3 FOR 1)' + + + + 'X' + '21' + 'X' + + + + ''O'' + 'Environment.Variables.rAdditionalText[X].TextType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '89.3' + 'SET Environment.Variables.rAdditionalText[X].UsageCode = SUBSTRING(textValue FROM 4 FOR 1);' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + 'SUBSTRING('HTOI' FROM 4 FOR 1)' + ''I'' + 'SUBSTRING(textValue FROM 4 FOR 1)' + + + + 'X' + '21' + 'X' + + + + ''I'' + 'Environment.Variables.rAdditionalText[X].UsageCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '90.3' + 'SET Environment.Variables.rAdditionalText[X].text = 'HT21' || ' ';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''HT21' || ' '' + ''HT21 '' + ''HT21' || ' '' + + + + 'X' + '21' + 'X' + + + + ''HT21 '' + 'Environment.Variables.rAdditionalText[X].text' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '91.3' + 'SET X = X + 1;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'X' + '21' + 'X' + + + + '21 + 1' + '22' + 'X + 1' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '94.2' + 'IF textValue = 'PS' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + ''HTOI' = 'PS'' + 'FALSE' + 'textValue = 'PS'' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '109.2' + 'IF textValue = 'DT' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + ''HTOI' = 'DT'' + 'FALSE' + 'textValue = 'DT'' + + + + 'com.nb.esb.iib.cmn.ord.util.additionalTextFiller' + '145.2' + 'IF textValue = ' ' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'textValue' + ''HTOI'' + 'textValue' + + + + ''HTOI' = ' '' + 'FALSE' + 'textValue = ' '' + + + + '.post_FullFillmentReq_Route_Compute.Main' + '89.3' + 'SET Environment.Variables.ProcessDate = convertDate();' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'convertDate()' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.convertDate' + '3.2' + 'RETURN CAST(CURRENT_DATE AS CHARACTER FORMAT 'YYYYMMdd');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'DATE '2019-11-21'' + 'CURRENT_DATE' + + + + 'CAST(DATE '2019-11-21' AS CHARACTER FORMAT 'YYYYMMdd' )' + ''20191121'' + 'CAST(CURRENT_DATE AS CHARACTER FORMAT 'YYYYMMdd')' + + + + ''20191121'' + 'Environment.Variables.ProcessDate' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '90.3' + 'SET Environment.Variables.ProcessTime = convertTime();' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'convertTime()' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.convertTime' + '3.2' + 'RETURN CAST(CURRENT_TIME AS CHARACTER FORMAT 'HHMMSSsss');' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'TIME '13:23:07.737752'' + 'CURRENT_TIME' + + + + 'CAST(TIME '13:23:07.737752' AS CHARACTER FORMAT 'HHMMSSsss' )' + ''130173007'' + 'CAST(CURRENT_TIME AS CHARACTER FORMAT 'HHMMSSsss')' + + + + ''130173007'' + 'Environment.Variables.ProcessTime' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '92.3' + 'PROPAGATE TO TERMINAL 'out2' FINALIZE DEFAULT DELETE DEFAULT;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''out2'' + 'OutputLocalEnvironment, OutputRoot, InputExceptionList' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.InTerminal.Input + + + 'com.nb.mqmft.xsi' + '1.1' + 'DECLARE xsi SHARED NAMESPACE 'http://www.w3.org/2001/XMLSchema-instance';' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_SERVER_NAME' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_SERVER_NAME EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_FROM_ADDR' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_FROM_ADDR EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_SUBJECT' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_SUBJECT EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_REPLYTO' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_REPLYTO EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_ATTCH_FILENAME' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_ATTCH_FILENAME EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_FLAG' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_FLAG EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.mqmft.SiteCodeValdationRoutine_Compute.Main' + '4.3' + 'CALL CopyEntireMessage();' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'CopyEntireMessage()' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.mqmft.SiteCodeValdationRoutine_Compute.CopyEntireMessage' + '2.3' + 'SET OutputRoot = InputRoot;' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'InputRoot' + 'ROW... Root Element Type=16777216 NameSpace='' Name='Root' Value=NULL' + 'InputRoot' + + + + 'InputRoot' + 'OutputRoot' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.mqmft.SiteCodeValdationRoutine_Compute.Main' + '6.3' + 'IF Environment.cSiteCode IS NULL OR Environment.cSiteCode = ' ' THEN... ELSE... END IF;' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'Environment.cSiteCode' + ''NBEU'' + 'Environment.cSiteCode' + + + + 'FALSE' + 'Environment.cSiteCode IS NULL' + + + + 'Environment.cSiteCode' + 'ROW... Root Element Type=50331648 NameSpace='' Name='cSiteCode' Value='NBEU'' + 'Environment.cSiteCode' + + + + 'ROW... Root Element Type=50331648 NameSpace='' Name='cSiteCode' Value='NBEU' = ' '' + 'FALSE' + 'Environment.cSiteCode = ' '' + + + + 'FALSE OR FALSE' + 'FALSE' + 'Environment.cSiteCode IS NULL OR Environment.cSiteCode = ' '' + + + + 'com.nb.mqmft.SiteCodeValdationRoutine_Compute.Main' + '9.4' + 'CALL getSiteCodeProperties(Environment.cSiteCode, Environment.MFT.AgentName, Environment.MFT.Destination, Environment.MFT.IIBLocalQMGR, Environment.MFT.SourceQueue, Environment.MFT.ShellProgram, Environment.MFT.queueMGR, Environment.MFT.ReplyToQueue);' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'getSiteCodeProperties(Environment.cSiteCode, Environment.MFT.AgentName, Environment.MFT.Destination, Environment.MFT.IIBLocalQMGR, Environment.MFT.SourceQueue, Environment.MFT.ShellProgram, Environment.MFT.queueMGR, Environment.MFT.ReplyToQueue)' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'Environment.cSiteCode' + ''NBEU'' + 'Environment.cSiteCode' + + + + 'com.nb.iib.util.SiteCodeParameterLookup.getSiteCodeParameters' + ''NBEU', NULL, NULL, NULL, NULL, NULL, NULL, NULL' + ''NBEU', 'ERPQUAEUAGNT1', '/Inbound/Orders', '', 'SFDC.NB.ORDER.REQ', 'erpquaeu.sh', 'MWGWSTGQM', ''' + 'void' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'com.nb.mqmft.SiteCodeValdationRoutine_Compute.Main' + '28.3' + 'RETURN TRUE;' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + 'InputLocalEnvironment, OutputRoot, InputExceptionList' + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.Sitecode_Valdation_Compute + + + gen.fulfillment_request_3.post (Implementation).SiteCodeValdationRoutine.OutTerminal.Output + + + 'ComIbmMSLMappingNode' + 'gen/fulfillment_request_3#FCMComposite_1_8.post#FCMComposite_1_1' + 'post (Implementation).TDF 850 Mapping' + gen.fulfillment_request_3.post (Implementation).TDF 850 Mapping + + + 'ComIbmMQHeaderNode' + 'gen/fulfillment_request_3#FCMComposite_1_8.post#FCMComposite_1_5' + 'post (Implementation).MQ Header' + gen.fulfillment_request_3.post (Implementation).MQ Header + + + '.token_API_URL' + '1.1' + 'DECLARE token_API_URL EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.token_Authorization' + '1.1' + 'DECLARE token_Authorization EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.API_ClientId' + '1.1' + 'DECLARE API_ClientId EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.REPLY_TO_QUEUE' + '1.1' + 'DECLARE REPLY_TO_QUEUE EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.COMP_CODES_API_URL' + '1.1' + 'DECLARE COMP_CODES_API_URL EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_SERVER_NAME' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_SERVER_NAME EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_FROM_ADDR' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_FROM_ADDR EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_SUBJECT' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_SUBJECT EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_REPLYTO' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_REPLYTO EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_ATTCH_FILENAME' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_ATTCH_FILENAME EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_FLAG' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_FLAG EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'com.nb.mqmft.xsi' + '1.1' + 'DECLARE xsi SHARED NAMESPACE 'http://www.w3.org/2001/XMLSchema-instance';' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '3.3' + 'CALL CopyEntireMessage();' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'CopyEntireMessage()' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.CopyEntireMessage' + '2.3' + 'SET OutputRoot = InputRoot;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'InputRoot' + 'ROW... Root Element Type=16777216 NameSpace='' Name='Root' Value=NULL' + 'InputRoot' + + + + 'InputRoot' + 'OutputRoot' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '4.3' + 'SET OutputRoot.HTTPInputHeader = NULL;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'OutputRoot.HTTPInputHeader' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '5.3' + 'DECLARE rMQMDRef REFERENCE TO OutputRoot.MQMD;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '6.3' + 'IF Environment.messageType = 'payLoad' THEN... ELSE... END IF;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'Environment.messageType' + 'ROW... Root Element Type=50331648 NameSpace='' Name='messageType' Value='payLoad'' + 'Environment.messageType' + + + + 'ROW... Root Element Type=50331648 NameSpace='' Name='messageType' Value='payLoad' = 'payLoad'' + 'TRUE' + 'Environment.messageType = 'payLoad'' + + + + '.post_ConstructMQMDHeaders_Compute.Main' + '7.4' + 'SET rMQMDRef.GroupId = Environment.payLoadGroupID;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'Environment.payLoadGroupID' + 'ROW... Root Element Type=50331648 NameSpace='' Name='payLoadGroupID' Value=X'effbca92070000effbca9207effbca92070000effbca9207'' + 'Environment.payLoadGroupID' + + + + 'Environment.payLoadGroupID' + 'rMQMDRef.GroupId' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '8.4' + 'SET OutputRoot.DFDL.EDIFormat.SiteIDRecord.SiteCode = Environment.cSiteCode;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'Environment.cSiteCode' + 'ROW... Root Element Type=50331648 NameSpace='' Name='cSiteCode' Value='NBEU'' + 'Environment.cSiteCode' + + + + 'Environment.cSiteCode' + 'OutputRoot.DFDL.EDIFormat.SiteIDRecord.SiteCode' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '13.9' + 'SET rMQMDRef.MsgSeqNumber = 1;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '1' + 'rMQMDRef.MsgSeqNumber' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '14.9' + 'SET rMQMDRef.MsgFlags = MQMF_MSG_IN_GROUP;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'MQMF_MSG_IN_GROUP' + '8' + 'MQMF_MSG_IN_GROUP' + + + + '8' + 'rMQMDRef.MsgFlags' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '15.6' + 'SET rMQMDRef.MsgFlags = MQMF_LAST_MSG_IN_GROUP;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'MQMF_LAST_MSG_IN_GROUP' + '16' + 'MQMF_LAST_MSG_IN_GROUP' + + + + '16' + 'rMQMDRef.MsgFlags' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '16.3' + 'RETURN TRUE;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'InputLocalEnvironment, OutputRoot, InputExceptionList' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'gen.fulfillment_request_3.post (Implementation).SFDC.NB.ORDER.REQ_MQOutput' + '' + 'connection: SERVER, destinationQueueManagerName: IIBQMSTGNB1, logLabel: gen.fulfillment_request_3.post (Implementation).SFDC.NB.ORDER.REQ_MQOutput' + gen.fulfillment_request_3.post (Implementation).SFDC.NB.ORDER.REQ_MQOutput + + + '.post_FullFillmentReq_Route_Compute.Main' + '94.3' + 'SET OutputRoot.MQMD.GroupId = Environment.UniquenessId;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'Environment.UniquenessId' + 'ROW... Root Element Type=50331648 NameSpace='' Name='UniquenessId' Value='effbca9207'' + 'Environment.UniquenessId' + + + + 'Environment.UniquenessId' + 'OutputRoot.MQMD.GroupId' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '97.3' + 'SET OutputRoot.DFDL.MetaCSV.metaData.siteCode = cSiteCode;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + ''NBEU'' + 'OutputRoot.DFDL.MetaCSV.metaData.siteCode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '99.3' + 'SET OutputRoot.DFDL.MetaCSV.metaData.id = 'id';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''id'' + 'OutputRoot.DFDL.MetaCSV.metaData.id' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '100.3' + 'SET OutputRoot.DFDL.MetaCSV.metaData.requestType = 'POSTSALESORDER';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''POSTSALESORDER'' + 'OutputRoot.DFDL.MetaCSV.metaData.requestType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '101.3' + 'SET OutputRoot.DFDL.MetaCSV.metaData.replyToQueue = REPLY_TO_QUEUE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'REPLY_TO_QUEUE' + ''SFDC.NB.ORDER.RES'' + 'REPLY_TO_QUEUE' + + + + ''SFDC.NB.ORDER.RES'' + 'OutputRoot.DFDL.MetaCSV.metaData.replyToQueue' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '102.3' + 'SET OutputRoot.DFDL.MetaCSV.metaData.replyToQMGR = QueueManagerName;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'QueueManagerName' + ''IIBQMSTGNB1'' + 'QueueManagerName' + + + + ''IIBQMSTGNB1'' + 'OutputRoot.DFDL.MetaCSV.metaData.replyToQMGR' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '103.3' + 'SET OutputRoot.DFDL.MetaCSV.metaData.sessionID = InputLocalEnvironment.Destination.HTTP.RequestIdentifier;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'InputLocalEnvironment.Destination.HTTP.RequestIdentifier' + 'ROW... Root Element Type=50331648 NameSpace='' Name='RequestIdentifier' Value=X'485454500000000000000000d81d348f4822000000000000'' + 'InputLocalEnvironment.Destination.HTTP.RequestIdentifier' + + + + 'InputLocalEnvironment.Destination.HTTP.RequestIdentifier' + 'OutputRoot.DFDL.MetaCSV.metaData.sessionID' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '104.3' + 'SET Environment.messageType = 'metaData';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''metaData'' + 'Environment.messageType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '106.3' + 'PROPAGATE TO TERMINAL 'out3' FINALIZE DEFAULT DELETE DEFAULT;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''out3'' + 'OutputLocalEnvironment, OutputRoot, InputExceptionList' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'ComIbmMQHeaderNode' + 'gen/fulfillment_request_3#FCMComposite_1_8.post#FCMComposite_1_5' + 'post (Implementation).MQ Header' + gen.fulfillment_request_3.post (Implementation).MQ Header + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '3.3' + 'CALL CopyEntireMessage();' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'CopyEntireMessage()' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.CopyEntireMessage' + '2.3' + 'SET OutputRoot = InputRoot;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'InputRoot' + 'ROW... Root Element Type=16777216 NameSpace='' Name='Root' Value=NULL' + 'InputRoot' + + + + 'InputRoot' + 'OutputRoot' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '4.3' + 'SET OutputRoot.HTTPInputHeader = NULL;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'OutputRoot.HTTPInputHeader' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '5.3' + 'DECLARE rMQMDRef REFERENCE TO OutputRoot.MQMD;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '6.3' + 'IF Environment.messageType = 'payLoad' THEN... ELSE... END IF;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'Environment.messageType' + 'ROW... Root Element Type=50331648 NameSpace='' Name='messageType' Value='metaData'' + 'Environment.messageType' + + + + 'ROW... Root Element Type=50331648 NameSpace='' Name='messageType' Value='metaData' = 'payLoad'' + 'FALSE' + 'Environment.messageType = 'payLoad'' + + + + '.post_ConstructMQMDHeaders_Compute.Main' + '10.4' + 'SET rMQMDRef.GroupId = Environment.metaDataGroupID;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'Environment.metaDataGroupID' + 'ROW... Root Element Type=50331648 NameSpace='' Name='metaDataGroupID' Value=X'effbca92071111effbca9207effbca92070000effbca9207'' + 'Environment.metaDataGroupID' + + + + 'Environment.metaDataGroupID' + 'rMQMDRef.GroupId' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '13.9' + 'SET rMQMDRef.MsgSeqNumber = 1;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '1' + 'rMQMDRef.MsgSeqNumber' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '14.9' + 'SET rMQMDRef.MsgFlags = MQMF_MSG_IN_GROUP;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'MQMF_MSG_IN_GROUP' + '8' + 'MQMF_MSG_IN_GROUP' + + + + '8' + 'rMQMDRef.MsgFlags' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '15.6' + 'SET rMQMDRef.MsgFlags = MQMF_LAST_MSG_IN_GROUP;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'MQMF_LAST_MSG_IN_GROUP' + '16' + 'MQMF_LAST_MSG_IN_GROUP' + + + + '16' + 'rMQMDRef.MsgFlags' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + '.post_ConstructMQMDHeaders_Compute.Main' + '16.3' + 'RETURN TRUE;' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'InputLocalEnvironment, OutputRoot, InputExceptionList' + gen.fulfillment_request_3.post (Implementation).MapGroupID_Compute + + + 'gen.fulfillment_request_3.post (Implementation).SFDC.NB.ORDER.REQ_MQOutput' + '' + 'connection: SERVER, destinationQueueManagerName: IIBQMSTGNB1, logLabel: gen.fulfillment_request_3.post (Implementation).SFDC.NB.ORDER.REQ_MQOutput' + gen.fulfillment_request_3.post (Implementation).SFDC.NB.ORDER.REQ_MQOutput + + + '.post_FullFillmentReq_Route_Compute.Main' + '109.3' + 'SET Environment.Variables.metadata.sitecode = cSiteCode;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cSiteCode' + ''NBEU'' + 'cSiteCode' + + + + ''NBEU'' + 'Environment.Variables.metadata.sitecode' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '110.3' + 'SET Environment.Variables.metadata.ordernumber = cOrderNumber;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cOrderNumber' + ''E300179204-15'' + 'cOrderNumber' + + + + ''E300179204-15'' + 'Environment.Variables.metadata.ordernumber' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '112.3' + 'SET Environment.Variables.metadata.id = 'id';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''id'' + 'Environment.Variables.metadata.id' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '113.3' + 'SET Environment.Variables.metadata.requesttype = 'POSTSALESORDER';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''POSTSALESORDER'' + 'Environment.Variables.metadata.requesttype' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '114.3' + 'SET Environment.Variables.metadata.metaDataFileName = cPayloadPrefix || Environment.UniquenessId || '.metadata';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cPayloadPrefix' + ''NBEU'' + 'cPayloadPrefix' + + + + 'Environment.UniquenessId' + ''effbca9207'' + 'Environment.UniquenessId' + + + + ''NBEU' || 'effbca9207'' + ''NBEUeffbca9207'' + 'cPayloadPrefix || Environment.UniquenessId' + + + + ''NBEUeffbca9207' || '.metadata'' + ''NBEUeffbca9207.metadata'' + 'cPayloadPrefix || Environment.UniquenessId || '.metadata'' + + + + ''NBEUeffbca9207.metadata'' + 'Environment.Variables.metadata.metaDataFileName' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '115.3' + 'SET Environment.Variables.metadata.payLoadFileName = cPayloadPrefix || '_' || InputRoot.JSON.Data.consumerPurchaseOrderNumber || '.850';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'cPayloadPrefix' + ''NBEU'' + 'cPayloadPrefix' + + + + ''NBEU' || '_'' + ''NBEU_'' + 'cPayloadPrefix || '_'' + + + + 'InputRoot.JSON.Data.consumerPurchaseOrderNumber' + ''E300179204-15'' + 'InputRoot.JSON.Data.consumerPurchaseOrderNumber' + + + + ''NBEU_' || 'E300179204-15'' + ''NBEU_E300179204-15'' + 'cPayloadPrefix || '_' || InputRoot.JSON.Data.consumerPurchaseOrderNumber' + + + + ''NBEU_E300179204-15' || '.850'' + ''NBEU_E300179204-15.850'' + 'cPayloadPrefix || '_' || InputRoot.JSON.Data.consumerPurchaseOrderNumber || '.850'' + + + + ''NBEU_E300179204-15.850'' + 'Environment.Variables.metadata.payLoadFileName' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '117.3' + 'SET Environment.messageType = 'payLoad';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''payLoad'' + 'Environment.messageType' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '118.3' + 'PROPAGATE TO TERMINAL 'out4' FINALIZE DEFAULT DELETE NONE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''out4'' + 'OutputLocalEnvironment, OutputRoot, InputExceptionList' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.InTerminal.Input + + + 'com.nb.mqmft.xsi' + '1.1' + 'DECLARE xsi SHARED NAMESPACE 'http://www.w3.org/2001/XMLSchema-instance';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_SERVER_NAME' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_SERVER_NAME EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_FROM_ADDR' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_FROM_ADDR EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_SUBJECT' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_SUBJECT EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_REPLYTO' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_REPLYTO EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_ATTCH_FILENAME' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_ATTCH_FILENAME EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.esb.iib.cmn.util.UDP_SMTP_EMAIL_FLAG' + '1.1' + 'DECLARE UDP_SMTP_EMAIL_FLAG EXTERNAL CHARACTER '';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '4.3' + 'CALL CopyEntireMessage();' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'CopyEntireMessage()' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'BEGIN ... END;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.CopyEntireMessage' + '2.3' + 'SET OutputRoot = InputRoot;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'InputRoot' + 'ROW... Root Element Type=16777216 NameSpace='' Name='Root' Value=NULL' + 'InputRoot' + + + + 'InputRoot' + 'OutputRoot' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '6.3' + 'DECLARE rOutRef, rOutReqRef, rManagedTransferRef, rOriginatorRef, rSourceAgentRef, rPostDestCallRef, rFileRef, rDestinationAgentRef, rTransferSetRef, rTransferSetItemRef, rCommandRef, rJobRef, rMetadataSetRef, rReplyRef, rMetadataRef REFERENCE TO OutputRoot;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '10.3' + 'DECLARE cAgentName, cShellProgram, cSourceQueue, cQueueMGR, cDestination, cIIBLocalQMGR CHARACTER;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '11.3' + 'DECLARE cSiteCode CHARACTER Environment.cSiteCode;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.cSiteCode' + ''NBEU'' + 'Environment.cSiteCode' + + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '13.3' + 'SET cAgentName = Environment.MFT.AgentName;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.MFT.AgentName' + ''ERPQUAEUAGNT1'' + 'Environment.MFT.AgentName' + + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '14.3' + 'SET cSourceQueue = Environment.MFT.SourceQueue;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.MFT.SourceQueue' + ''SFDC.NB.ORDER.REQ'' + 'Environment.MFT.SourceQueue' + + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '15.3' + 'SET cQueueMGR = Environment.MFT.queueMGR;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.MFT.queueMGR' + ''MWGWSTGQM'' + 'Environment.MFT.queueMGR' + + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '16.3' + 'SET cIIBLocalQMGR = Environment.MFT.IIBLocalQMGR;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.MFT.IIBLocalQMGR' + '''' + 'Environment.MFT.IIBLocalQMGR' + + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '17.3' + 'SET cDestination = Environment.MFT.Destination;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.MFT.Destination' + ''/Inbound/Orders'' + 'Environment.MFT.Destination' + + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '18.3' + 'SET cShellProgram = Environment.MFT.ShellProgram;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.MFT.ShellProgram' + ''erpquaeu.sh'' + 'Environment.MFT.ShellProgram' + + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '19.3' + 'DELETE FIELD OutputRoot;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '22.3' + 'IF cAgentName = 'SiteCodeNotConfigured' OR cShellProgram = 'SiteCodeNotConfigured' THEN... END IF;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cAgentName' + ''ERPQUAEUAGNT1'' + 'cAgentName' + + + + ''ERPQUAEUAGNT1' = 'SiteCodeNotConfigured'' + 'FALSE' + 'cAgentName = 'SiteCodeNotConfigured'' + + + + 'cShellProgram' + ''erpquaeu.sh'' + 'cShellProgram' + + + + ''erpquaeu.sh' = 'SiteCodeNotConfigured'' + 'FALSE' + 'cShellProgram = 'SiteCodeNotConfigured'' + + + + 'FALSE OR FALSE' + 'FALSE' + 'cAgentName = 'SiteCodeNotConfigured' OR cShellProgram = 'SiteCodeNotConfigured'' + + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '27.3' + 'CREATE LASTCHILD OF rOutRef AS rOutRef DOMAIN 'XMLNSC' NAMESPACE '' NAME 'XMLNSC';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '28.9' + 'SET rOutRef.(XMLNSC.XmlDeclaration)*:*.(XMLNSC.Attribute)Version = '1.0';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.XmlDeclaration' + '16778240' + 'XMLNSC.XmlDeclaration' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''1.0'' + 'rOutRef.(XMLNSC.XmlDeclaration)*:*.(XMLNSC.Attribute)Version' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '29.9' + 'SET rOutRef.(XMLNSC.XmlDeclaration)*:*.(XMLNSC.Attribute)Encoding = 'UTF-8';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.XmlDeclaration' + '16778240' + 'XMLNSC.XmlDeclaration' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''UTF-8'' + 'rOutRef.(XMLNSC.XmlDeclaration)*:*.(XMLNSC.Attribute)Encoding' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '32.3' + 'CREATE LASTCHILD OF rOutRef AS rOutReqRef NAMESPACE '' NAME 'request';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '33.3' + 'SET rOutReqRef.(XMLNSC.NamespaceDecl)xmlns:xsi = xsi;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'xsi' + ''http://www.w3.org/2001/XMLSchema-instance'' + 'xsi' + + + + 'XMLNSC.NamespaceDecl' + '50331906' + 'XMLNSC.NamespaceDecl' + + + + ''http://www.w3.org/2001/XMLSchema-instance'' + 'rOutReqRef.(XMLNSC.NamespaceDecl)xmlns:xsi' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '34.3' + 'SET rOutReqRef.(XMLNSC.Attribute)version = '2.00';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''2.00'' + 'rOutReqRef.(XMLNSC.Attribute)version' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '35.3' + 'SET rOutReqRef.(XMLNSC.NamespaceDecl)xsi:noNamespaceSchemaLocation = 'FileTransfer.xsd';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.NamespaceDecl' + '50331906' + 'XMLNSC.NamespaceDecl' + + + + ''FileTransfer.xsd'' + 'rOutReqRef.(XMLNSC.NamespaceDecl)xsi:noNamespaceSchemaLocation' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '38.3' + 'CREATE LASTCHILD OF rOutReqRef AS rManagedTransferRef NAMESPACE '' NAME 'managedTransfer';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '39.3' + 'CREATE LASTCHILD OF rManagedTransferRef AS rOriginatorRef NAMESPACE '' NAME 'originator';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '40.3' + 'SET rOriginatorRef.hostName = BrokerName;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'BrokerName' + ''IIBSTGNB1'' + 'BrokerName' + + + + ''IIBSTGNB1'' + 'rOriginatorRef.hostName' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '41.3' + 'SET rOriginatorRef.userID = BrokerUserId;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'BrokerUserId' + ''iibstgsvc'' + 'BrokerUserId' + + + + ''iibstgsvc'' + 'rOriginatorRef.userID' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '43.3' + 'CREATE LASTCHILD OF rManagedTransferRef AS rSourceAgentRef NAMESPACE '' NAME 'sourceAgent';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '44.3' + 'SET rSourceAgentRef.(XMLNSC.Attribute)QMgr = cQueueMGR;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cQueueMGR' + ''MWGWSTGQM'' + 'cQueueMGR' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''MWGWSTGQM'' + 'rSourceAgentRef.(XMLNSC.Attribute)QMgr' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '45.3' + 'SET rSourceAgentRef.(XMLNSC.Attribute)agent = cAgentName;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cAgentName' + ''ERPQUAEUAGNT1'' + 'cAgentName' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''ERPQUAEUAGNT1'' + 'rSourceAgentRef.(XMLNSC.Attribute)agent' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '48.3' + 'CREATE LASTCHILD OF rManagedTransferRef AS rDestinationAgentRef NAMESPACE '' NAME 'destinationAgent';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '49.3' + 'SET rDestinationAgentRef.(XMLNSC.Attribute)QMgr = cQueueMGR;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cQueueMGR' + ''MWGWSTGQM'' + 'cQueueMGR' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''MWGWSTGQM'' + 'rDestinationAgentRef.(XMLNSC.Attribute)QMgr' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '50.3' + 'SET rDestinationAgentRef.(XMLNSC.Attribute)agent = cAgentName;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cAgentName' + ''ERPQUAEUAGNT1'' + 'cAgentName' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''ERPQUAEUAGNT1'' + 'rDestinationAgentRef.(XMLNSC.Attribute)agent' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '58.3' + 'CREATE LASTCHILD OF rManagedTransferRef AS rTransferSetRef NAMESPACE '' NAME 'transferSet';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '60.3' + 'SET rTransferSetRef.(XMLNSC.Attribute)priority = '0';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''0'' + 'rTransferSetRef.(XMLNSC.Attribute)priority' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '61.3' + 'CREATE LASTCHILD OF rTransferSetRef AS rMetadataSetRef NAMESPACE '' NAME 'metaDataSet';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '62.3' + 'FOR rEnvMetaRef AS Environment.Variables.metadata.*:*[] DO ... END FOR;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '63.4' + 'CREATE LASTCHILD OF rMetadataSetRef AS rMetadataRef NAMESPACE '' NAME 'metaData';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '64.4' + 'SET rMetadataRef.(XMLNSC.Attribute)key = FIELDNAME(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''sitecode'' + 'FIELDNAME(rEnvMetaRef)' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''sitecode'' + 'rMetadataRef.(XMLNSC.Attribute)key' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '65.4' + 'SET rMetadataRef = FIELDVALUE(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''NBEU'' + 'FIELDVALUE(rEnvMetaRef)' + + + + ''NBEU'' + 'rMetadataRef' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '63.4' + 'CREATE LASTCHILD OF rMetadataSetRef AS rMetadataRef NAMESPACE '' NAME 'metaData';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '64.4' + 'SET rMetadataRef.(XMLNSC.Attribute)key = FIELDNAME(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''ordernumber'' + 'FIELDNAME(rEnvMetaRef)' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''ordernumber'' + 'rMetadataRef.(XMLNSC.Attribute)key' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '65.4' + 'SET rMetadataRef = FIELDVALUE(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''E300179204-15'' + 'FIELDVALUE(rEnvMetaRef)' + + + + ''E300179204-15'' + 'rMetadataRef' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '63.4' + 'CREATE LASTCHILD OF rMetadataSetRef AS rMetadataRef NAMESPACE '' NAME 'metaData';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '64.4' + 'SET rMetadataRef.(XMLNSC.Attribute)key = FIELDNAME(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''id'' + 'FIELDNAME(rEnvMetaRef)' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''id'' + 'rMetadataRef.(XMLNSC.Attribute)key' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '65.4' + 'SET rMetadataRef = FIELDVALUE(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''id'' + 'FIELDVALUE(rEnvMetaRef)' + + + + ''id'' + 'rMetadataRef' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '63.4' + 'CREATE LASTCHILD OF rMetadataSetRef AS rMetadataRef NAMESPACE '' NAME 'metaData';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '64.4' + 'SET rMetadataRef.(XMLNSC.Attribute)key = FIELDNAME(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''requesttype'' + 'FIELDNAME(rEnvMetaRef)' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''requesttype'' + 'rMetadataRef.(XMLNSC.Attribute)key' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '65.4' + 'SET rMetadataRef = FIELDVALUE(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''POSTSALESORDER'' + 'FIELDVALUE(rEnvMetaRef)' + + + + ''POSTSALESORDER'' + 'rMetadataRef' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '63.4' + 'CREATE LASTCHILD OF rMetadataSetRef AS rMetadataRef NAMESPACE '' NAME 'metaData';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '64.4' + 'SET rMetadataRef.(XMLNSC.Attribute)key = FIELDNAME(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''metaDataFileName'' + 'FIELDNAME(rEnvMetaRef)' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''metaDataFileName'' + 'rMetadataRef.(XMLNSC.Attribute)key' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '65.4' + 'SET rMetadataRef = FIELDVALUE(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''NBEUeffbca9207.metadata'' + 'FIELDVALUE(rEnvMetaRef)' + + + + ''NBEUeffbca9207.metadata'' + 'rMetadataRef' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '63.4' + 'CREATE LASTCHILD OF rMetadataSetRef AS rMetadataRef NAMESPACE '' NAME 'metaData';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '64.4' + 'SET rMetadataRef.(XMLNSC.Attribute)key = FIELDNAME(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''payLoadFileName'' + 'FIELDNAME(rEnvMetaRef)' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''payLoadFileName'' + 'rMetadataRef.(XMLNSC.Attribute)key' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '65.4' + 'SET rMetadataRef = FIELDVALUE(rEnvMetaRef);' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + ''NBEU_E300179204-15.850'' + 'FIELDVALUE(rEnvMetaRef)' + + + + ''NBEU_E300179204-15.850'' + 'rMetadataRef' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '69.3' + 'CREATE LASTCHILD OF rTransferSetRef AS rPostDestCallRef NAMESPACE '' NAME 'postDestinationCall';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '70.3' + 'CREATE LASTCHILD OF rPostDestCallRef AS rCommandRef NAMESPACE '' NAME 'command';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '71.3' + 'SET rCommandRef.(XMLNSC.Attribute)name = cShellProgram;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cShellProgram' + ''erpquaeu.sh'' + 'cShellProgram' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''erpquaeu.sh'' + 'rCommandRef.(XMLNSC.Attribute)name' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '72.3' + 'SET rCommandRef.(XMLNSC.Attribute)retryCount = '0';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''0'' + 'rCommandRef.(XMLNSC.Attribute)retryCount' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '73.3' + 'SET rCommandRef.(XMLNSC.Attribute)retryWait = '0';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''0'' + 'rCommandRef.(XMLNSC.Attribute)retryWait' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '74.3' + 'SET rCommandRef.(XMLNSC.Attribute)successRC = '0';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''0'' + 'rCommandRef.(XMLNSC.Attribute)successRC' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '75.3' + 'SET rCommandRef.(XMLNSC.Attribute)type = 'executable';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''executable'' + 'rCommandRef.(XMLNSC.Attribute)type' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '76.3' + 'SET rCommandRef.argument[1] = Environment.Variables.metadata.payLoadFileName;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.Variables.metadata.payLoadFileName' + 'ROW... Root Element Type=50331648 NameSpace='' Name='payLoadFileName' Value='NBEU_E300179204-15.850'' + 'Environment.Variables.metadata.payLoadFileName' + + + + 'Environment.Variables.metadata.payLoadFileName' + 'rCommandRef.argument[1]' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '77.3' + 'SET rCommandRef.argument[2] = Environment.Variables.metadata.metaDataFileName;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.Variables.metadata.metaDataFileName' + 'ROW... Root Element Type=50331648 NameSpace='' Name='metaDataFileName' Value='NBEUeffbca9207.metadata'' + 'Environment.Variables.metadata.metaDataFileName' + + + + 'Environment.Variables.metadata.metaDataFileName' + 'rCommandRef.argument[2]' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '78.9' + 'SET rCommandRef.argument[3] = cDestination;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cDestination' + ''/Inbound/Orders'' + 'cDestination' + + + + ''/Inbound/Orders'' + 'rCommandRef.argument[3]' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '80.3' + 'CREATE LASTCHILD OF rTransferSetRef AS rTransferSetItemRef NAMESPACE '' NAME 'item';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '81.3' + 'SET rTransferSetItemRef.(XMLNSC.Attribute)checksumMethod = 'MD5';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''MD5'' + 'rTransferSetItemRef.(XMLNSC.Attribute)checksumMethod' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '82.3' + 'SET rTransferSetItemRef.(XMLNSC.Attribute)mode = 'binary';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''binary'' + 'rTransferSetItemRef.(XMLNSC.Attribute)mode' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '83.3' + 'SET rTransferSetItemRef.source.(XMLNSC.Attribute)disposition = 'leave';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''leave'' + 'rTransferSetItemRef.source.(XMLNSC.Attribute)disposition' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '84.3' + 'SET rTransferSetItemRef.source.(XMLNSC.Attribute)recursive = 'false';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''false'' + 'rTransferSetItemRef.source.(XMLNSC.Attribute)recursive' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '85.3' + 'SET rTransferSetItemRef.source.(XMLNSC.Attribute)type = 'queue';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''queue'' + 'rTransferSetItemRef.source.(XMLNSC.Attribute)type' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '86.3' + 'SET rTransferSetItemRef.source.queue = cSourceQueue;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cSourceQueue' + ''SFDC.NB.ORDER.REQ'' + 'cSourceQueue' + + + + ''SFDC.NB.ORDER.REQ'' + 'rTransferSetItemRef.source.queue' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '87.3' + 'SET rTransferSetItemRef.source.queue.(XMLNSC.Attribute)groupId = Environment.payLoadGroupID;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.payLoadGroupID' + 'ROW... Root Element Type=50331648 NameSpace='' Name='payLoadGroupID' Value=X'effbca92070000effbca9207effbca92070000effbca9207'' + 'Environment.payLoadGroupID' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + 'Environment.payLoadGroupID' + 'rTransferSetItemRef.source.queue.(XMLNSC.Attribute)groupId' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '88.3' + 'SET rTransferSetItemRef.source.queue.(XMLNSC.Attribute)useGroups = 'true';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''true'' + 'rTransferSetItemRef.source.queue.(XMLNSC.Attribute)useGroups' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '89.3' + 'SET rTransferSetItemRef.destination.(XMLNSC.Attribute)exist = 'error';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''error'' + 'rTransferSetItemRef.destination.(XMLNSC.Attribute)exist' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '90.3' + 'SET rTransferSetItemRef.destination.(XMLNSC.Attribute)type = 'file';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''file'' + 'rTransferSetItemRef.destination.(XMLNSC.Attribute)type' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '92.3' + 'CREATE LASTCHILD OF rTransferSetItemRef.destination AS rFileRef NAMESPACE '' NAME 'file';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '93.3' + 'SET rFileRef = cDestination || '/' || Environment.Variables.metadata.payLoadFileName;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cDestination' + ''/Inbound/Orders'' + 'cDestination' + + + + ''/Inbound/Orders' || '/'' + ''/Inbound/Orders/'' + 'cDestination || '/'' + + + + 'Environment.Variables.metadata.payLoadFileName' + ''NBEU_E300179204-15.850'' + 'Environment.Variables.metadata.payLoadFileName' + + + + ''/Inbound/Orders/' || 'NBEU_E300179204-15.850'' + ''/Inbound/Orders/NBEU_E300179204-15.850'' + 'cDestination || '/' || Environment.Variables.metadata.payLoadFileName' + + + + ''/Inbound/Orders/NBEU_E300179204-15.850'' + 'rFileRef' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '96.3' + 'CREATE LASTCHILD OF rTransferSetRef AS rTransferSetItemRef NAMESPACE '' NAME 'item';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '97.3' + 'SET rTransferSetItemRef.(XMLNSC.Attribute)checksumMethod = 'MD5';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''MD5'' + 'rTransferSetItemRef.(XMLNSC.Attribute)checksumMethod' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '98.3' + 'SET rTransferSetItemRef.(XMLNSC.Attribute)mode = 'binary';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''binary'' + 'rTransferSetItemRef.(XMLNSC.Attribute)mode' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '99.3' + 'SET rTransferSetItemRef.source.(XMLNSC.Attribute)disposition = 'leave';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''leave'' + 'rTransferSetItemRef.source.(XMLNSC.Attribute)disposition' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '100.3' + 'SET rTransferSetItemRef.source.(XMLNSC.Attribute)recursive = 'false';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''false'' + 'rTransferSetItemRef.source.(XMLNSC.Attribute)recursive' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '101.3' + 'SET rTransferSetItemRef.source.(XMLNSC.Attribute)type = 'queue';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''queue'' + 'rTransferSetItemRef.source.(XMLNSC.Attribute)type' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '102.3' + 'SET rTransferSetItemRef.source.queue = cSourceQueue;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cSourceQueue' + ''SFDC.NB.ORDER.REQ'' + 'cSourceQueue' + + + + ''SFDC.NB.ORDER.REQ'' + 'rTransferSetItemRef.source.queue' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '103.3' + 'SET rTransferSetItemRef.source.queue.(XMLNSC.Attribute)groupId = Environment.metaDataGroupID;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.metaDataGroupID' + 'ROW... Root Element Type=50331648 NameSpace='' Name='metaDataGroupID' Value=X'effbca92071111effbca9207effbca92070000effbca9207'' + 'Environment.metaDataGroupID' + + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + 'Environment.metaDataGroupID' + 'rTransferSetItemRef.source.queue.(XMLNSC.Attribute)groupId' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '104.3' + 'SET rTransferSetItemRef.source.queue.(XMLNSC.Attribute)useGroups = 'true';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''true'' + 'rTransferSetItemRef.source.queue.(XMLNSC.Attribute)useGroups' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '105.3' + 'SET rTransferSetItemRef.destination.(XMLNSC.Attribute)exist = 'error';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''error'' + 'rTransferSetItemRef.destination.(XMLNSC.Attribute)exist' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '106.3' + 'SET rTransferSetItemRef.destination.(XMLNSC.Attribute)type = 'file';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'XMLNSC.Attribute' + '1035137450240' + 'XMLNSC.Attribute' + + + + ''file'' + 'rTransferSetItemRef.destination.(XMLNSC.Attribute)type' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '108.3' + 'CREATE LASTCHILD OF rTransferSetItemRef.destination AS rFileRef NAMESPACE '' NAME 'file';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '109.3' + 'SET rFileRef = cDestination || '/' || Environment.Variables.metadata.metaDataFileName;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cDestination' + ''/Inbound/Orders'' + 'cDestination' + + + + ''/Inbound/Orders' || '/'' + ''/Inbound/Orders/'' + 'cDestination || '/'' + + + + 'Environment.Variables.metadata.metaDataFileName' + ''NBEUeffbca9207.metadata'' + 'Environment.Variables.metadata.metaDataFileName' + + + + ''/Inbound/Orders/' || 'NBEUeffbca9207.metadata'' + ''/Inbound/Orders/NBEUeffbca9207.metadata'' + 'cDestination || '/' || Environment.Variables.metadata.metaDataFileName' + + + + ''/Inbound/Orders/NBEUeffbca9207.metadata'' + 'rFileRef' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '111.3' + 'CREATE LASTCHILD OF rManagedTransferRef AS rJobRef NAMESPACE '' NAME 'job';' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '112.3' + 'SET rJobRef.name = Environment.UniquenessId;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'Environment.UniquenessId' + 'ROW... Root Element Type=50331648 NameSpace='' Name='UniquenessId' Value='effbca9207'' + 'Environment.UniquenessId' + + + + 'Environment.UniquenessId' + 'rJobRef.name' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'com.nb.mqmft.NB_MFTProcessing_Compute.Main' + '114.3' + 'SET InputLocalEnvironment.Destination.MQ.DestinationData[1].queueName = 'SYSTEM.FTE.COMMAND.' || cAgentName;' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'cAgentName' + ''ERPQUAEUAGNT1'' + 'cAgentName' + + + + ''SYSTEM.FTE.COMMAND.' || 'ERPQUAEUAGNT1'' + ''SYSTEM.FTE.COMMAND.ERPQUAEUAGNT1'' + ''SYSTEM.FTE.COMMAND.' || cAgentName' + + + + ''SYSTEM.FTE.COMMAND.ERPQUAEUAGNT1'' + 'InputLocalEnvironment.Destination.MQ.DestinationData[1].queueName' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'InputLocalEnvironment, OutputRoot, InputExceptionList' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.NB_MFTProcessing_Compute + + + 'gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.MQ_Output_Command_Queue' + '' + 'connection: SERVER, destinationQueueManagerName: IIBQMSTGNB1, logLabel: gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.MQ_Output_Command_Queue' + gen.fulfillment_request_3.post (Implementation).NB_MFTProcessing.MQ_Output_Command_Queue + + + '.post_FullFillmentReq_Route_Compute.Main' + '121.3' + 'SET OutputRoot.JSON.Data.message = 'OK';' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + ''OK'' + 'OutputRoot.JSON.Data.message' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + '.post_FullFillmentReq_Route_Compute.Main' + '126.3' + 'RETURN TRUE;' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + 'OutputLocalEnvironment, OutputRoot, InputExceptionList' + gen.fulfillment_request_3.post (Implementation).Route_Compute + + + gen.fulfillment_request_3.post (Implementation).Output + + + 'gen.fulfillment_request_3.HTTP Reply' + 'HTTP' + gen.fulfillment_request_3.HTTP Reply + + \ No newline at end of file diff --git a/esql-code-coverage/src/test/resources/codecoverage/trace.xml b/esql-code-coverage/src/test/resources/codecoverage/trace.xml index fb01cbdf..d17e144e 100644 --- a/esql-code-coverage/src/test/resources/codecoverage/trace.xml +++ b/esql-code-coverage/src/test/resources/codecoverage/trace.xml @@ -1 +1,343 @@ -'default''3e243ae7-6b29-4ce8-b525-4e58a2edcbb6'ConfigurationManager'InputNode''''ABCDE'Test.Timeout Notification'Properties'00Test.Timeout NotificationTest.Timeout Notification'.Test_Compute.Main''2.2''BEGIN ... END;'Test.Compute'.Test_Compute.Main''3.3''DECLARE i INTEGER 1;'Test.Compute'.Test_Compute.Main''4.3''SET i = 2;'Test.Compute'.Test_Compute.Main''5.3''CALL dec(i);'Test.Compute'.Test_Compute.Main''5.8''dec(i)'Test.Compute'.Test_Compute.Main''5.14''i''2''i''.Test_Compute.dec''2.2''BEGIN ... END;'Test.Compute'.Test_Compute.dec''3.3''SET var = var - 1;'Test.Compute'.Test_Compute.dec''3.13''var''2''var''.Test_Compute.dec''3.16''2 - 1''1''var - 1''.Test_Compute.Main''6.3''RETURN TRUE;'Test.Compute''Test.Compute'0.5''1''ABCDE'Test.Timeout Notification'Properties'00Test.Timeout NotificationTest.Timeout Notification'.Test_Compute.Main''2.2''BEGIN ... END;'Test.Compute'.Test_Compute.Main''3.3''DECLARE i INTEGER 1;'Test.Compute'.Test_Compute.Main''4.3''SET i = 2;'Test.Compute'.Test_Compute.Main''5.3''CALL dec(i);'Test.Compute'.Test_Compute.Main''5.8''dec(i)'Test.Compute'.Test_Compute.Main''5.14''i''2''i''.Test_Compute.dec''2.2''BEGIN ... END;'Test.Compute'.Test_Compute.dec''3.3''SET var = var - 1;'Test.Compute'.Test_Compute.dec''3.13''var''2''var''.Test_Compute.dec''3.16''2 - 1''1''var - 1''.Test_Compute.Main''6.3''RETURN TRUE;'Test.Compute''Test.Compute'TESTMQ''TESTMQ''0.5''1''ABCDE'Test.Timeout Notification'Properties'00Test.Timeout NotificationTest.Timeout Notification'.Test_Compute.Main''2.2''BEGIN ... END;'Test.Compute'.Test_Compute.Main''3.3''DECLARE i INTEGER 1;'Test.Compute'.Test_Compute.Main''4.3''SET i = 2;'Test.Compute'.Test_Compute.Main''5.3''CALL dec(i);'Test.Compute'.Test_Compute.Main''5.8''dec(i)'Test.Compute'.Test_Compute.Main''5.14''i''2''i''.Test_Compute.dec''2.2''BEGIN ... END;'Test.Compute'.Test_Compute.dec''3.3''SET var = var - 1;'Test.Compute'.Test_Compute.dec''3.13''var''2''var''.Test_Compute.dec''3.16''2 - 1''1''var - 1''.Test_Compute.Main''6.3''RETURN TRUE;'Test.Compute''Test.Compute'0.5''1''ABCDE'Test.Timeout Notification'Properties'00Test.Timeout NotificationTest.Timeout Notification'.Test_Compute.Main''2.2''BEGIN ... END;'Test.Compute'.Test_Compute.Main''3.3''DECLARE i INTEGER 1;'Test.Compute'.Test_Compute.Main''4.3''SET i = 2;'Test.Compute'.Test_Compute.Main''5.3''CALL dec(i);'Test.Compute'.Test_Compute.Main''5.8''dec(i)'Test.Compute'.Test_Compute.Main''5.14''i''2''i''.Test_Compute.dec''2.2''BEGIN ... END;'Test.Compute'.Test_Compute.dec''3.3''SET var = var - 1;'Test.Compute'.Test_Compute.dec''3.13''var''2''var''.Test_Compute.dec''3.16''2 - 1''1''var - 1''.Test_Compute.Main''6.3''RETURN TRUE;'Test.Compute''Test.Compute'.InputNode''out'.InputNode'Properties'00.InputNode'MQMD'0364'MQHMD'.InputNode'XMLS'364298'XMLS'.InputNode \ No newline at end of file + + + +'default' +'3e243ae7-6b29-4ce8-b525-4e58a2edcbb6' +ConfigurationManager + +'InputNode' +'' + +'ABCDE' +Test.Timeout Notification + +'Properties' +0 +0 +Test.Timeout Notification + +Test.Timeout Notification + +'.Test_Compute.Main' +'2.2' +'BEGIN ... END;' +Test.Compute + +'.Test_Compute.Main' +'3.3' +'DECLARE i INTEGER 1;' +Test.Compute + +'.Test_Compute.Main' +'4.3' +'SET i = 2;' +Test.Compute + +'.Test_Compute.Main' +'5.3' +'CALL dec(i);' +Test.Compute + +'.Test_Compute.Main' +'5.8' +'dec(i)' +Test.Compute + +'.Test_Compute.Main' +'5.14' +'i' +'2' +'i' + + +'.Test_Compute.dec' +'2.2' +'BEGIN ... END;' +Test.Compute + +'.Test_Compute.dec' +'3.3' +'SET var = var - 1;' +Test.Compute + +'.Test_Compute.dec' +'3.13' +'var' +'2' +'var' + + +'.Test_Compute.dec' +'3.16' +'2 - 1' +'1' +'var - 1' + + +'.Test_Compute.Main' +'6.3' +'RETURN TRUE;' +Test.Compute + +'' +Test.Compute + + +'0.5' +'1' + +'ABCDE' +Test.Timeout Notification + +'Properties' +0 +0 +Test.Timeout Notification + +Test.Timeout Notification + +'.Test_Compute.Main' +'2.2' +'BEGIN ... END;' +Test.Compute + +'.Test_Compute.Main' +'3.3' +'DECLARE i INTEGER 1;' +Test.Compute + +'.Test_Compute.Main' +'4.3' +'SET i = 2;' +Test.Compute + +'.Test_Compute.Main' +'5.3' +'CALL dec(i);' +Test.Compute + +'.Test_Compute.Main' +'5.8' +'dec(i)' +Test.Compute + +'.Test_Compute.Main' +'5.14' +'i' +'2' +'i' + + +'.Test_Compute.dec' +'2.2' +'BEGIN ... END;' +Test.Compute + +'.Test_Compute.dec' +'3.3' +'SET var = var - 1;' +Test.Compute + +'.Test_Compute.dec' +'3.13' +'var' +'2' +'var' + + +'.Test_Compute.dec' +'3.16' +'2 - 1' +'1' +'var - 1' + + +'.Test_Compute.Main' +'6.3' +'RETURN TRUE;' +Test.Compute + +'' +Test.Compute + + +'TESTMQ' + +'TESTMQ' + +'0.5' +'1' + +'ABCDE' +Test.Timeout Notification + +'Properties' +0 +0 +Test.Timeout Notification + +Test.Timeout Notification + +'.Test_Compute.Main' +'2.2' +'BEGIN ... END;' +Test.Compute + +'.Test_Compute.Main' +'3.3' +'DECLARE i INTEGER 1;' +Test.Compute + +'.Test_Compute.Main' +'4.3' +'SET i = 2;' +Test.Compute + +'.Test_Compute.Main' +'5.3' +'CALL dec(i);' +Test.Compute + +'.Test_Compute.Main' +'5.8' +'dec(i)' +Test.Compute + +'.Test_Compute.Main' +'5.14' +'i' +'2' +'i' + + +'.Test_Compute.dec' +'2.2' +'BEGIN ... END;' +Test.Compute + +'.Test_Compute.dec' +'3.3' +'SET var = var - 1;' +Test.Compute + +'.Test_Compute.dec' +'3.13' +'var' +'2' +'var' + + +'.Test_Compute.dec' +'3.16' +'2 - 1' +'1' +'var - 1' + + +'.Test_Compute.Main' +'6.3' +'RETURN TRUE;' +Test.Compute + +'' +Test.Compute + + +'0.5' +'1' + +'ABCDE' +Test.Timeout Notification + +'Properties' +0 +0 +Test.Timeout Notification + +Test.Timeout Notification + +'.Test_Compute.Main' +'2.2' +'BEGIN ... END;' +Test.Compute + +'.Test_Compute.Main' +'3.3' +'DECLARE i INTEGER 1;' +Test.Compute + +'.Test_Compute.Main' +'4.3' +'SET i = 2;' +Test.Compute + +'.Test_Compute.Main' +'5.3' +'CALL dec(i);' +Test.Compute + +'.Test_Compute.Main' +'5.8' +'dec(i)' +Test.Compute + +'.Test_Compute.Main' +'5.14' +'i' +'2' +'i' + + +'.Test_Compute.dec' +'2.2' +'BEGIN ... END;' +Test.Compute + +'.Test_Compute.dec' +'3.3' +'SET var = var - 1;' +Test.Compute + +'.Test_Compute.dec' +'3.13' +'var' +'2' +'var' + + +'.Test_Compute.dec' +'3.16' +'2 - 1' +'1' +'var - 1' + + +'.Test_Compute.Main' +'6.3' +'RETURN TRUE;' +Test.Compute + +'' +Test.Compute + + +'.InputNode' +'out' +.InputNode + +'Properties' +0 +0 +.InputNode + +'MQMD' +0 +364 +'MQHMD' +.InputNode + +'XMLS' +364 +298 +'XMLS' +.InputNode diff --git a/esql-frontend/pom.xml b/esql-frontend/pom.xml index 77507704..af71387f 100644 --- a/esql-frontend/pom.xml +++ b/esql-frontend/pom.xml @@ -5,7 +5,7 @@ com.exxeta.iss sonar-esql-plugin - 2.3.5 + 0.0.1-SNAPSHOT esql-frontend @@ -47,7 +47,7 @@ org.mockito - mockito-all + mockito-core com.google.code.gson diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/CustomEsqlRulesDefinition.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/CustomEsqlRulesDefinition.java index 33f42b4a..2a987272 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/CustomEsqlRulesDefinition.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/CustomEsqlRulesDefinition.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -18,7 +18,7 @@ package com.exxeta.iss.sonar.esql.api; import org.sonar.api.ExtensionPoint; -import org.sonar.api.batch.BatchSide; +import org.sonar.api.batch.ScannerSide; import org.sonar.api.server.rule.RulesDefinition; import org.sonar.squidbridge.annotations.AnnotationBasedRulesDefinition; @@ -30,7 +30,8 @@ */ @Beta @ExtensionPoint -@BatchSide +@ScannerSide +@Deprecated public abstract class CustomEsqlRulesDefinition implements RulesDefinition { /** diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlCheck.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlCheck.java index 2207f797..19dac423 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlCheck.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -43,4 +43,4 @@ public interface EsqlCheck { T addIssue(T issue); List scanFile(TreeVisitorContext context); -} \ No newline at end of file +} diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlNonReservedKeyword.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlNonReservedKeyword.java index 4e6659a7..52e1ad88 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlNonReservedKeyword.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlNonReservedKeyword.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlTokenType.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlTokenType.java index 6c3e1a23..693ff228 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlTokenType.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/EsqlTokenType.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Symbol.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Symbol.java index 4fdcacb7..2256b629 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Symbol.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Symbol.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/SymbolModel.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/SymbolModel.java index 95096c13..54395b15 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/SymbolModel.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/SymbolModel.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/SymbolModelBuilder.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/SymbolModelBuilder.java index c71443f8..7d6a9de4 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/SymbolModelBuilder.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/SymbolModelBuilder.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Type.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Type.java index a03e249a..11133fa2 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Type.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Type.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -56,4 +56,4 @@ enum Kind { } -} \ No newline at end of file +} diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/TypeSet.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/TypeSet.java index cb37c877..fbaca386 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/TypeSet.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/TypeSet.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Usage.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Usage.java index 216aba84..34cf48ac 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Usage.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/symbols/Usage.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/AsbitstreamFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/AsbitstreamFunctionTree.java index 75d5d310..d2ed6aa6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/AsbitstreamFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/AsbitstreamFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/BrokerSchemaStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/BrokerSchemaStatementTree.java index 9b17e925..3dbcc76a 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/BrokerSchemaStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/BrokerSchemaStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/DataTypeTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/DataTypeTree.java index 1f1818d8..bf78cd56 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/DataTypeTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/DataTypeTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/DecimalDataTypeTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/DecimalDataTypeTree.java index 7eeba334..1d8f5be0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/DecimalDataTypeTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/DecimalDataTypeTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/EsqlContentsTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/EsqlContentsTree.java index 16f2cc88..3feca1a9 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/EsqlContentsTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/EsqlContentsTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/FieldReferenceTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/FieldReferenceTree.java index 50534cc2..48142ab2 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/FieldReferenceTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/FieldReferenceTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IndexTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IndexTree.java index dcb7554b..6072a19b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IndexTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IndexTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IntervalDataTypeTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IntervalDataTypeTree.java index 82b21f28..9242f6ff 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IntervalDataTypeTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IntervalDataTypeTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IntervalQualifierTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IntervalQualifierTree.java index 2f82f6bf..4b13920e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IntervalQualifierTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/IntervalQualifierTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/ModuleTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/ModuleTree.java index 467afbfd..341c64b6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/ModuleTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/ModuleTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/NamespaceTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/NamespaceTree.java index 30ebf9f1..2170da3e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/NamespaceTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/NamespaceTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathClauseTree.java index ed9c5473..9b1babe6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementNameTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementNameTree.java index eea8e492..b8c0b5f4 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementNameTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementNameTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementNamespaceTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementNamespaceTree.java index c1a501c9..dd39f007 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementNamespaceTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementNamespaceTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementTree.java index 651fefa5..9c0d553e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementTypeTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementTypeTree.java index 991bf810..7e3b3ed0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementTypeTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/PathElementTypeTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/ProgramTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/ProgramTree.java index 981d1bde..044b0311 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/ProgramTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/ProgramTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/RoutineDeclarationTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/RoutineDeclarationTree.java index bd1fbf7d..4dab725f 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/RoutineDeclarationTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/RoutineDeclarationTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/SchemaNameTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/SchemaNameTree.java index 2d6c020e..85998054 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/SchemaNameTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/SchemaNameTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/Tree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/Tree.java index 2a879ea3..f30feadf 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/Tree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/Tree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/BetweenExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/BetweenExpressionTree.java index aa8d0b51..94d9b5dc 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/BetweenExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/BetweenExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/BinaryExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/BinaryExpressionTree.java index 37844b03..0731e2e7 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/BinaryExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/BinaryExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/CallExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/CallExpressionTree.java index 1a34f39d..fa476fd0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/CallExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/CallExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/ExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/ExpressionTree.java index d6d3ddfb..5f0376d9 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/ExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/ExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IdentifierTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IdentifierTree.java index 87b00b50..12a66b7a 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IdentifierTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IdentifierTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -52,4 +52,4 @@ public interface IdentifierTree extends VariableReferenceTree, BindingElementTre * @return {@link Scope} instance in which this identifier appear */ Scope scope(); - } \ No newline at end of file + } diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/InExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/InExpressionTree.java index 74786f20..2d6a0a21 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/InExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/InExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IntervalExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IntervalExpressionTree.java index 2d0b5c1b..901d458a 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IntervalExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IntervalExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IsExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IsExpressionTree.java index e58d8daa..da0f7c34 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IsExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/IsExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/LikeExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/LikeExpressionTree.java index 3f2f4ff4..c6a00c21 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/LikeExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/LikeExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/ParenthesisedExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/ParenthesisedExpressionTree.java index 1b567485..7f40023c 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/ParenthesisedExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/ParenthesisedExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/UnaryExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/UnaryExpressionTree.java index e3f288db..e939c6d9 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/UnaryExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/UnaryExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/VariableReferenceTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/VariableReferenceTree.java index 6f904b7f..5e102a40 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/VariableReferenceTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/expression/VariableReferenceTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/AliasedExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/AliasedExpressionTree.java index efb01797..2c25ee48 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/AliasedExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/AliasedExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/AliasedFieldReferenceTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/AliasedFieldReferenceTree.java index f884ae8d..2fa8344d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/AliasedFieldReferenceTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/AliasedFieldReferenceTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/CaseFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/CaseFunctionTree.java index ffae1c49..d886b49d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/CaseFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/CaseFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/CastFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/CastFunctionTree.java index ca821fe7..2c041f23 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/CastFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/CastFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ComplexFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ComplexFunctionTree.java index 88afb352..60b72123 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ComplexFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ComplexFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/DateTimeFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/DateTimeFunctionTree.java index 846f7b8f..f472f7c5 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/DateTimeFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/DateTimeFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ExtractFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ExtractFunctionTree.java index b79ae7da..65bc2b67 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ExtractFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ExtractFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FieldFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FieldFunctionTree.java index c08bf7fb..d19c64b0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FieldFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FieldFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ForFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ForFunctionTree.java index 89d79634..a15bb532 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ForFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ForFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FromClauseExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FromClauseExpressionTree.java index cc2456d2..35f7c691 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FromClauseExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FromClauseExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FunctionTree.java index 11d551b7..fbb7cc22 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/FunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ListConstructorFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ListConstructorFunctionTree.java index 5d6aca2a..fe491392 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ListConstructorFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ListConstructorFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ListFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ListFunctionTree.java index 43544b2a..fc46c809 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ListFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/ListFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/MiscellaneousFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/MiscellaneousFunctionTree.java index 99c9d18e..8f415b2c 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/MiscellaneousFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/MiscellaneousFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/NumericFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/NumericFunctionTree.java index c8440c9f..4c79a096 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/NumericFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/NumericFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/OverlayFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/OverlayFunctionTree.java index dcaedb4c..2feb61d2 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/OverlayFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/OverlayFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/PassthruFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/PassthruFunctionTree.java index ee981d03..188da5c0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/PassthruFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/PassthruFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/PositionFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/PositionFunctionTree.java index 9385819e..b460b139 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/PositionFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/PositionFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/RoundFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/RoundFunctionTree.java index 67e581db..9348ec3f 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/RoundFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/RoundFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/RowConstructorFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/RowConstructorFunctionTree.java index 0bf24078..ac9fd204 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/RowConstructorFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/RowConstructorFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SelectClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SelectClauseTree.java index e9f863ed..d0dea995 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SelectClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SelectClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SelectFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SelectFunctionTree.java index 73a361e2..82f0a355 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SelectFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SelectFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/StringManipulationFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/StringManipulationFunctionTree.java index 7e58950f..8635ebd0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/StringManipulationFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/StringManipulationFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SubstringFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SubstringFunctionTree.java index e71ce808..a646041b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SubstringFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/SubstringFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/TheFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/TheFunctionTree.java index bbbb0f71..e7570d56 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/TheFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/TheFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/TrimFunctionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/TrimFunctionTree.java index 4a194369..ebe6c834 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/TrimFunctionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/TrimFunctionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/WhenClauseExpressionTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/WhenClauseExpressionTree.java index 9643c88a..315139b6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/WhenClauseExpressionTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/WhenClauseExpressionTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/WhereClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/WhereClauseTree.java index 93694085..d4574df6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/WhereClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/function/WhereClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/lexical/SyntaxToken.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/lexical/SyntaxToken.java index 27bc17e0..37b3bf40 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/lexical/SyntaxToken.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/lexical/SyntaxToken.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/lexical/SyntaxTrivia.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/lexical/SyntaxTrivia.java index 11204e6f..d4df9d43 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/lexical/SyntaxTrivia.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/lexical/SyntaxTrivia.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -20,4 +20,4 @@ public interface SyntaxTrivia extends SyntaxToken { -} \ No newline at end of file +} diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/AttachStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/AttachStatementTree.java index 416e8038..6e291931 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/AttachStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/AttachStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/BeginEndStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/BeginEndStatementTree.java index 81141f10..cc15450a 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/BeginEndStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/BeginEndStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CallStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CallStatementTree.java index 623ab1cc..3068c0e3 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CallStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CallStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CaseStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CaseStatementTree.java index f0677035..d0c6aabb 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CaseStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CaseStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ControlsTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ControlsTree.java index ba82532c..28a8f18d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ControlsTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ControlsTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateFunctionStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateFunctionStatementTree.java index e969a051..5cafae9d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateFunctionStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateFunctionStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateModuleStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateModuleStatementTree.java index 57fb8012..9bb06bf5 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateModuleStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateModuleStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateProcedureStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateProcedureStatementTree.java index b87b569d..665ddd13 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateProcedureStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateProcedureStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateStatementTree.java index 67e35228..4c783ac5 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/CreateStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeclareHandlerStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeclareHandlerStatementTree.java index bee0eacd..93802b93 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeclareHandlerStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeclareHandlerStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeclareStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeclareStatementTree.java index d14c25fd..076bb2ef 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeclareStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeclareStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeleteFromStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeleteFromStatementTree.java index 7c6f6e68..a66c64be 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeleteFromStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeleteFromStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeleteStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeleteStatementTree.java index 12540a65..a6db7b4d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeleteStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DeleteStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DetachStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DetachStatementTree.java index d4230fd3..ce3aed20 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DetachStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/DetachStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ElseClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ElseClauseTree.java index 3cd087c5..c54e53eb 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ElseClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ElseClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ElseifClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ElseifClauseTree.java index 5f69350c..afc0054a 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ElseifClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ElseifClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/EvalStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/EvalStatementTree.java index 0eacf411..8df00840 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/EvalStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/EvalStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ExternalRoutineBodyTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ExternalRoutineBodyTree.java index c33e6d89..80fca8dd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ExternalRoutineBodyTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ExternalRoutineBodyTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ForStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ForStatementTree.java index 5d7e0d8d..bebc874b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ForStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ForStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/FromClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/FromClauseTree.java index 607872c1..03159edd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/FromClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/FromClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/IfStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/IfStatementTree.java index db5c37d3..5cf8bb20 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/IfStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/IfStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/InsertStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/InsertStatementTree.java index 8b7cfc51..78a6fda5 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/InsertStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/InsertStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/IterateStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/IterateStatementTree.java index 749073cd..c6aacb7b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/IterateStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/IterateStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LabelTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LabelTree.java index 59716c5c..a31b0bc8 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LabelTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LabelTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LanguageTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LanguageTree.java index 34d30a7a..8b77cc44 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LanguageTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LanguageTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LeaveStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LeaveStatementTree.java index 7847b391..0cc7b437 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LeaveStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LeaveStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LogStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LogStatementTree.java index b3157227..caed0cfc 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LogStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LogStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LoopStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LoopStatementTree.java index 19617848..f11a5b6c 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LoopStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/LoopStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/MessageSourceTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/MessageSourceTree.java index bea4e14d..99348ec1 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/MessageSourceTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/MessageSourceTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/MoveStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/MoveStatementTree.java index 11a70780..2ead79df 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/MoveStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/MoveStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/NameClausesTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/NameClausesTree.java index 9de2e9e0..e0e4b6ac 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/NameClausesTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/NameClausesTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParameterListTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParameterListTree.java index e832a65e..56d50d45 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParameterListTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParameterListTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParameterTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParameterTree.java index c4cef1ba..366bbf98 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParameterTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParameterTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParseClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParseClauseTree.java index be9802a6..93005d0c 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParseClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ParseClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/PassthruStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/PassthruStatementTree.java index 9eb9f6c9..3dbdc8a4 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/PassthruStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/PassthruStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/PropagateStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/PropagateStatementTree.java index f0992e45..f6feb157 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/PropagateStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/PropagateStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RepeatClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RepeatClauseTree.java index 0c39a421..1b19ab19 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RepeatClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RepeatClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RepeatStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RepeatStatementTree.java index 445ebe73..8e70847d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RepeatStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RepeatStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ResignalStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ResignalStatementTree.java index b7f01150..699c47e9 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ResignalStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ResignalStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ResultSetTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ResultSetTree.java index ea562f66..fc7d9509 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ResultSetTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ResultSetTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ReturnStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ReturnStatementTree.java index 83db6ead..481851d2 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ReturnStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ReturnStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ReturnTypeTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ReturnTypeTree.java index 9cc2df68..132763bd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ReturnTypeTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ReturnTypeTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RoutineBodyTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RoutineBodyTree.java index a79573e6..ff9e2ea2 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RoutineBodyTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/RoutineBodyTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SetColumnTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SetColumnTree.java index 297eeea7..b4191772 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SetColumnTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SetColumnTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SetStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SetStatementTree.java index 02916ef1..49ec279e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SetStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SetStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SqlStateTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SqlStateTree.java index 4727dea4..edc2420d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SqlStateTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/SqlStateTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/StatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/StatementTree.java index 2548e413..9dc528c2 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/StatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/StatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/StatementsTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/StatementsTree.java index 3ceefcac..88229778 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/StatementsTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/StatementsTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ThrowStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ThrowStatementTree.java index edf18899..f14e2bfa 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ThrowStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ThrowStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/UpdateStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/UpdateStatementTree.java index df2d07e0..69ba07fb 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/UpdateStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/UpdateStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ValuesClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ValuesClauseTree.java index abed03fc..47f7b1d0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ValuesClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/ValuesClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/WhenClauseTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/WhenClauseTree.java index 447c954a..77863f10 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/WhenClauseTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/WhenClauseTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/WhileStatementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/WhileStatementTree.java index 3b662bd4..9345261e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/WhileStatementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/statement/WhileStatementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/symbols/type/TypableTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/symbols/type/TypableTree.java index 27642e99..5b1c3645 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/symbols/type/TypableTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/tree/symbols/type/TypableTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -21,4 +21,4 @@ public interface TypableTree { void add(Type type); -} \ No newline at end of file +} diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/DoubleDispatchVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/DoubleDispatchVisitor.java index 7032c85d..91c1913b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/DoubleDispatchVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/DoubleDispatchVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/DoubleDispatchVisitorCheck.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/DoubleDispatchVisitorCheck.java index 325de147..6fdfbc06 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/DoubleDispatchVisitorCheck.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/DoubleDispatchVisitorCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/EsqlFile.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/EsqlFile.java index 578c559c..eda440d8 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/EsqlFile.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/EsqlFile.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/EsqlVisitorContext.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/EsqlVisitorContext.java index e132c61e..173a311d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/EsqlVisitorContext.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/EsqlVisitorContext.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/FileIssue.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/FileIssue.java index 789320c8..f725dc07 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/FileIssue.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/FileIssue.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/Issue.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/Issue.java index 1e312927..a3b50f81 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/Issue.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/Issue.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -30,4 +30,4 @@ public interface Issue { Issue cost(double cost); - } \ No newline at end of file + } diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/IssueLocation.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/IssueLocation.java index 4d265219..a1c41452 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/IssueLocation.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/IssueLocation.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -63,4 +63,4 @@ public int endLineOffset() { return lastToken.endColumn(); } -} \ No newline at end of file +} diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/Issues.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/Issues.java index 89834766..d2daaed6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/Issues.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/Issues.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/LineIssue.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/LineIssue.java index ff9eeb4e..df3d903b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/LineIssue.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/LineIssue.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/PreciseIssue.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/PreciseIssue.java index 01021ee4..de8973e8 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/PreciseIssue.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/PreciseIssue.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/SubscriptionVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/SubscriptionVisitor.java index 3e0c9f15..ac6d08d9 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/SubscriptionVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/SubscriptionVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/SubscriptionVisitorCheck.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/SubscriptionVisitorCheck.java index e306617d..742102e0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/SubscriptionVisitorCheck.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/SubscriptionVisitorCheck.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/TreeVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/TreeVisitor.java index b0b5969c..3806d937 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/TreeVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/TreeVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/TreeVisitorContext.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/TreeVisitorContext.java index 6d9eca7b..c73bf74f 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/TreeVisitorContext.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/api/visitors/TreeVisitorContext.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/cpd/CpdVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/cpd/CpdVisitor.java index 5fc5ae48..96d6c9ee 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/cpd/CpdVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/cpd/CpdVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/highlighter/HighlightSymbolTableBuilder.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/highlighter/HighlightSymbolTableBuilder.java index dc1649d1..9f39c376 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/highlighter/HighlightSymbolTableBuilder.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/highlighter/HighlightSymbolTableBuilder.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/highlighter/HighlighterVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/highlighter/HighlighterVisitor.java index 4874c7ce..93c3dcc7 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/highlighter/HighlighterVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/highlighter/HighlighterVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlLexer.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlLexer.java index b5929f9c..6e1ed312 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlLexer.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlLexer.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -61,7 +61,7 @@ public final class EsqlLexer { public static final String MULTI_LINE_COMMENT = "/\\*[\\s\\S]*?\\*/"; public static final String MULTI_LINE_COMMENT_NO_LB = "/\\*[^\\n\\r]*?\\*/"; - public static final String COMMENT = "(?:" + SINGLE_LINE_COMMENT + "|" + MULTI_LINE_COMMENT + ")"; + public static final String COMMENT_CONTENT = "((?!/\\*)(?!\\*/)[\\s\\S])*"; /** @@ -82,7 +82,7 @@ public final class EsqlLexer { private static final String IDENTIFIER_START = "(?:[$_" + UNICODE_LETTER + "]|\\\\" + UNICODE_ESCAPE_SEQUENCE + ")"; private static final String IDENTIFIER_PART = "(?:" + IDENTIFIER_START + "|[" + UNICODE_COMBINING_MARK + UNICODE_DIGIT + UNICODE_CONNECTOR_PUNCTUATION + "])"; - private static final String IDENTIFIER_PART_ESCAPED = "(?:" + IDENTIFIER_START + "|[{" + UNICODE_COMBINING_MARK + UNICODE_DIGIT + UNICODE_CONNECTOR_PUNCTUATION+ "-.:<> }]|\"\")"; + private static final String IDENTIFIER_PART_ESCAPED = "(?:" + IDENTIFIER_START + "|[{" + UNICODE_COMBINING_MARK + UNICODE_DIGIT + UNICODE_CONNECTOR_PUNCTUATION+ "-.:<>% \\[\\]}]|\"\")"; public static final String IDENTIFIER = IDENTIFIER_START + IDENTIFIER_PART + "*+"; public static final String IDENTIFIER_WITH_QUOTES ="\"(" +IDENTIFIER_PART_ESCAPED + "*+)"+"\""; diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlPunctuator.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlPunctuator.java index bfe36f03..1fa75693 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlPunctuator.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlPunctuator.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlReservedKeyword.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlReservedKeyword.java index 62250ef2..d7807429 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlReservedKeyword.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlReservedKeyword.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlTokenType.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlTokenType.java index 3a2d937a..68485561 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlTokenType.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/lexer/EsqlTokenType.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/CommentLineVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/CommentLineVisitor.java index c15b35a2..5e967171 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/CommentLineVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/CommentLineVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/ComplexityVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/ComplexityVisitor.java index 9c9e9e68..d1e0fd1b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/ComplexityVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/ComplexityVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/CounterVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/CounterVisitor.java index b949ee26..93f75f6e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/CounterVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/CounterVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/EsqlMetrics.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/EsqlMetrics.java index 4bc28164..12f1174f 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/EsqlMetrics.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/EsqlMetrics.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/ExecutableLineVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/ExecutableLineVisitor.java index be3f7130..9febedfd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/ExecutableLineVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/ExecutableLineVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/LineVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/LineVisitor.java index 1fd827d2..15ce9fb7 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/LineVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/LineVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/MetricsVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/MetricsVisitor.java index 335ec7fe..067cf09b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/MetricsVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/metrics/MetricsVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlGrammar.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlGrammar.java index 1efa900a..3bf0abcd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlGrammar.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlGrammar.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlLegacyGrammar.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlLegacyGrammar.java index a0bc3526..ae7a3e14 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlLegacyGrammar.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlLegacyGrammar.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -53,7 +53,7 @@ public enum EsqlLegacyGrammar implements GrammarRuleKey { EOF, PROGRAM, EOS, LITERAL, BOOLEAN_LITERAL, NULL_LITERAL, NUMERIC_LITERAL, HEX_LITERAL, - STRING_LITERAL, SPACING, IDENTIFIER_NAME, IDENTIFIER_NAME_WO_QUOTES, IDENTIFIER_NAME_WITH_QUOTES + STRING_LITERAL, SPACING, COMMENT, SINGLE_LINE_COMMENT, MULTI_LINE_COMMENT, IDENTIFIER_NAME, IDENTIFIER_NAME_WO_QUOTES, IDENTIFIER_NAME_WITH_QUOTES , DATE_LITERAL, TIME_LITERAL, TIMESTAMP_LITERAL, SPACING_NO_LINE_BREAK_NOT_FOLLOWED_BY_LINE_BREAK, SPACING_NO_LB, NEXT_NOT_LB, SPACING_NOT_SKIPPED, LINE_TERMINATOR_SEQUENCE, EOS_NO_LB, LETTER_OR_DIGIT, reservedKeyword, @@ -86,9 +86,17 @@ private static void lexical(LexerlessGrammarBuilder b) { b.rule(SPACING_NO_LINE_BREAK_NOT_FOLLOWED_BY_LINE_BREAK).is(SPACING_NO_LB, NEXT_NOT_LB); b.rule(SPACING).is(b.skippedTrivia(b.regexp("[" + EsqlLexer.LINE_TERMINATOR + EsqlLexer.WHITESPACE + "]*+")), - b.zeroOrMore(b.commentTrivia(b.regexp(EsqlLexer.COMMENT)), + b.zeroOrMore(COMMENT, b.skippedTrivia(b.regexp("[" + EsqlLexer.LINE_TERMINATOR + EsqlLexer.WHITESPACE + "]*+")))) .skip(); + b.rule(COMMENT).is(b.commentTrivia(b.firstOf( + SINGLE_LINE_COMMENT, + MULTI_LINE_COMMENT + ))); + b.rule(SINGLE_LINE_COMMENT).is (b.regexp(EsqlLexer.SINGLE_LINE_COMMENT)); + b.rule(MULTI_LINE_COMMENT).is (b.regexp("/\\*"), + b.optional(b.regexp(EsqlLexer.COMMENT_CONTENT)), b.optional(MULTI_LINE_COMMENT), b.optional(b.regexp(EsqlLexer.COMMENT_CONTENT)), + b.regexp("\\*/")); b.rule(SPACING_NOT_SKIPPED).is(SPACING); b.rule(SPACING_NO_LB).is(b.zeroOrMore(b.firstOf(b.skippedTrivia(b.regexp("[" + EsqlLexer.WHITESPACE + "]++")), diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlNodeBuilder.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlNodeBuilder.java index 24957eab..8a88ae47 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlNodeBuilder.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlNodeBuilder.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlParser.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlParser.java index 94760baf..66652bc3 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlParser.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlParser.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -68,4 +68,4 @@ private static Tree setParents(Tree tree) { } -} \ No newline at end of file +} diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlParserBuilder.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlParserBuilder.java index 5a746b3d..c2b4a5fb 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlParserBuilder.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/EsqlParserBuilder.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/TreeFactory.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/TreeFactory.java index bdd4ee11..ba3647ae 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/TreeFactory.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/parser/TreeFactory.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/EsqlCommentAnalyser.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/EsqlCommentAnalyser.java index 2d2671b2..d3a8c115 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/EsqlCommentAnalyser.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/EsqlCommentAnalyser.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -17,11 +17,8 @@ */ package com.exxeta.iss.sonar.esql.tree; -import org.sonar.squidbridge.CommentAnalyser; +public class EsqlCommentAnalyser { -public class EsqlCommentAnalyser extends CommentAnalyser { - - @Override public boolean isBlank(String line) { for (int i = 0; i < line.length(); i++) { if (Character.isLetterOrDigit(line.charAt(i))) { @@ -31,7 +28,6 @@ public boolean isBlank(String line) { return true; } - @Override public String getContents(String comment) { if (comment.startsWith("--")) { return comment.substring(2); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/Kinds.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/Kinds.java index 6d978dff..bc7cc653 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/Kinds.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/Kinds.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/SyntacticEquivalence.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/SyntacticEquivalence.java index 7f2b3301..34fa807a 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/SyntacticEquivalence.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/SyntacticEquivalence.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/declaration/BindingElementTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/declaration/BindingElementTree.java index 5356122b..f5400cfd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/declaration/BindingElementTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/declaration/BindingElementTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/expression/LikeExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/expression/LikeExpressionTreeImpl.java index 8e7468eb..9ea1eaae 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/expression/LikeExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/expression/LikeExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/expression/LiteralTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/expression/LiteralTree.java index 6ba79711..dfb8266f 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/expression/LiteralTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/expression/LiteralTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/EsqlTree.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/EsqlTree.java index cd25accf..965ecf31 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/EsqlTree.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/EsqlTree.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/SeparatedList.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/SeparatedList.java index e44d8375..ee206da5 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/SeparatedList.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/SeparatedList.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/BrokerSchemaStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/BrokerSchemaStatementTreeImpl.java index 8fd4626f..0f914d1e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/BrokerSchemaStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/BrokerSchemaStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/DataTypeTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/DataTypeTreeImpl.java index bf3df937..dcdc0df8 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/DataTypeTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/DataTypeTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/DecimalDataTypeTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/DecimalDataTypeTreeImpl.java index 659869fb..f8b35efd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/DecimalDataTypeTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/DecimalDataTypeTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/EsqlContentsTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/EsqlContentsTreeImpl.java index 747bf8fe..edc533df 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/EsqlContentsTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/EsqlContentsTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/FieldReferenceTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/FieldReferenceTreeImpl.java index af25e4a8..f016742d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/FieldReferenceTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/FieldReferenceTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IndexTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IndexTreeImpl.java index 9e8f49f2..26feb462 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IndexTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IndexTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IntervalDataTypeTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IntervalDataTypeTreeImpl.java index 8845d7ce..b313846d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IntervalDataTypeTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IntervalDataTypeTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IntervalQualifierTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IntervalQualifierTreeImpl.java index 39f03f88..1aed2a42 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IntervalQualifierTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/IntervalQualifierTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/NamespaceTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/NamespaceTreeImpl.java index b19b4fbb..89acff41 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/NamespaceTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/NamespaceTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/ParameterListTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/ParameterListTreeImpl.java index 7721e689..9c45d4a3 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/ParameterListTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/ParameterListTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathClauseTreeImpl.java index 44be88d3..abce65e6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementNameTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementNameTreeImpl.java index c56d5bac..aa8ed1b9 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementNameTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementNameTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementNamespaceTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementNamespaceTreeImpl.java index 11a21743..d2ca10db 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementNamespaceTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementNamespaceTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementTreeImpl.java index 366eb7b3..7b2a15be 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementTypeTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementTypeTreeImpl.java index 3d8f22dc..90b4b8d1 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementTypeTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/PathElementTypeTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/ProgramTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/ProgramTreeImpl.java index 045f1019..9ddd365c 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/ProgramTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/ProgramTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/SchemaNameTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/SchemaNameTreeImpl.java index 7666076f..0cdccf61 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/SchemaNameTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/declaration/SchemaNameTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/BetweenExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/BetweenExpressionTreeImpl.java index 2cdb580c..102f53f4 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/BetweenExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/BetweenExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/BinaryExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/BinaryExpressionTreeImpl.java index 04bd48c2..ea20a91c 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/BinaryExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/BinaryExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/CallExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/CallExpressionTreeImpl.java index b9dcf72b..e58f5b6d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/CallExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/CallExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IdentifierTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IdentifierTreeImpl.java index 6e45a534..991c0336 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IdentifierTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IdentifierTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -134,4 +134,4 @@ public void scope(Scope scope) { public List bindingIdentifiers() { return ImmutableList.of((IdentifierTree) this); } - } \ No newline at end of file + } diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/InExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/InExpressionTreeImpl.java index bcfaf1e3..1c878ae5 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/InExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/InExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IntervalExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IntervalExpressionTreeImpl.java index ef394352..0c354731 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IntervalExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IntervalExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IsExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IsExpressionTreeImpl.java index d4c25709..70abdba7 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IsExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/IsExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/LiteralTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/LiteralTreeImpl.java index c6b8114e..e99f9ace 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/LiteralTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/LiteralTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/ParenthesisedExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/ParenthesisedExpressionTreeImpl.java index 29bdf2ec..d91ffb00 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/ParenthesisedExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/ParenthesisedExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/PrefixExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/PrefixExpressionTreeImpl.java index f6f5ab6b..595a5cf6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/PrefixExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/expression/PrefixExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AliasedExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AliasedExpressionTreeImpl.java index 4f3f1987..e5fa7e67 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AliasedExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AliasedExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AliasedFieldReferenceTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AliasedFieldReferenceTreeImpl.java index 725cf3a2..29263703 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AliasedFieldReferenceTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AliasedFieldReferenceTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AsbitstreamFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AsbitstreamFunctionTreeImpl.java index 828fb41d..0f7ac7ff 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AsbitstreamFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/AsbitstreamFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/CaseFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/CaseFunctionTreeImpl.java index f36d1ae3..4ecb49be 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/CaseFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/CaseFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/CastFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/CastFunctionTreeImpl.java index 5a44d301..7446e317 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/CastFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/CastFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ExtractFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ExtractFunctionTreeImpl.java index 1f805193..c4e8123e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ExtractFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ExtractFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ForFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ForFunctionTreeImpl.java index ed76df4f..34268177 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ForFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ForFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/FromClauseExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/FromClauseExpressionTreeImpl.java index 85171431..8519b635 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/FromClauseExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/FromClauseExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ListConstructorFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ListConstructorFunctionTreeImpl.java index e6c64af9..9fbcf99e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ListConstructorFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/ListConstructorFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/OverlayFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/OverlayFunctionTreeImpl.java index 806141a5..cffb5d2b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/OverlayFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/OverlayFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/PassthruFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/PassthruFunctionTreeImpl.java index 2f766cf3..d952adf5 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/PassthruFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/PassthruFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/PositionFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/PositionFunctionTreeImpl.java index ef076fc7..ea0ec428 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/PositionFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/PositionFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/RoundFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/RoundFunctionTreeImpl.java index bdf9920d..ae6fcee7 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/RoundFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/RoundFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/RowConstructorFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/RowConstructorFunctionTreeImpl.java index bb086cd9..9bac2767 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/RowConstructorFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/RowConstructorFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SelectClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SelectClauseTreeImpl.java index f67930fa..aff9e9d0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SelectClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SelectClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SelectFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SelectFunctionTreeImpl.java index 1c02644c..a0ea6db9 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SelectFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SelectFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SubstringFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SubstringFunctionTreeImpl.java index efa5df6f..e6d4c378 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SubstringFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/SubstringFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/TheFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/TheFunctionTreeImpl.java index 596e70b9..9443b429 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/TheFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/TheFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/TrimFunctionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/TrimFunctionTreeImpl.java index 91282edb..2ac50754 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/TrimFunctionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/TrimFunctionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/WhenClauseExpressionTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/WhenClauseExpressionTreeImpl.java index 744654d0..7804dd9b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/WhenClauseExpressionTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/WhenClauseExpressionTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/WhereClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/WhereClauseTreeImpl.java index 106d5278..a146c55e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/WhereClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/function/WhereClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/lexical/InternalSyntaxToken.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/lexical/InternalSyntaxToken.java index a6e4a17f..5e36ed66 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/lexical/InternalSyntaxToken.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/lexical/InternalSyntaxToken.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/lexical/InternalSyntaxTrivia.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/lexical/InternalSyntaxTrivia.java index e2a61554..89fb9dee 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/lexical/InternalSyntaxTrivia.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/lexical/InternalSyntaxTrivia.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/AttachStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/AttachStatementTreeImpl.java index 4eab0621..54ef1027 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/AttachStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/AttachStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/BeginEndStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/BeginEndStatementTreeImpl.java index c8180b5c..3f62935a 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/BeginEndStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/BeginEndStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CallStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CallStatementTreeImpl.java index 798e42e0..ad40e369 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CallStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CallStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CaseStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CaseStatementTreeImpl.java index 858795d3..4409b0a1 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CaseStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CaseStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ControlsTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ControlsTreeImpl.java index 06a6ec22..5a9ea64b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ControlsTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ControlsTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateFunctionStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateFunctionStatementTreeImpl.java index d5c3daa0..ca3656e7 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateFunctionStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateFunctionStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateModuleStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateModuleStatementTreeImpl.java index ff1c5985..263842ce 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateModuleStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateModuleStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateProcedureStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateProcedureStatementTreeImpl.java index 33fd6790..bd620cbd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateProcedureStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateProcedureStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateRoutineTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateRoutineTreeImpl.java index f7fd49d1..3709f091 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateRoutineTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateRoutineTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateStatementTreeImpl.java index f72cb8d3..501caff8 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/CreateStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeclareHandlerStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeclareHandlerStatementTreeImpl.java index 4b7af502..becf9b13 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeclareHandlerStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeclareHandlerStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeclareStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeclareStatementTreeImpl.java index 4c790b33..7f5cd879 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeclareStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeclareStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeleteFromStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeleteFromStatementTreeImpl.java index fef0331a..97dcb10d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeleteFromStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeleteFromStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeleteStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeleteStatementTreeImpl.java index e202eb23..5b00ea03 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeleteStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DeleteStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DetachStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DetachStatementTreeImpl.java index 71eed335..3d3df65d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DetachStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/DetachStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ElseClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ElseClauseTreeImpl.java index e091f8a6..8236246c 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ElseClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ElseClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ElseifClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ElseifClauseTreeImpl.java index ab8a5e7e..2f108b48 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ElseifClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ElseifClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/EvalStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/EvalStatementTreeImpl.java index b88fd1a2..100a6ce6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/EvalStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/EvalStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ExternalRoutineBodyTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ExternalRoutineBodyTreeImpl.java index fff9518a..53a61f20 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ExternalRoutineBodyTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ExternalRoutineBodyTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ForStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ForStatementTreeImpl.java index 12851a3e..e0a566e0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ForStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ForStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/FromClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/FromClauseTreeImpl.java index 302fbab3..a179f106 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/FromClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/FromClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/IfStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/IfStatementTreeImpl.java index 509ea478..695f235b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/IfStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/IfStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/InsertStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/InsertStatementTreeImpl.java index ee38482e..3ab24906 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/InsertStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/InsertStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/IterateStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/IterateStatementTreeImpl.java index fa6cb3c7..fdb187c2 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/IterateStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/IterateStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LabelTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LabelTreeImpl.java index c8ff91dc..b7451257 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LabelTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LabelTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LanguageTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LanguageTreeImpl.java index 7a4b7e12..3e263319 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LanguageTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LanguageTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LeaveStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LeaveStatementTreeImpl.java index 2bf3ae80..6c0aff00 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LeaveStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LeaveStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LogStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LogStatementTreeImpl.java index b6693d31..4c471ab3 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LogStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LogStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LoopStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LoopStatementTreeImpl.java index 50e8cc65..64faa72a 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LoopStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/LoopStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/MessageSourceTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/MessageSourceTreeImpl.java index 9b4928d4..e1e0bf38 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/MessageSourceTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/MessageSourceTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/MoveStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/MoveStatementTreeImpl.java index 9e37f3a5..4b096932 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/MoveStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/MoveStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/NameClausesTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/NameClausesTreeImpl.java index 60fb6dd4..cbe6e229 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/NameClausesTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/NameClausesTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -139,4 +139,4 @@ public Iterator childrenIterator() { repeatNameKeyword); } -} \ No newline at end of file +} diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ParameterTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ParameterTreeImpl.java index 17c7d152..d4282ba1 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ParameterTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ParameterTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ParseClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ParseClauseTreeImpl.java index 7adbd723..1f3e36ad 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ParseClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ParseClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/PassthruStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/PassthruStatementTreeImpl.java index 1134624d..30596a60 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/PassthruStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/PassthruStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/PropagateStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/PropagateStatementTreeImpl.java index a456db12..b341dec1 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/PropagateStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/PropagateStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RepeatClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RepeatClauseTreeImpl.java index 338645e8..e65ac646 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RepeatClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RepeatClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RepeatStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RepeatStatementTreeImpl.java index 6233153e..b86a019f 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RepeatStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RepeatStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ResignalStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ResignalStatementTreeImpl.java index 25788262..4974014e 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ResignalStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ResignalStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ResultSetTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ResultSetTreeImpl.java index 5d641e07..3d7f2153 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ResultSetTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ResultSetTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ReturnStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ReturnStatementTreeImpl.java index 5a8b6753..aabbd7fd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ReturnStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ReturnStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ReturnTypeTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ReturnTypeTreeImpl.java index 146c1294..f0ee3e98 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ReturnTypeTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ReturnTypeTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RoutineBodyTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RoutineBodyTreeImpl.java index 77c23ed3..53c7faa6 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RoutineBodyTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/RoutineBodyTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SetColumnTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SetColumnTreeImpl.java index 783eaeae..f83b434d 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SetColumnTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SetColumnTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SetStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SetStatementTreeImpl.java index e68c230e..282897d8 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SetStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SetStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SqlStateTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SqlStateTreeImpl.java index 028301b0..9db1a823 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SqlStateTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/SqlStateTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/StatementsTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/StatementsTreeImpl.java index 9b98ae1d..5046cabf 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/StatementsTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/StatementsTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ThrowStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ThrowStatementTreeImpl.java index 4e1c3372..90b687e0 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ThrowStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ThrowStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/UpdateStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/UpdateStatementTreeImpl.java index f6fcb70f..fb409baf 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/UpdateStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/UpdateStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ValuesClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ValuesClauseTreeImpl.java index 00833917..2c6cba3b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ValuesClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/ValuesClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/WhenClauseTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/WhenClauseTreeImpl.java index 636c29d7..01debaa7 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/WhenClauseTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/WhenClauseTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/WhileStatementTreeImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/WhileStatementTreeImpl.java index 2d31b24a..a3f1e1c5 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/WhileStatementTreeImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/impl/statement/WhileStatementTreeImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/HoistedSymbolVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/HoistedSymbolVisitor.java index ebb2342e..e40edac9 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/HoistedSymbolVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/HoistedSymbolVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/Scope.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/Scope.java index 9f187c80..b8b4733c 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/Scope.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/Scope.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/ScopeVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/ScopeVisitor.java index af85e488..f779693b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/ScopeVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/ScopeVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/SymbolModelImpl.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/SymbolModelImpl.java index 3bc4ba9a..8db2c43f 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/SymbolModelImpl.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/SymbolModelImpl.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/SymbolVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/SymbolVisitor.java index 68e4dc5f..4ff91c65 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/SymbolVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/SymbolVisitor.java @@ -1,14 +1,14 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -29,6 +29,10 @@ import com.exxeta.iss.sonar.esql.api.tree.statement.CreateProcedureStatementTree; import com.exxeta.iss.sonar.esql.api.tree.statement.DeclareStatementTree; import com.exxeta.iss.sonar.esql.api.visitors.DoubleDispatchVisitor; +import com.exxeta.iss.sonar.esql.tree.impl.declaration.PathElementNamespaceTreeImpl; +import com.exxeta.iss.sonar.esql.tree.impl.declaration.PathElementTreeImpl; +import com.exxeta.iss.sonar.esql.tree.impl.expression.IdentifierTreeImpl; +import com.exxeta.iss.sonar.esql.tree.impl.lexical.InternalSyntaxToken; import com.google.common.collect.HashMultimap; import com.google.common.collect.SetMultimap; @@ -81,10 +85,17 @@ public void visitDeclareStatement(DeclareStatementTree tree) { public void visitIdentifier(IdentifierTree tree) { if (tree.is(Tree.Kind.IDENTIFIER_REFERENCE, Tree.Kind.PROPERTY_IDENTIFIER)) { addUsageFor(tree, Usage.Kind.READ); + if (tree.parent() != null && tree.parent().parent() instanceof PathElementTreeImpl) { + PathElementNamespaceTreeImpl namespace = ((PathElementTreeImpl) tree.parent().parent()).namespace(); + if (namespace != null && namespace.namespace() != null) { + IdentifierTree identifierTree = new IdentifierTreeImpl(Tree.Kind.PROPERTY_IDENTIFIER, (InternalSyntaxToken) namespace.namespace().identifier()); + addUsageFor(identifierTree, Usage.Kind.READ); + } + } } super.visitIdentifier(tree); } - + @Override public void visitBeginEndStatement(BeginEndStatementTree tree) { if (isScopeAlreadyEntered(tree)) { diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/Type.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/Type.java index b6b166ea..f199b340 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/Type.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/Type.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/FunctionType.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/FunctionType.java index fc1af20f..ebd9fff8 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/FunctionType.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/FunctionType.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/PrimitiveOperations.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/PrimitiveOperations.java index 3dc4b7cb..5f5592e5 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/PrimitiveOperations.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/PrimitiveOperations.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/PrimitiveType.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/PrimitiveType.java index b2ab1c6e..e19f68e1 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/PrimitiveType.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/PrimitiveType.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/ProcedureType.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/ProcedureType.java index 6428e5f5..bab33205 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/ProcedureType.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/ProcedureType.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/RoutineType.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/RoutineType.java index 4bd99c44..6f75e3bd 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/RoutineType.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/RoutineType.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/TypeVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/TypeVisitor.java index 4f319929..5623fa8c 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/TypeVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/symbols/type/TypeVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/visitors/CharsetAwareVisitor.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/visitors/CharsetAwareVisitor.java index 856cd3c2..0285d79b 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/visitors/CharsetAwareVisitor.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/tree/visitors/CharsetAwareVisitor.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/utils/LiteralUtils.java b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/utils/LiteralUtils.java index 41f82efc..ec2a717a 100644 --- a/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/utils/LiteralUtils.java +++ b/esql-frontend/src/main/java/com/exxeta/iss/sonar/esql/utils/LiteralUtils.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/CustomEsqlRulesDefinitionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/CustomEsqlRulesDefinitionTest.java index c45860bc..9925824c 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/CustomEsqlRulesDefinitionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/CustomEsqlRulesDefinitionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/IssueTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/IssueTest.java index 477e3617..9fdbfb3e 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/IssueTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/IssueTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/TypeSetTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/TypeSetTest.java index 95f8dd04..223a668a 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/TypeSetTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/TypeSetTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/ArgumentListTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/ArgumentListTest.java index 1f68aff0..dcce5d2d 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/ArgumentListTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/ArgumentListTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/CreateProcedureTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/CreateProcedureTest.java index ef5a2439..109054d3 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/CreateProcedureTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/CreateProcedureTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/CreateRoutineTreeImplTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/CreateRoutineTreeImplTest.java index bf9e66a0..a4841cae 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/CreateRoutineTreeImplTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/CreateRoutineTreeImplTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/DataTypeTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/DataTypeTest.java index e22a5c85..5e6dba6d 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/DataTypeTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/DataTypeTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/FieldReferenceTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/FieldReferenceTest.java index 7c7c44d2..6f28f2f3 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/FieldReferenceTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/FieldReferenceTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -49,6 +49,8 @@ public void pathElement(){ .notMatches("a a") .matches("cursor") .matches("(XML.Element)NSpace1:Element1[2]") + .matches("\"A-Z\"") + .matches("\"[A-Z]\"") ; diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/IdentifierTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/IdentifierTest.java index 696032a6..6ccec7f4 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/IdentifierTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/IdentifierTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/KeywordTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/KeywordTest.java index e7c46865..bbeccd85 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/KeywordTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/KeywordTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/ReturnTypeTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/ReturnTypeTest.java index be62c7f8..27340b53 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/ReturnTypeTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/ReturnTypeTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/SeparatedListTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/SeparatedListTest.java index e2efa9ad..d817cb72 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/SeparatedListTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/SeparatedListTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/SpacingTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/SpacingTest.java index 8b54ba5b..9772185f 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/SpacingTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/SpacingTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -44,8 +44,10 @@ public void ok() { .matches("-- comment \n") .as("MultiLineComment") - .matches("/* comment */") - .matches("/* comment \n */"); + .matches("/* comment */") + .matches("/* /* comment */ */") + .matches("/* comment \n */") + .notMatches("/* /* comment */"); } } diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/BetweenExpressionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/BetweenExpressionTest.java index 22479bff..5db2f8f0 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/BetweenExpressionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/BetweenExpressionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/ExpressionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/ExpressionTest.java index 1f2886f8..b5ecaed9 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/ExpressionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/ExpressionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/InExpressionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/InExpressionTest.java index a40c1720..29967c4f 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/InExpressionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/InExpressionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/IsExpressionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/IsExpressionTest.java index e812cd5d..f960ace8 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/IsExpressionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/IsExpressionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/LikeExpressionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/LikeExpressionTest.java index 7e0b12bb..4da31b36 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/LikeExpressionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/LikeExpressionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/LiteralTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/LiteralTest.java index 886e5808..b303e214 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/LiteralTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/LiteralTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/PrimaryExpressionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/PrimaryExpressionTest.java index fec6e4ff..c470745e 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/PrimaryExpressionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/PrimaryExpressionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/UnaryExpressionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/UnaryExpressionTest.java index 133b4b8f..eef5215b 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/UnaryExpressionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/expression/UnaryExpressionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/AsbitstreamFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/AsbitstreamFunctionTest.java index 4ab862ca..9ecac5dc 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/AsbitstreamFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/AsbitstreamFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CaseFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CaseFunctionTest.java index 35ef233d..b2ac6723 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CaseFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CaseFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CastFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CastFunctionTest.java index 42cab53c..41b13f1d 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CastFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CastFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CreateFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CreateFunctionTest.java index f94dea0d..4db2027d 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CreateFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/CreateFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ExtractFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ExtractFunctionTest.java index ad79d443..0afc7a4b 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ExtractFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ExtractFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ForFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ForFunctionTest.java index 5af688e1..6b7a4572 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ForFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ForFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ListConstructorFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ListConstructorFunctionTest.java index 2a81fada..af781076 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ListConstructorFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/ListConstructorFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/OverlayFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/OverlayFunctionTest.java index 98ea2200..4ad844c1 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/OverlayFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/OverlayFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/PassthruFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/PassthruFunctionTest.java index be309340..baeaa67b 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/PassthruFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/PassthruFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -67,4 +67,3 @@ public void modelTest() throws Exception{ } } - \ No newline at end of file diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/PositionFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/PositionFunctionTest.java index 5bb9ac3f..8dbc75e7 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/PositionFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/PositionFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/RoundFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/RoundFunctionTest.java index 389052b8..bc87a3dc 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/RoundFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/RoundFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/RowConstructorFunctionTest.java b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/RowConstructorFunctionTest.java index 3ad185e7..a36620b5 100644 --- a/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/RowConstructorFunctionTest.java +++ b/esql-frontend/src/test/java/com/exxeta/iss/sonar/esql/api/tree/function/RowConstructorFunctionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -29,8 +29,11 @@ public class RowConstructorFunctionTest extends EsqlTreeModelTest com.exxeta.iss sonar-esql-plugin - 2.3.5 + 0.0.1-SNAPSHOT esql-plugin sonar-plugin ESQL :: Sonar Plugin - Enables analysis of ESQL projects. - http://exxeta.com + Enables analysis of ESQL in IIB projects. + https://github.com/EXXETA/sonar-esql-plugin scm:git:git@github.com:EXXETA/sonar-esql-plugin.git @@ -62,8 +62,12 @@ org.mockito - mockito-all + mockito-core + + org.sonarsource.analyzer-commons + sonar-analyzer-commons + @@ -78,6 +82,7 @@ true false ${sonarQubeMinVersion} + iibesql @@ -118,8 +123,9 @@ - 4200000 - 4300000 + + 4400000 + 4500000 ${project.build.directory}/${project.build.finalName}.jar diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/CancellationException.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/CancellationException.java index 715bb982..4519cb85 100644 --- a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/CancellationException.java +++ b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/CancellationException.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlChecks.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlChecks.java index c5f249ee..6b32fc57 100644 --- a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlChecks.java +++ b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlChecks.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlExclusionsFileFilter.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlExclusionsFileFilter.java new file mode 100644 index 00000000..f0907905 --- /dev/null +++ b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlExclusionsFileFilter.java @@ -0,0 +1,51 @@ +/* + * Sonar ESQL Plugin + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG + * http://www.exxeta.com + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.exxeta.iss.sonar.esql; + +import org.sonar.api.batch.fs.InputFile; +import org.sonar.api.batch.fs.InputFileFilter; +import org.sonar.api.config.Configuration; +import org.sonar.api.utils.WildcardPattern; +import org.sonar.api.utils.log.Logger; +import org.sonar.api.utils.log.Loggers; + +public class EsqlExclusionsFileFilter implements InputFileFilter { + + private final Configuration configuration; + + private static final Logger LOG = Loggers.get(EsqlExclusionsFileFilter.class); + + public EsqlExclusionsFileFilter(Configuration configuration) { + this.configuration = configuration; + } + + @Override + public boolean accept(InputFile inputFile) { + if (isExcludedWithProperty(inputFile, EsqlPlugin.ESQL_EXCLUSIONS_KEY)) { + return false; + } + + return true; + } + + private boolean isExcludedWithProperty(InputFile inputFile, String property) { + String[] excludedPatterns = this.configuration.getStringArray(property); + String relativePath = inputFile.uri().toString(); + return WildcardPattern.match(WildcardPattern.create(excludedPatterns), relativePath); + } +} diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlLanguage.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlLanguage.java index c1ac0dd3..d313efc0 100644 --- a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlLanguage.java +++ b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlLanguage.java @@ -1,14 +1,14 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -17,37 +17,26 @@ */ package com.exxeta.iss.sonar.esql; -import org.apache.commons.lang.StringUtils; import org.sonar.api.config.Configuration; import org.sonar.api.resources.AbstractLanguage; public class EsqlLanguage extends AbstractLanguage { - public static final String KEY = "esql"; - - private Configuration configuration; - - public EsqlLanguage(Configuration configuration) { - super(KEY, "Esql"); - this.configuration = configuration; - } - - @Override - public String[] getFileSuffixes() { - String[] suffixes = configuration.getStringArray(EsqlPlugin.FILE_SUFFIXES_KEY); - if (suffixes == null || suffixes.length == 0) { - suffixes = StringUtils.split(EsqlPlugin.FILE_SUFFIXES_DEFVALUE, ","); - } - return suffixes; - } - - @Override - public boolean equals(Object o) { - return super.equals(o); - } - - @Override - public int hashCode() { - return super.hashCode(); - } + public static final String KEY = "esql"; + + static final String FILE_SUFFIXES_KEY = "sonar.esql.file.suffixes"; + static final String FILE_SUFFIXES_DEFVALUE = ".esql"; + + private Configuration configuration; + + public EsqlLanguage(Configuration configuration) { + super(KEY, "Esql"); + this.configuration = configuration; + } + + @Override + public String[] getFileSuffixes() { + return configuration.getStringArray(FILE_SUFFIXES_KEY); + } + } diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlPlugin.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlPlugin.java index c97b45f1..000a3f55 100644 --- a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlPlugin.java +++ b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlPlugin.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -30,32 +30,34 @@ public class EsqlPlugin implements Plugin { private static final String ESQL_CATEGORY = "Esql"; // Global ESQL constants - public static final String FALSE = "false"; - - public static final String FILE_SUFFIXES_KEY = "sonar.esql.file.suffixes"; - public static final String FILE_SUFFIXES_DEFVALUE = ".esql"; - public static final String PROPERTY_PREFIX = "sonar.esql"; - public static final String TEST_FRAMEWORK_KEY = PROPERTY_PREFIX + ".testframework"; - public static final String TEST_FRAMEWORK_DEFAULT = ""; public static final String IGNORE_HEADER_COMMENTS = PROPERTY_PREFIX + ".ignoreHeaderComments"; public static final Boolean IGNORE_HEADER_COMMENTS_DEFAULT_VALUE = true; - + public static final String ESQL_EXCLUSIONS_KEY = PROPERTY_PREFIX + ".exclusions"; + public static final String ESQL_EXCLUSIONS_DEFAULT_VALUE = ""; + public static final String TRACE_PATHS_PROPERTY = "sonar.esql.trace.reportPaths"; public static final String TRACE_PATHS_DEFAULT_VALUE = "target/iibTrace"; + public static final String FILE_SUFFIXES_NAME = "File Suffixes"; + public static final String FILE_SUFFIXES_DESCRIPTION = "List of suffixes for files to analyze."; @Override public void define(Context context) { - context.addExtensions(EsqlLanguage.class, EsqlSquidSensor.class, - new EsqlRulesDefinition(context.getSonarQubeVersion()), EsqlProfile.class, EsqlMetrics.class); + context.addExtensions( + EsqlLanguage.class, + EsqlSensor.class, + EsqlExclusionsFileFilter.class, + EsqlRulesDefinition.class, + EsqlProfilesDefinition.class, + EsqlMetrics.class); context.addExtensions( - PropertyDefinition.builder(FILE_SUFFIXES_KEY) - .defaultValue(FILE_SUFFIXES_DEFVALUE) - .name("File Suffixes") - .description("List of suffixes for files to analyze.") + PropertyDefinition.builder(EsqlLanguage.FILE_SUFFIXES_KEY) + .defaultValue(EsqlLanguage.FILE_SUFFIXES_DEFVALUE) + .name(FILE_SUFFIXES_NAME) + .description(FILE_SUFFIXES_DESCRIPTION) .subCategory(GENERAL) .category(ESQL_CATEGORY) .multiValues(true) @@ -66,20 +68,31 @@ public void define(Context context) { .defaultValue(EsqlPlugin.IGNORE_HEADER_COMMENTS_DEFAULT_VALUE.toString()) .name("Ignore header comments") .description("True to not count file header comments in comment metrics.") - .onQualifiers(Qualifiers.MODULE, Qualifiers.PROJECT) + .onQualifiers(Qualifiers.PROJECT) .subCategory(GENERAL) .category(ESQL_CATEGORY) .type(PropertyType.BOOLEAN) .build(), + PropertyDefinition.builder(TRACE_PATHS_PROPERTY) .defaultValue(TRACE_PATHS_DEFAULT_VALUE) .category("Esql") .subCategory("Trace") .name("IIB trace file") .description("Path to the IIB trace files containing coverage data. The path may be absolute or relative to the project base directory.") - .onQualifiers(Qualifiers.PROJECT, Qualifiers.MODULE) + .onQualifiers(Qualifiers.PROJECT) .multiValues(true) - .build() + .build(), + + PropertyDefinition.builder(EsqlPlugin.ESQL_EXCLUSIONS_KEY) + .defaultValue(ESQL_EXCLUSIONS_DEFAULT_VALUE) + .name("ESQL Exclusions") + .description("List of file path patterns to be excluded from analysis of ESQL files.") + .onQualifiers(Qualifiers.PROJECT) + .subCategory(GENERAL) + .multiValues(true) + .category(ESQL_CATEGORY) + .build() ); } diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlProfile.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlProfile.java deleted file mode 100644 index 4be1cfe3..00000000 --- a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlProfile.java +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG - * http://www.exxeta.com - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.exxeta.iss.sonar.esql; - -import org.sonar.api.profiles.ProfileDefinition; -import org.sonar.api.profiles.RulesProfile; -import org.sonar.api.rules.Rule; -import org.sonar.api.rules.RuleFinder; -import org.sonar.api.utils.ValidationMessages; - -import com.exxeta.iss.sonar.esql.check.CheckList; - -public class EsqlProfile extends ProfileDefinition { - - public static final String PROFILE_NAME = "Sonar way"; - public static final String PATH_TO_JSON = "/org/sonar/l10n/esql/rules/esql/Sonar_way_profile.json"; - - private final RuleFinder ruleFinder; - - public EsqlProfile(RuleFinder ruleFinder) { - this.ruleFinder = ruleFinder; - } - - @Override - public RulesProfile createProfile(ValidationMessages messages) { - RulesProfile profile = RulesProfile.create(CheckList.SONAR_WAY_PROFILE, EsqlLanguage.KEY); - - loadFromCommonRepository(profile); - loadActiveKeysFromJsonProfile(profile); - return profile; - } - - private void loadFromCommonRepository(RulesProfile profile) { - Rule duplicatedBlocksRule = ruleFinder.findByKey("common-" + EsqlLanguage.KEY, "DuplicatedBlocks"); - // in SonarLint duplicatedBlocksRule == null - if (duplicatedBlocksRule != null) { - profile.activateRule(duplicatedBlocksRule, null); - } - } - - private void loadActiveKeysFromJsonProfile(RulesProfile rulesProfile) { - for (String ruleKey : JsonProfileReader.ruleKeys(PATH_TO_JSON)) { - Rule rule = ruleFinder.findByKey(CheckList.REPOSITORY_KEY, ruleKey); - if (rule==null){ - System.err.println("Cannot load rule: "+ruleKey); - } - rulesProfile.activateRule(rule, null); - } - } - -} diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlProfilesDefinition.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlProfilesDefinition.java new file mode 100644 index 00000000..d1b16258 --- /dev/null +++ b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlProfilesDefinition.java @@ -0,0 +1,73 @@ +/* + * Sonar ESQL Plugin + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG + * http://www.exxeta.com + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.exxeta.iss.sonar.esql; + +import com.exxeta.iss.sonar.esql.check.CheckList; +import org.sonar.api.server.profile.BuiltInQualityProfilesDefinition; +import org.sonar.check.Rule; +import org.sonarsource.analyzer.commons.BuiltInQualityProfileJsonLoader; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.stream.Collectors; + +public class EsqlProfilesDefinition implements BuiltInQualityProfilesDefinition { + static final String SONAR_WAY = "Sonar way"; + + public static final String RESOURCE_PATH = "org/sonar/l10n/esql/rules/esql"; + public static final String SONAR_WAY_JSON = RESOURCE_PATH + "/Sonar_way_profile.json"; + + private static final Map PROFILES = new HashMap<>(); + + static { + PROFILES.put(SONAR_WAY, SONAR_WAY_JSON); + } + + private static final Map REPO_BY_LANGUAGE = new HashMap<>(); + + static { + REPO_BY_LANGUAGE.put(EsqlLanguage.KEY, CheckList.REPOSITORY_KEY); + } + + @Override + public void define(Context context) { + Set javaScriptRuleKeys = ruleKeys(CheckList.getChecks()); + createProfile(SONAR_WAY, EsqlLanguage.KEY, javaScriptRuleKeys, context); + } + + private static void createProfile(String profileName, String language, Set keys, Context context) { + NewBuiltInQualityProfile newProfile = context.createBuiltInQualityProfile(profileName, language); + String jsonProfilePath = PROFILES.get(profileName); + String repositoryKey = REPO_BY_LANGUAGE.get(language); + Set activeKeysForBothLanguages = BuiltInQualityProfileJsonLoader.loadActiveKeysFromJsonProfile(jsonProfilePath); + + keys.stream() + .filter(activeKeysForBothLanguages::contains) + .forEach(key -> newProfile.activateRule(repositoryKey, key)); + + newProfile.done(); + } + + private static Set ruleKeys(List checks) { + return checks.stream() + .map(c -> ((Rule) c.getAnnotation(Rule.class)).key()) + .collect(Collectors.toSet()); + } +} diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlRulesDefinition.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlRulesDefinition.java index 989a42ef..b8a15454 100644 --- a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlRulesDefinition.java +++ b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlRulesDefinition.java @@ -1,14 +1,14 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -17,120 +17,30 @@ */ package com.exxeta.iss.sonar.esql; -import java.io.IOException; -import java.net.URL; -import java.util.Locale; -import java.util.Set; - -import javax.annotation.Nullable; - -import org.sonar.api.rule.RuleStatus; -import org.sonar.api.rules.RuleType; -import org.sonar.api.server.debt.DebtRemediationFunction; -import org.sonar.api.server.rule.RulesDefinition; -import org.sonar.api.utils.Version; -import org.sonar.squidbridge.annotations.AnnotationBasedRulesDefinition; - import com.exxeta.iss.sonar.esql.check.CheckList; -import com.google.common.base.Charsets; -import com.google.common.io.Resources; -import com.google.gson.Gson; +import org.sonar.api.server.rule.RulesDefinition; +import org.sonarsource.analyzer.commons.RuleMetadataLoader; public class EsqlRulesDefinition implements RulesDefinition { - private final Gson gson = new Gson(); - private final Version sonarRuntimeVersion; - - public EsqlRulesDefinition(Version sonarRuntimeVersion) { - this.sonarRuntimeVersion = sonarRuntimeVersion; - } - - @Override - public void define(Context context) { - NewRepository repository = context - .createRepository(CheckList.REPOSITORY_KEY, EsqlLanguage.KEY) - .setName(CheckList.REPOSITORY_NAME); - - new AnnotationBasedRulesDefinition(repository, EsqlLanguage.KEY) - .addRuleClasses(/* don't fail if no SQALE annotations */ false, CheckList.getChecks()); + private static final String METADATA_LOCATION = "org/sonar/l10n/esql/rules/esql"; - for (NewRule rule : repository.rules()) { - String metadataKey = rule.key(); - // Setting internal key is essential for rule templates (see SONAR-6162), and it is not done by AnnotationBasedRulesDefinition from sslr-squid-bridge version 2.5.1: - rule.setInternalKey(metadataKey); - rule.setHtmlDescription(readRuleDefinitionResource(metadataKey + ".html")); - addMetadata(rule, metadataKey); - } - - boolean shouldSetupSonarLintProfile = sonarRuntimeVersion.isGreaterThanOrEqual(Version.parse("6.0")); - if (shouldSetupSonarLintProfile) { - Set activatedRuleKeys = JsonProfileReader.ruleKeys(EsqlProfile.PATH_TO_JSON); - for (NewRule rule : repository.rules()) { - rule.setActivatedByDefault(activatedRuleKeys.contains(rule.key())); - } - } + @Override + public void define(Context context) { + NewRepository repository = context + .createRepository(CheckList.REPOSITORY_KEY, EsqlLanguage.KEY) + .setName(CheckList.REPOSITORY_NAME); - repository.done(); - } - - @Nullable - private static String readRuleDefinitionResource(String fileName) { - URL resource = EsqlRulesDefinition.class.getResource("/org/sonar/l10n/esql/rules/esql/" + fileName); - if (resource == null) { - return null; - } - try { - return Resources.toString(resource, Charsets.UTF_8); - } catch (IOException e) { - throw new IllegalStateException("Failed to read: " + resource, e); - } - } + RuleMetadataLoader ruleMetadataLoader = new RuleMetadataLoader(METADATA_LOCATION, EsqlProfilesDefinition.SONAR_WAY_JSON); + ruleMetadataLoader.addRulesByAnnotatedClass(repository, CheckList.getChecks()); + NewRule commentRegularExpression = repository.rule("CommentRegularExpression"); + if (commentRegularExpression != null) { + commentRegularExpression.setTemplate(true); + } - private void addMetadata(NewRule rule, String metadataKey) { - String json = readRuleDefinitionResource(metadataKey + ".json"); - if (json != null) { - RuleMetadata metadata = gson.fromJson(json, RuleMetadata.class); - rule.setSeverity(metadata.defaultSeverity.toUpperCase(Locale.US)); - rule.setName(metadata.title); - rule.setTags(metadata.tags); - rule.setType(RuleType.valueOf(metadata.type)); - rule.setStatus(RuleStatus.valueOf(metadata.status.toUpperCase(Locale.US))); - if (metadata.remediation != null) { - // metadata.remediation is null for template rules - rule.setDebtRemediationFunction(metadata.remediation.remediationFunction(rule.debtRemediationFunctions())); - rule.setGapDescription(metadata.remediation.linearDesc); - } + repository.done(); } - } - - private static class RuleMetadata { - String title; - String status; - String type; - @Nullable - Remediation remediation; - - String[] tags; - String defaultSeverity; - } - private static class Remediation { - String func; - String constantCost; - String linearDesc; - String linearOffset; - String linearFactor; - - private DebtRemediationFunction remediationFunction(DebtRemediationFunctions drf) { - if (func.startsWith("Constant")) { - return drf.constantPerIssue(constantCost.replace("mn", "min")); - } - if ("Linear".equals(func)) { - return drf.linear(linearFactor.replace("mn", "min")); - } - return drf.linearWithOffset(linearFactor.replace("mn", "min"), linearOffset.replace("mn", "min")); - } - } } diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlSensor.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlSensor.java new file mode 100644 index 00000000..5a29b2c2 --- /dev/null +++ b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlSensor.java @@ -0,0 +1,393 @@ +/* + * Sonar ESQL Plugin + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG + * http://www.exxeta.com + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.exxeta.iss.sonar.esql; + +import com.exxeta.iss.sonar.esql.api.CustomEsqlRulesDefinition; +import com.exxeta.iss.sonar.esql.api.EsqlCheck; +import com.exxeta.iss.sonar.esql.api.tree.ProgramTree; +import com.exxeta.iss.sonar.esql.api.tree.Tree; +import com.exxeta.iss.sonar.esql.api.visitors.EsqlVisitorContext; +import com.exxeta.iss.sonar.esql.api.visitors.FileIssue; +import com.exxeta.iss.sonar.esql.api.visitors.Issue; +import com.exxeta.iss.sonar.esql.api.visitors.IssueLocation; +import com.exxeta.iss.sonar.esql.api.visitors.LineIssue; +import com.exxeta.iss.sonar.esql.api.visitors.PreciseIssue; +import com.exxeta.iss.sonar.esql.api.visitors.TreeVisitor; +import com.exxeta.iss.sonar.esql.api.visitors.TreeVisitorContext; +import com.exxeta.iss.sonar.esql.check.CheckList; +import com.exxeta.iss.sonar.esql.check.ParsingErrorCheck; +import com.exxeta.iss.sonar.esql.codecoverage.TraceSensor; +import com.exxeta.iss.sonar.esql.cpd.CpdVisitor; +import com.exxeta.iss.sonar.esql.highlighter.HighlightSymbolTableBuilder; +import com.exxeta.iss.sonar.esql.highlighter.HighlighterVisitor; +import com.exxeta.iss.sonar.esql.metrics.MetricsVisitor; +import com.exxeta.iss.sonar.esql.metrics.NoSonarVisitor; +import com.exxeta.iss.sonar.esql.parser.EsqlParserBuilder; +import com.google.common.annotations.VisibleForTesting; +import com.google.common.base.Preconditions; +import com.google.common.base.Throwables; +import com.google.common.collect.Lists; +import com.sonar.sslr.api.RecognitionException; +import com.sonar.sslr.api.typed.ActionParser; +import org.sonar.api.batch.InstantiationStrategy; +import org.sonar.api.batch.fs.FilePredicate; +import org.sonar.api.batch.fs.FileSystem; +import org.sonar.api.batch.fs.InputFile; +import org.sonar.api.batch.fs.InputFile.Type; +import org.sonar.api.batch.fs.TextRange; +import org.sonar.api.batch.rule.CheckFactory; +import org.sonar.api.batch.sensor.Sensor; +import org.sonar.api.batch.sensor.SensorContext; +import org.sonar.api.batch.sensor.SensorDescriptor; +import org.sonar.api.batch.sensor.issue.NewIssue; +import org.sonar.api.batch.sensor.issue.NewIssueLocation; +import org.sonar.api.batch.sensor.symbol.NewSymbolTable; +import org.sonar.api.config.Configuration; +import org.sonar.api.issue.NoSonarFilter; +import org.sonar.api.measures.FileLinesContextFactory; +import org.sonar.api.rule.RuleKey; +import org.sonar.api.scanner.ScannerSide; +import org.sonar.api.utils.log.Logger; +import org.sonar.api.utils.log.Loggers; +import org.sonar.squidbridge.ProgressReport; + +import javax.annotation.Nullable; +import java.io.InterruptedIOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.concurrent.TimeUnit; +import java.util.stream.Collectors; +import java.util.stream.StreamSupport; + +@ScannerSide +@InstantiationStrategy(InstantiationStrategy.PER_PROJECT) +public class EsqlSensor implements Sensor { + + private static final Logger LOG = Loggers.get(EsqlSensor.class); + + private final EsqlChecks checks; + private final FileLinesContextFactory fileLinesContextFactory; + private final FileSystem fileSystem; + private final NoSonarFilter noSonarFilter; + private final FilePredicate mainFilePredicate; + private final ActionParser parser; + // parsingErrorRuleKey equals null if ParsingErrorCheck is not activated + private RuleKey parsingErrorRuleKey = null; + + public EsqlSensor( + CheckFactory checkFactory, FileLinesContextFactory fileLinesContextFactory, FileSystem fileSystem, NoSonarFilter noSonarFilter) { + this(checkFactory, fileLinesContextFactory, fileSystem, noSonarFilter, null); + } + + + public EsqlSensor( + CheckFactory checkFactory, FileLinesContextFactory fileLinesContextFactory, FileSystem fileSystem, NoSonarFilter noSonarFilter, + @Nullable CustomEsqlRulesDefinition[] customRulesDefinition + ) { + + this.checks = EsqlChecks.createEsqlCheck(checkFactory) + .addChecks(CheckList.REPOSITORY_KEY, CheckList.getChecks()) + .addCustomChecks(customRulesDefinition); + this.fileLinesContextFactory = fileLinesContextFactory; + this.fileSystem = fileSystem; + this.noSonarFilter = noSonarFilter; + this.mainFilePredicate = fileSystem.predicates().and( + fileSystem.predicates().hasType(InputFile.Type.MAIN), + fileSystem.predicates().hasLanguage(EsqlLanguage.KEY)); + this.parser = EsqlParserBuilder.createParser(); + } + + @VisibleForTesting + protected void analyseFiles( + SensorContext context, List treeVisitors, Iterable inputFiles, + ProgressReport progressReport + ) { + boolean success = false; + try { + for (InputFile inputFile : inputFiles) { + // check for cancellation of the analysis (by SonarQube or SonarLint). See SONARJS-761. + if (context.isCancelled()) { + throw new CancellationException("Analysis interrupted because the SensorContext is in cancelled state"); + } + analyse(context, inputFile, treeVisitors); + progressReport.nextFile(); + } + success = true; + } catch (CancellationException e) { + // do not propagate the exception + LOG.debug(e.toString(), e); + } finally { + stopProgressReport(progressReport, success); + } + } + + private static void stopProgressReport(ProgressReport progressReport, boolean success) { + if (success) { + progressReport.stop(); + } else { + progressReport.cancel(); + } + } + + private void analyse(SensorContext sensorContext, InputFile inputFile, List visitors) { + ProgramTree programTree; + + try { + programTree = (ProgramTree) parser.parse(inputFile.contents()); + scanFile(sensorContext, inputFile, visitors, programTree); + } catch (RecognitionException e) { + checkInterrupted(e); + LOG.error("Unable to parse file: " + inputFile.uri()); + LOG.error(e.getMessage()); + processRecognitionException(e, sensorContext, inputFile); + } catch (Exception e) { + checkInterrupted(e); + processException(e, sensorContext, inputFile); + LOG.error("Unable to analyse file: " + inputFile.uri(), e); + } + } + + private static void checkInterrupted(Exception e) { + Throwable cause = Throwables.getRootCause(e); + if (cause instanceof InterruptedException || cause instanceof InterruptedIOException) { + throw new AnalysisException("Analysis cancelled", e); + } + } + + private void processRecognitionException(RecognitionException e, SensorContext sensorContext, InputFile inputFile) { + if (parsingErrorRuleKey != null) { + NewIssue newIssue = sensorContext.newIssue(); + + NewIssueLocation primaryLocation = newIssue.newLocation() + .message(ParsingErrorCheck.MESSAGE) + .on(inputFile) + .at(inputFile.selectLine(e.getLine())); + + newIssue + .forRule(parsingErrorRuleKey) + .at(primaryLocation) + .save(); + } + + sensorContext.newAnalysisError() + .onFile(inputFile) + .at(inputFile.newPointer(e.getLine(), 0)) + .message(e.getMessage()) + .save(); + } + + private static void processException(Exception e, SensorContext sensorContext, InputFile inputFile) { + sensorContext.newAnalysisError() + .onFile(inputFile) + .message(e.getMessage()) + .save(); + } + + private void scanFile(SensorContext sensorContext, InputFile inputFile, List visitors, ProgramTree programTree) { + LOG.debug("scanning file " + inputFile.filename()); + EsqlVisitorContext context = new EsqlVisitorContext(programTree, inputFile, sensorContext.config()); + + List fileIssues = new ArrayList<>(); + + for (TreeVisitor visitor : visitors) { + if (visitor instanceof EsqlCheck) { + fileIssues.addAll(((EsqlCheck) visitor).scanFile(context)); + } else { + visitor.scanTree(context); + } + } + + saveFileIssues(sensorContext, fileIssues, inputFile); + highlightSymbols(inputFile, context, sensorContext); + } + + private void saveFileIssues(SensorContext sensorContext, List fileIssues, InputFile inputFile) { + for (Issue issue : fileIssues) { + RuleKey ruleKey = ruleKey(issue.check()); + if (issue instanceof FileIssue) { + saveFileIssue(sensorContext, inputFile, ruleKey, (FileIssue) issue); + } else if (issue instanceof LineIssue) { + saveLineIssue(sensorContext, inputFile, ruleKey, (LineIssue) issue); + } else { + savePreciseIssue(sensorContext, inputFile, ruleKey, (PreciseIssue) issue); + } + } + } + + private static void savePreciseIssue(SensorContext sensorContext, InputFile inputFile, RuleKey ruleKey, PreciseIssue issue) { + NewIssue newIssue = sensorContext.newIssue(); + + newIssue + .forRule(ruleKey) + .at(newLocation(inputFile, newIssue, issue.primaryLocation())); + + if (issue.cost() != null) { + newIssue.gap(issue.cost()); + } + + for (IssueLocation secondary : issue.secondaryLocations()) { + newIssue.addLocation(newLocation(inputFile, newIssue, secondary)); + } + newIssue.save(); + } + + private static NewIssueLocation newLocation(InputFile inputFile, NewIssue issue, IssueLocation location) { + TextRange range = inputFile.newRange( + location.startLine(), location.startLineOffset(), location.endLine(), location.endLineOffset()); + + NewIssueLocation newLocation = issue.newLocation() + .on(inputFile) + .at(range); + + if (location.message() != null) { + newLocation.message(location.message()); + } + return newLocation; + } + + private RuleKey ruleKey(EsqlCheck check) { + Preconditions.checkNotNull(check); + RuleKey ruleKey = checks.ruleKeyFor(check); + if (ruleKey == null) { + throw new IllegalStateException("No rule key found for a rule"); + } + return ruleKey; + } + + @Override + public void describe(SensorDescriptor descriptor) { + descriptor + .onlyOnLanguage(EsqlLanguage.KEY) + .name("ESQL Squid Sensor") + .onlyOnFileType(Type.MAIN); + } + + public void execute(SensorContext context) { + LOG.warn("ESQL sensor execute"); + List treeVisitors = Lists.newArrayList(); + treeVisitors.addAll(getTreeVisitors(context)); + treeVisitors.addAll(checks.visitorChecks()); + + for (TreeVisitor check : treeVisitors) { + if (check instanceof ParsingErrorCheck) { + parsingErrorRuleKey = checks.ruleKeyFor((EsqlCheck) check); + break; + } + } + + Iterable inputFiles = fileSystem.inputFiles(mainFilePredicate); + Collection files = StreamSupport.stream(inputFiles.spliterator(), false) + .map(InputFile::toString) + .collect(Collectors.toList()); + + ProgressReport progressReport = new ProgressReport("Report about progress of ESQL analyzer", TimeUnit.SECONDS.toMillis(10)); + progressReport.start(files); + + analyseFiles(context, treeVisitors, inputFiles, progressReport); + + executeCoverageSensors(context); + } + + + public List getTreeVisitors(SensorContext context) { + boolean ignoreHeaderComments = ignoreHeaderComments(context); + + MetricsVisitor metricsVisitor = new MetricsVisitor( + context, + ignoreHeaderComments, + fileLinesContextFactory); + return Arrays.asList( + metricsVisitor, + new NoSonarVisitor(noSonarFilter, ignoreHeaderComments), + new HighlighterVisitor(context), + new CpdVisitor(context)); + } + + public void highlightSymbols(InputFile inputFile, TreeVisitorContext treeVisitorContext, SensorContext context) { + NewSymbolTable newSymbolTable = context.newSymbolTable().onFile(inputFile); + HighlightSymbolTableBuilder.build(newSymbolTable, treeVisitorContext); + } + + public void executeCoverageSensors(SensorContext context) { + boolean ignoreHeaderComments = ignoreHeaderComments(context); + + MetricsVisitor metricsVisitor = new MetricsVisitor( + context, + ignoreHeaderComments, + fileLinesContextFactory); + + executeCoverageSensors(context, metricsVisitor.executableLines()); + } + + private static void executeCoverageSensors(SensorContext context, Map> executableLines) { + Configuration configuration = context.config(); + + String[] traces = configuration.getStringArray(EsqlPlugin.TRACE_PATHS_PROPERTY); + + (new TraceSensor()).execute(context, executableLines, traces); + + } + + private static boolean ignoreHeaderComments(SensorContext context) { + return context.config().getBoolean(EsqlPlugin.IGNORE_HEADER_COMMENTS).orElse(EsqlPlugin.IGNORE_HEADER_COMMENTS_DEFAULT_VALUE); + } + + private static void saveLineIssue(SensorContext sensorContext, InputFile inputFile, RuleKey ruleKey, LineIssue issue) { + NewIssue newIssue = sensorContext.newIssue(); + + NewIssueLocation primaryLocation = newIssue.newLocation() + .message(issue.message()) + .on(inputFile) + .at(inputFile.selectLine(issue.line())); + + saveIssue(newIssue, primaryLocation, ruleKey, issue); + } + + private static void saveFileIssue(SensorContext sensorContext, InputFile inputFile, RuleKey ruleKey, FileIssue issue) { + NewIssue newIssue = sensorContext.newIssue(); + + NewIssueLocation primaryLocation = newIssue.newLocation() + .message(issue.message()) + .on(inputFile); + + saveIssue(newIssue, primaryLocation, ruleKey, issue); + } + + private static void saveIssue(NewIssue newIssue, NewIssueLocation primaryLocation, RuleKey ruleKey, Issue issue) { + newIssue + .forRule(ruleKey) + .at(primaryLocation); + + if (issue.cost() != null) { + newIssue.gap(issue.cost()); + } + + newIssue.save(); + } + + static class AnalysisException extends RuntimeException { + AnalysisException(String message, Throwable cause) { + super(message, cause); + } + } + +} diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlSquidSensor.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlSquidSensor.java deleted file mode 100644 index 152b5101..00000000 --- a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/EsqlSquidSensor.java +++ /dev/null @@ -1,441 +0,0 @@ -/* - * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG - * http://www.exxeta.com - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.exxeta.iss.sonar.esql; - -import java.io.File; -import java.io.InterruptedIOException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Collection; -import java.util.Collections; -import java.util.List; -import java.util.Map; -import java.util.Set; -import java.util.concurrent.TimeUnit; -import java.util.stream.Collectors; -import java.util.stream.StreamSupport; - -import javax.annotation.Nullable; - -import org.sonar.api.SonarProduct; -import org.sonar.api.batch.fs.FilePredicate; -import org.sonar.api.batch.fs.FileSystem; -import org.sonar.api.batch.fs.InputFile; -import org.sonar.api.batch.fs.InputFile.Type; -import org.sonar.api.batch.fs.TextRange; -import org.sonar.api.batch.rule.CheckFactory; -import org.sonar.api.batch.sensor.Sensor; -import org.sonar.api.batch.sensor.SensorContext; -import org.sonar.api.batch.sensor.SensorDescriptor; -import org.sonar.api.batch.sensor.issue.NewIssue; -import org.sonar.api.batch.sensor.issue.NewIssueLocation; -import org.sonar.api.batch.sensor.symbol.NewSymbolTable; -import org.sonar.api.config.Configuration; -import org.sonar.api.issue.NoSonarFilter; -import org.sonar.api.measures.FileLinesContextFactory; -import org.sonar.api.rule.RuleKey; -import org.sonar.api.utils.log.Logger; -import org.sonar.api.utils.log.Loggers; -import org.sonar.squidbridge.ProgressReport; -import org.sonar.squidbridge.api.AnalysisException; - -import com.exxeta.iss.sonar.esql.api.CustomEsqlRulesDefinition; -import com.exxeta.iss.sonar.esql.api.EsqlCheck; -import com.exxeta.iss.sonar.esql.api.tree.ProgramTree; -import com.exxeta.iss.sonar.esql.api.tree.Tree; -import com.exxeta.iss.sonar.esql.api.visitors.EsqlVisitorContext; -import com.exxeta.iss.sonar.esql.api.visitors.FileIssue; -import com.exxeta.iss.sonar.esql.api.visitors.Issue; -import com.exxeta.iss.sonar.esql.api.visitors.IssueLocation; -import com.exxeta.iss.sonar.esql.api.visitors.LineIssue; -import com.exxeta.iss.sonar.esql.api.visitors.PreciseIssue; -import com.exxeta.iss.sonar.esql.api.visitors.TreeVisitor; -import com.exxeta.iss.sonar.esql.api.visitors.TreeVisitorContext; -import com.exxeta.iss.sonar.esql.check.CheckList; -import com.exxeta.iss.sonar.esql.check.ParsingErrorCheck; -import com.exxeta.iss.sonar.esql.codecoverage.TraceSensor; -import com.exxeta.iss.sonar.esql.cpd.CpdVisitor; -import com.exxeta.iss.sonar.esql.highlighter.HighlightSymbolTableBuilder; -import com.exxeta.iss.sonar.esql.highlighter.HighlighterVisitor; -import com.exxeta.iss.sonar.esql.metrics.MetricsVisitor; -import com.exxeta.iss.sonar.esql.metrics.NoSonarVisitor; -import com.exxeta.iss.sonar.esql.parser.EsqlParserBuilder; -import com.google.common.annotations.VisibleForTesting; -import com.google.common.base.Preconditions; -import com.google.common.base.Throwables; -import com.google.common.collect.Lists; -import com.sonar.sslr.api.RecognitionException; -import com.sonar.sslr.api.typed.ActionParser; - -public class EsqlSquidSensor implements Sensor { - - private static final Logger LOG = Loggers.get(EsqlSquidSensor.class); - - private final EsqlChecks checks; - private final FileLinesContextFactory fileLinesContextFactory; - private final FileSystem fileSystem; - private final NoSonarFilter noSonarFilter; - private final FilePredicate mainFilePredicate; - private final ActionParser parser; - // parsingErrorRuleKey equals null if ParsingErrorCheck is not activated - private RuleKey parsingErrorRuleKey = null; - - public EsqlSquidSensor( - CheckFactory checkFactory, FileLinesContextFactory fileLinesContextFactory, FileSystem fileSystem, NoSonarFilter noSonarFilter) { - this(checkFactory, fileLinesContextFactory, fileSystem, noSonarFilter, null); - } - - public EsqlSquidSensor( - CheckFactory checkFactory, FileLinesContextFactory fileLinesContextFactory, FileSystem fileSystem, NoSonarFilter noSonarFilter, - @Nullable CustomEsqlRulesDefinition[] customRulesDefinition - ) { - - this.checks = EsqlChecks.createEsqlCheck(checkFactory) - .addChecks(CheckList.REPOSITORY_KEY, CheckList.getChecks()) - .addCustomChecks(customRulesDefinition); - this.fileLinesContextFactory = fileLinesContextFactory; - this.fileSystem = fileSystem; - this.noSonarFilter = noSonarFilter; - this.mainFilePredicate = fileSystem.predicates().and( - fileSystem.predicates().hasType(InputFile.Type.MAIN), - fileSystem.predicates().hasLanguage(EsqlLanguage.KEY)); - this.parser = EsqlParserBuilder.createParser(); - } - - @VisibleForTesting - protected void analyseFiles( - SensorContext context, List treeVisitors, Iterable inputFiles, - ProductDependentExecutor executor, ProgressReport progressReport - ) { - boolean success = false; - try { - for (InputFile inputFile : inputFiles) { - // check for cancellation of the analysis (by SonarQube or SonarLint). See SONARJS-761. - if (context.isCancelled()) { - throw new CancellationException("Analysis interrupted because the SensorContext is in cancelled state"); - } - analyse(context, inputFile, executor, treeVisitors); - progressReport.nextFile(); - } - success = true; - } catch (CancellationException e) { - // do not propagate the exception - LOG.debug(e.toString(), e); - } finally { - stopProgressReport(progressReport, success); - } - } - - private static void stopProgressReport(ProgressReport progressReport, boolean success) { - if (success) { - progressReport.stop(); - } else { - progressReport.cancel(); - } - } - - private void analyse(SensorContext sensorContext, InputFile inputFile, ProductDependentExecutor executor, List visitors) { - ProgramTree programTree; - - try { - programTree = (ProgramTree) parser.parse(inputFile.contents()); - scanFile(sensorContext, inputFile, executor, visitors, programTree); - } catch (RecognitionException e) { - checkInterrupted(e); - LOG.error("Unable to parse file: " + inputFile.uri()); - LOG.error(e.getMessage()); - processRecognitionException(e, sensorContext, inputFile); - } catch (Exception e) { - checkInterrupted(e); - processException(e, sensorContext, inputFile); - throw new AnalysisException("Unable to analyse file: " + inputFile.uri(), e); - } - } - - private static void checkInterrupted(Exception e) { - Throwable cause = Throwables.getRootCause(e); - if (cause instanceof InterruptedException || cause instanceof InterruptedIOException) { - throw new AnalysisException("Analysis cancelled", e); - } - } - - private void processRecognitionException(RecognitionException e, SensorContext sensorContext, InputFile inputFile) { - if (parsingErrorRuleKey != null) { - NewIssue newIssue = sensorContext.newIssue(); - - NewIssueLocation primaryLocation = newIssue.newLocation() - .message(ParsingErrorCheck.MESSAGE) - .on(inputFile) - .at(inputFile.selectLine(e.getLine())); - - newIssue - .forRule(parsingErrorRuleKey) - .at(primaryLocation) - .save(); - } - - sensorContext.newAnalysisError() - .onFile(inputFile) - .at(inputFile.newPointer(e.getLine(), 0)) - .message(e.getMessage()) - .save(); - } - - private static void processException(Exception e, SensorContext sensorContext, InputFile inputFile) { - sensorContext.newAnalysisError() - .onFile(inputFile) - .message(e.getMessage()) - .save(); - } - - private void scanFile(SensorContext sensorContext, InputFile inputFile, ProductDependentExecutor executor, List visitors, ProgramTree programTree) { - EsqlVisitorContext context = new EsqlVisitorContext(programTree, inputFile, sensorContext.config()); - - List fileIssues = new ArrayList<>(); - - for (TreeVisitor visitor : visitors) { - if (visitor instanceof EsqlCheck) { - fileIssues.addAll(((EsqlCheck) visitor).scanFile(context)); - } else { - visitor.scanTree(context); - } - } - - saveFileIssues(sensorContext, fileIssues, inputFile); - executor.highlightSymbols(inputFile, context); - } - - private void saveFileIssues(SensorContext sensorContext, List fileIssues, InputFile inputFile) { - for (Issue issue : fileIssues) { - RuleKey ruleKey = ruleKey(issue.check()); - if (issue instanceof FileIssue) { - saveFileIssue(sensorContext, inputFile, ruleKey, (FileIssue) issue); - } else if (issue instanceof LineIssue) { - saveLineIssue(sensorContext, inputFile, ruleKey, (LineIssue) issue); - } else { - savePreciseIssue(sensorContext, inputFile, ruleKey, (PreciseIssue) issue); - } - } - } - - private static void savePreciseIssue(SensorContext sensorContext, InputFile inputFile, RuleKey ruleKey, PreciseIssue issue) { - NewIssue newIssue = sensorContext.newIssue(); - - newIssue - .forRule(ruleKey) - .at(newLocation(inputFile, newIssue, issue.primaryLocation())); - - if (issue.cost() != null) { - newIssue.gap(issue.cost()); - } - - for (IssueLocation secondary : issue.secondaryLocations()) { - newIssue.addLocation(newLocation(inputFile, newIssue, secondary)); - } - newIssue.save(); - } - - private static NewIssueLocation newLocation(InputFile inputFile, NewIssue issue, IssueLocation location) { - TextRange range = inputFile.newRange( - location.startLine(), location.startLineOffset(), location.endLine(), location.endLineOffset()); - - NewIssueLocation newLocation = issue.newLocation() - .on(inputFile) - .at(range); - - if (location.message() != null) { - newLocation.message(location.message()); - } - return newLocation; - } - - private RuleKey ruleKey(EsqlCheck check) { - Preconditions.checkNotNull(check); - RuleKey ruleKey = checks.ruleKeyFor(check); - if (ruleKey == null) { - throw new IllegalStateException("No rule key found for a rule"); - } - return ruleKey; - } - - - @Override - public void describe(SensorDescriptor descriptor) { - descriptor - .onlyOnLanguage(EsqlLanguage.KEY) - .name("ESQL Squid Sensor") - .onlyOnFileType(Type.MAIN); - } - - @Override - public void execute(SensorContext context) { - ProductDependentExecutor executor = createProductDependentExecutor(context); - - List treeVisitors = Lists.newArrayList(); - treeVisitors.addAll(executor.getProductDependentTreeVisitors()); - treeVisitors.addAll(checks.visitorChecks()); - - for (TreeVisitor check : treeVisitors) { - if (check instanceof ParsingErrorCheck) { - parsingErrorRuleKey = checks.ruleKeyFor((EsqlCheck) check); - break; - } - } - - Iterable inputFiles = fileSystem.inputFiles(mainFilePredicate); - Collection files = StreamSupport.stream(inputFiles.spliterator(), false) - .map(InputFile::file) - .collect(Collectors.toList()); - - ProgressReport progressReport = new ProgressReport("Report about progress of ESQL analyzer", TimeUnit.SECONDS.toMillis(10)); - progressReport.start(files); - - analyseFiles(context, treeVisitors, inputFiles, executor, progressReport); - - executor.executeCoverageSensors(); - } - - private ProductDependentExecutor createProductDependentExecutor(SensorContext context) { - if (isSonarLint(context)) { - return new SonarLintProductExecutor(); - } - return new SonarQubeProductExecutor(context, noSonarFilter, fileLinesContextFactory); - } - - @VisibleForTesting - protected interface ProductDependentExecutor { - List getProductDependentTreeVisitors(); - - void highlightSymbols(InputFile inputFile, TreeVisitorContext treeVisitorContext); - - void executeCoverageSensors(); - } - - private static class SonarQubeProductExecutor implements ProductDependentExecutor { - private final SensorContext context; - private final NoSonarFilter noSonarFilter; - private final FileLinesContextFactory fileLinesContextFactory; - private MetricsVisitor metricsVisitor; - - SonarQubeProductExecutor(SensorContext context, NoSonarFilter noSonarFilter, FileLinesContextFactory fileLinesContextFactory) { - this.context = context; - this.noSonarFilter = noSonarFilter; - this.fileLinesContextFactory = fileLinesContextFactory; - } - - @Override - public List getProductDependentTreeVisitors() { - boolean ignoreHeaderComments = ignoreHeaderComments(context); - - metricsVisitor = new MetricsVisitor( - context, - ignoreHeaderComments, - fileLinesContextFactory); - return Arrays.asList( - metricsVisitor, - new NoSonarVisitor(noSonarFilter, ignoreHeaderComments), - new HighlighterVisitor(context), - new CpdVisitor(context)); - } - - @Override - public void highlightSymbols(InputFile inputFile, TreeVisitorContext treeVisitorContext) { - NewSymbolTable newSymbolTable = context.newSymbolTable().onFile(inputFile); - HighlightSymbolTableBuilder.build(newSymbolTable, treeVisitorContext); - } - - @Override - public void executeCoverageSensors() { - if (metricsVisitor == null) { - throw new IllegalStateException("Before starting coverage computation, metrics should have been calculated."); - } - executeCoverageSensors(context, metricsVisitor.executableLines()); - } - - private static void executeCoverageSensors(SensorContext context, Map> executableLines) { - Configuration configuration = context.config(); - - String[] traces = configuration.getStringArray(EsqlPlugin.TRACE_PATHS_PROPERTY); - - (new TraceSensor()).execute(context, executableLines, traces); - - } - - } - - @VisibleForTesting - protected static class SonarLintProductExecutor implements ProductDependentExecutor { - @Override - public List getProductDependentTreeVisitors() { - return Collections.emptyList(); - } - - @Override - public void highlightSymbols(InputFile inputFile, TreeVisitorContext treeVisitorContext) { - // unnecessary in SonarLint context - } - - @Override - public void executeCoverageSensors() { - // unnecessary in SonarLint context - } - - } - - private static boolean ignoreHeaderComments(SensorContext context) { - return context.config().getBoolean(EsqlPlugin.IGNORE_HEADER_COMMENTS).orElse(EsqlPlugin.IGNORE_HEADER_COMMENTS_DEFAULT_VALUE); - } - - private static boolean isSonarLint(SensorContext context) { - return context.runtime().getProduct() == SonarProduct.SONARLINT; - } - - private static void saveLineIssue(SensorContext sensorContext, InputFile inputFile, RuleKey ruleKey, LineIssue issue) { - NewIssue newIssue = sensorContext.newIssue(); - - NewIssueLocation primaryLocation = newIssue.newLocation() - .message(issue.message()) - .on(inputFile) - .at(inputFile.selectLine(issue.line())); - - saveIssue(newIssue, primaryLocation, ruleKey, issue); - } - - private static void saveFileIssue(SensorContext sensorContext, InputFile inputFile, RuleKey ruleKey, FileIssue issue) { - NewIssue newIssue = sensorContext.newIssue(); - - NewIssueLocation primaryLocation = newIssue.newLocation() - .message(issue.message()) - .on(inputFile); - - saveIssue(newIssue, primaryLocation, ruleKey, issue); - } - - private static void saveIssue(NewIssue newIssue, NewIssueLocation primaryLocation, RuleKey ruleKey, Issue issue) { - newIssue - .forRule(ruleKey) - .at(primaryLocation); - - if (issue.cost() != null) { - newIssue.gap(issue.cost()); - } - - newIssue.save(); - } - -} diff --git a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/JsonProfileReader.java b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/JsonProfileReader.java index bcdc1209..51bfa87b 100644 --- a/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/JsonProfileReader.java +++ b/esql-plugin/src/main/java/com/exxeta/iss/sonar/esql/JsonProfileReader.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); diff --git a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlExclusionsFileFilterTest.java b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlExclusionsFileFilterTest.java new file mode 100644 index 00000000..eda6335c --- /dev/null +++ b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlExclusionsFileFilterTest.java @@ -0,0 +1,47 @@ +package com.exxeta.iss.sonar.esql; + +import org.junit.Test; +import org.sonar.api.batch.fs.internal.DefaultInputFile; +import org.sonar.api.batch.fs.internal.TestInputFileBuilder; +import org.sonar.api.config.internal.MapSettings; + +import static org.assertj.core.api.Assertions.assertThat; + + +public class EsqlExclusionsFileFilterTest { + + + @Test + public void should_exclude_using_custom_path_regex() throws Exception { + MapSettings settings = new MapSettings(); + settings.setProperty( + EsqlPlugin.ESQL_EXCLUSIONS_KEY, EsqlPlugin.ESQL_EXCLUSIONS_DEFAULT_VALUE + "," + "**/libs/**"); + + EsqlExclusionsFileFilter filter = new EsqlExclusionsFileFilter(settings.asConfig()); + + assertThat(filter.accept(inputFile("some_app.esql"))).isTrue(); + assertThat(filter.accept(inputFile("libs/some_lib.esql"))).isFalse(); + } + + @Test + public void should_ignore_empty_path_regex() throws Exception { + MapSettings settings = new MapSettings(); + settings.setProperty(EsqlPlugin.ESQL_EXCLUSIONS_KEY, "," + EsqlPlugin.ESQL_EXCLUSIONS_DEFAULT_VALUE + ","); + + EsqlExclusionsFileFilter filter = new EsqlExclusionsFileFilter(settings.asConfig()); + + assertThat(filter.accept(inputFile("some_app.esql"))).isTrue(); + } + + private DefaultInputFile inputFile(String file) { + return new TestInputFileBuilder("test","test_node_modules/" + file) + .setLanguage(language(file)) + .setContents("foo();") + .build(); + } + + private static String language(String filename) { + String[] parts = filename.split("\\."); + return parts[parts.length - 1]; + } +} diff --git a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlLanguageTest.java b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlLanguageTest.java index dc16bc87..8d823ed3 100644 --- a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlLanguageTest.java +++ b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlLanguageTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -35,14 +35,21 @@ public void setUp() { @Test public void defaultSuffixes() { - settings.setProperty(EsqlPlugin.FILE_SUFFIXES_KEY, ""); - assertThat(esqlLanguage.getFileSuffixes()).containsOnly(".esql"); + MapSettings mapSettings = new MapSettings(); + mapSettings.setProperty(EsqlLanguage.FILE_SUFFIXES_KEY, EsqlLanguage.FILE_SUFFIXES_DEFVALUE); + EsqlLanguage esqlLanguage = new EsqlLanguage(mapSettings.asConfig()); + assertThat(esqlLanguage.getFileSuffixes()).containsOnly(".esql"); + } @Test public void customSuffixes() { - settings.setProperty(EsqlPlugin.FILE_SUFFIXES_KEY, "esql"); - assertThat(esqlLanguage.getFileSuffixes()).containsOnly("esql"); + + MapSettings mapSettings = new MapSettings(); + mapSettings.setProperty(EsqlLanguage.FILE_SUFFIXES_KEY, "esql"); + EsqlLanguage esqlLanguage = new EsqlLanguage(mapSettings.asConfig()); + assertThat(esqlLanguage.getFileSuffixes()).containsOnly("esql"); + } } diff --git a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlPluginTest.java b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlPluginTest.java index b9d41d92..238ca055 100644 --- a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlPluginTest.java +++ b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlPluginTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -21,6 +21,7 @@ import java.util.List; import org.junit.Test; import org.sonar.api.Plugin; +import org.sonar.api.SonarEdition; import org.sonar.api.SonarQubeSide; import org.sonar.api.SonarRuntime; import org.sonar.api.config.PropertyDefinition; @@ -31,16 +32,9 @@ public class EsqlPluginTest { - @Test - public void count_extensions_for_sonarqube_server_5_6() throws Exception { - Plugin.Context context = setupContext(SonarRuntimeImpl.forSonarQube(Version.create(5, 6), SonarQubeSide.SERVER)); - - assertThat(context.getExtensions()).hasSize(8); - } - @Test public void should_contain_right_properties_number() throws Exception { - assertThat(properties()).hasSize(3); + assertThat(properties()).hasSize(4); } @Test @@ -56,29 +50,17 @@ public void should_have_Esql_as_category_for_properties() throws Exception { } @Test - public void count_extensions_for_sonarqube_server_6_0() throws Exception { - Plugin.Context context = setupContext(SonarRuntimeImpl.forSonarQube(Version.create(6, 0), SonarQubeSide.SERVER)); - - assertThat(context.getExtensions()).hasSize(8); - } - - @Test - public void count_extensions_for_sonarqube_server_6_2() throws Exception { - Plugin.Context context = setupContext(SonarRuntimeImpl.forSonarQube(Version.create(6, 2), SonarQubeSide.SERVER)); + public void count_extensions() throws Exception { + Plugin.Context context = setupContext(SonarRuntimeImpl.forSonarQube(Version.create(7, 9), SonarQubeSide.SERVER, SonarEdition.COMMUNITY)); - assertThat(context.getExtensions()).hasSize(8); + assertThat(context.getExtensions()).hasSize(10); } - @Test - public void count_extensions_for_sonarlint() throws Exception { - Plugin.Context context = setupContext(SonarRuntimeImpl.forSonarLint(Version.create(6, 0))); - assertThat(context.getExtensions()).hasSize(8); - } private List properties() { List propertiesList = new ArrayList<>(); - List extensions = setupContext(SonarRuntimeImpl.forSonarQube(Version.create(5, 6), SonarQubeSide.SERVER)).getExtensions(); + List extensions = setupContext(SonarRuntimeImpl.forSonarQube(Version.create(7, 9), SonarQubeSide.SERVER, SonarEdition.COMMUNITY)).getExtensions(); for (Object extension : extensions) { if (extension instanceof PropertyDefinition) { diff --git a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlProfileTest.java b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlProfileTest.java deleted file mode 100644 index 4af07c79..00000000 --- a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlProfileTest.java +++ /dev/null @@ -1,94 +0,0 @@ -/* - * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG - * http://www.exxeta.com - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.exxeta.iss.sonar.esql; - -import org.junit.Test; -import org.mockito.invocation.InvocationOnMock; -import org.mockito.stubbing.Answer; -import org.sonar.api.profiles.RulesProfile; -import org.sonar.api.rules.Rule; -import org.sonar.api.rules.RuleFinder; -import org.sonar.api.rules.RulePriority; -import org.sonar.api.utils.ValidationMessages; - -import com.exxeta.iss.sonar.esql.check.CheckList; - -import static org.assertj.core.api.Assertions.assertThat; -import static org.mockito.Matchers.anyString; -import static org.mockito.Mockito.mock; -import static org.mockito.Mockito.when; - -public class EsqlProfileTest { - - @Test - public void should_create_sonar_way_recommended_profile() { - ValidationMessages validation = ValidationMessages.create(); - - RuleFinder ruleFinder = ruleFinder(); - EsqlProfile definition = new EsqlProfile(ruleFinder); - RulesProfile profile = definition.createProfile(validation); - - assertThat(profile.getLanguage()).isEqualTo(EsqlLanguage.KEY); - assertThat(profile.getName()).isEqualTo(EsqlProfile.PROFILE_NAME); - assertThat(profile.getActiveRules()).extracting("repositoryKey").containsOnly("common-esql", CheckList.REPOSITORY_KEY); - assertThat(validation.hasErrors()).isFalse(); - assertThat(profile.getActiveRules().size()).isGreaterThan(10); - } - - @Test - public void should_not_include_common_rules_for_sonarlint() { - ValidationMessages validation = ValidationMessages.create(); - RuleFinder ruleFinder = sonarLintRuleFinder(); - EsqlProfile definition = new EsqlProfile(ruleFinder); - RulesProfile profile = definition.createProfile(validation); - - // no "common-esql" here - assertThat(profile.getActiveRules()).extracting("repositoryKey").containsOnly(CheckList.REPOSITORY_KEY); - - assertThat(profile.getLanguage()).isEqualTo(EsqlLanguage.KEY); - assertThat(profile.getName()).isEqualTo(EsqlProfile.PROFILE_NAME); - assertThat(validation.hasErrors()).isFalse(); - assertThat(profile.getActiveRules().size()).isGreaterThan(10); - } - - static RuleFinder ruleFinder() { - return when(mock(RuleFinder.class).findByKey(anyString(), anyString())).thenAnswer(new Answer() { - @Override - public Rule answer(InvocationOnMock invocation) { - Object[] arguments = invocation.getArguments(); - return Rule.create((String) arguments[0], (String) arguments[1], (String) arguments[1]); - } - }).getMock(); - } - - /** - * SonarLint will inject a rule finder containing only the rules coming from the esql repository - */ - private RuleFinder sonarLintRuleFinder() { - return when(mock(RuleFinder.class).findByKey(anyString(), anyString())).thenAnswer(invocation -> { - Object[] arguments = invocation.getArguments(); - if (CheckList.REPOSITORY_KEY.equals(arguments[0])) { - Rule rule = Rule.create((String) arguments[0], (String) arguments[1], (String) arguments[1]); - return rule.setSeverity(RulePriority.MINOR); - } - return null; - }).getMock(); - } - - -} diff --git a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlProfilesDefinitionTest.java b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlProfilesDefinitionTest.java new file mode 100644 index 00000000..1843a481 --- /dev/null +++ b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlProfilesDefinitionTest.java @@ -0,0 +1,66 @@ +/* + * Sonar ESQL Plugin + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG + * http://www.exxeta.com + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.exxeta.iss.sonar.esql; + +import com.exxeta.iss.sonar.esql.check.CheckList; +import org.junit.Before; +import org.junit.Test; +import org.sonar.api.server.profile.BuiltInQualityProfilesDefinition; +import org.sonar.api.server.profile.BuiltInQualityProfilesDefinition.BuiltInQualityProfile; +import org.sonar.check.Rule; +import org.sonarsource.analyzer.commons.BuiltInQualityProfileJsonLoader; + +import java.lang.annotation.Annotation; +import java.util.Set; +import java.util.stream.Collectors; + +import static com.exxeta.iss.sonar.esql.EsqlProfilesDefinition.SONAR_WAY; +import static com.exxeta.iss.sonar.esql.EsqlProfilesDefinition.SONAR_WAY_JSON; +import static org.assertj.core.api.Assertions.assertThat; + +public class EsqlProfilesDefinitionTest { + + private BuiltInQualityProfilesDefinition.Context context = new BuiltInQualityProfilesDefinition.Context(); + + @Before + public void setUp() { + new EsqlProfilesDefinition().define(context); + } + + @Test + public void sonar_way_esql() { + BuiltInQualityProfile profile = context.profile(EsqlLanguage.KEY, SONAR_WAY); + + assertThat(profile.language()).isEqualTo(EsqlLanguage.KEY); + assertThat(profile.name()).isEqualTo(SONAR_WAY); + assertThat(profile.rules()).extracting("repoKey").containsOnly(CheckList.REPOSITORY_KEY); + assertThat(profile.rules().size()).isGreaterThan(50); + } + + @Test + public void no_legacy_Key_in_profile_json() { + Set allKeys = CheckList.getChecks().stream().map(c -> { + Annotation ruleAnnotation = c.getAnnotation(Rule.class); + return ((Rule) ruleAnnotation).key(); + }).collect(Collectors.toSet()); + + Set sonarWayKeys = BuiltInQualityProfileJsonLoader.loadActiveKeysFromJsonProfile(SONAR_WAY_JSON); + + assertThat(sonarWayKeys).isSubsetOf(allKeys); + } +} diff --git a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlSensorTest.java b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlSensorTest.java new file mode 100644 index 00000000..985015dc --- /dev/null +++ b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlSensorTest.java @@ -0,0 +1,352 @@ +/* + * Sonar ESQL Plugin + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG + * http://www.exxeta.com + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.exxeta.iss.sonar.esql; + +import com.exxeta.iss.sonar.esql.api.CustomEsqlRulesDefinition; +import com.exxeta.iss.sonar.esql.api.EsqlCheck; +import com.exxeta.iss.sonar.esql.api.tree.ProgramTree; +import com.exxeta.iss.sonar.esql.api.tree.Tree; +import com.exxeta.iss.sonar.esql.api.visitors.DoubleDispatchVisitorCheck; +import com.exxeta.iss.sonar.esql.api.visitors.LineIssue; +import com.exxeta.iss.sonar.esql.api.visitors.TreeVisitor; +import com.exxeta.iss.sonar.esql.api.visitors.TreeVisitorContext; +import com.exxeta.iss.sonar.esql.check.CheckList; +import com.google.common.base.Charsets; +import com.google.common.collect.ImmutableList; +import com.sonar.sslr.api.RecognitionException; +import org.apache.commons.lang.NotImplementedException; +import org.junit.Before; +import org.junit.Test; +import org.junit.rules.ExpectedException; +import org.sonar.api.batch.fs.InputFile; +import org.sonar.api.batch.fs.InputFile.Type; +import org.sonar.api.batch.fs.internal.DefaultInputFile; +import org.sonar.api.batch.fs.internal.DefaultTextPointer; +import org.sonar.api.batch.fs.internal.DefaultTextRange; +import org.sonar.api.batch.fs.internal.FileMetadata; +import org.sonar.api.batch.fs.internal.TestInputFileBuilder; +import org.sonar.api.batch.rule.ActiveRules; +import org.sonar.api.batch.rule.CheckFactory; +import org.sonar.api.batch.rule.internal.ActiveRulesBuilder; +import org.sonar.api.batch.rule.internal.NewActiveRule; +import org.sonar.api.batch.sensor.internal.SensorContextTester; +import org.sonar.api.batch.sensor.issue.Issue; +import org.sonar.api.issue.NoSonarFilter; +import org.sonar.api.measures.CoreMetrics; +import org.sonar.api.measures.FileLinesContext; +import org.sonar.api.measures.FileLinesContextFactory; +import org.sonar.api.rule.RuleKey; +import org.sonar.api.utils.log.LogTester; +import org.sonar.check.Rule; +import org.sonar.check.RuleProperty; +import org.sonar.squidbridge.ProgressReport; + +import java.io.File; +import java.io.FileInputStream; +import java.io.FileNotFoundException; +import java.io.InterruptedIOException; +import java.nio.charset.StandardCharsets; +import java.util.Collection; + +import static org.assertj.core.api.Assertions.assertThat; +import static org.mockito.ArgumentMatchers.any; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.verify; +import static org.mockito.Mockito.when; + +public class +EsqlSensorTest { + + @org.junit.Rule + public final ExpectedException thrown = ExpectedException.none(); + + @org.junit.Rule + public LogTester logTester = new LogTester(); + + private FileLinesContextFactory fileLinesContextFactory; + + private CheckFactory checkFactory = new CheckFactory(mock(ActiveRules.class)); + + + private final CustomEsqlRulesDefinition[] CUSTOM_RULES = {new CustomEsqlRulesDefinition() { + @Override + public String repositoryName() { + return "custom name"; + } + + @Override + public String repositoryKey() { + return "customKey"; + } + + @Override + public Class[] checkClasses() { + return new Class[]{MyCustomRule.class}; + } + }}; + + private File baseDir = new File("src/test/resources"); + private final ProgressReport progressReport = mock(ProgressReport.class); + private SensorContextTester context = SensorContextTester.create(baseDir); + + private EsqlSensor createSensor() { + return new EsqlSensor(checkFactory, fileLinesContextFactory, context.fileSystem(), new NoSonarFilter()); + } + + private EsqlSensor createSensorWithCustomRules() { + return new EsqlSensor(checkFactory, fileLinesContextFactory, context.fileSystem(), new NoSonarFilter(), CUSTOM_RULES); + } + + @Before + public void setUp() { + fileLinesContextFactory = mock(FileLinesContextFactory.class); + FileLinesContext fileLinesContext = mock(FileLinesContext.class); + when(fileLinesContextFactory.createFor(any(InputFile.class))).thenReturn(fileLinesContext); + } + + @Test + public void should_analyse() { + String relativePath = "cpd/Person.esql"; + inputFile(relativePath); + + createSensor().execute(context); + + String key = "moduleKey:" + relativePath; + + + //assertThat(context.measure(key, CoreMetrics.FILES).value()).isEqualTo(1); + //assertThat(context.measure(key, CoreMetrics.LINES).value()).isEqualTo(20); + assertThat(context.measure(key, CoreMetrics.NCLOC).value()).isEqualTo(18); + assertThat(context.measure(key, CoreMetrics.FUNCTIONS).value()).isEqualTo(1); + assertThat(context.measure(key, CoreMetrics.STATEMENTS).value()).isEqualTo(8); + assertThat(context.measure(key, CoreMetrics.COMPLEXITY).value()).isEqualTo(7); + assertThat(context.measure(key, CoreMetrics.COMMENT_LINES).value()).isEqualTo(3); + } + + @Test + public void parsing_error() { + String relativePath = "cpd/parsingError.esql"; + inputFile(relativePath); + + String parsingErrorCheckKey = "ParsingError"; + + ActiveRules activeRules = (new ActiveRulesBuilder()) + .addRule(new NewActiveRule.Builder().setName("ParsingError").setRuleKey(RuleKey.of(CheckList.REPOSITORY_KEY, parsingErrorCheckKey)).build()) + .build(); + + checkFactory = new CheckFactory(activeRules); + + context.setActiveRules(activeRules); + createSensor().execute(context); + Collection issues = context.allIssues(); + assertThat(issues).hasSize(1); + Issue issue = issues.iterator().next(); + assertThat(issue.primaryLocation().textRange().start().line()).isEqualTo(3); + assertThat(issue.primaryLocation().message()).isEqualTo("Parse error"); + + assertThat(context.allAnalysisErrors()).hasSize(1); + } + + @Test + public void should_add_error_to_context_but_not_fail_analysis_with_technical_error() { + EsqlCheck check = new ExceptionRaisingCheck(new NullPointerException("NPE forcibly raised by check class")); + + InputFile file = inputFile("file.esql"); + createSensor().analyseFiles(context, ImmutableList.of((TreeVisitor) check), + ImmutableList.of(file), progressReport); + assertThat(context.allAnalysisErrors()).hasSize(1); + + assertThat(logTester.logs()).contains("Unable to analyse file: " + file.uri()); + } + + @Test + public void analysis_with_no_issue_should_not_add_error_to_context() { + inputFile("file.esql"); + + createSensor().execute(context); + + Collection issues = context.allIssues(); + assertThat(issues).hasSize(0); + + assertThat(context.allAnalysisErrors()).isEmpty(); + } + + @Test + public void analysis_with_issues_should_not_add_error_to_context() { + inputFile("file.esql"); + + ActiveRules activeRules = (new ActiveRulesBuilder()) + .addRule(new NewActiveRule.Builder().setRuleKey(RuleKey.of(CheckList.REPOSITORY_KEY, "MissingNewlineAtEndOfFile")).build()) + .build(); + checkFactory = new CheckFactory(activeRules); + + createSensor().execute(context); + + Collection issues = context.allIssues(); + assertThat(issues).hasSize(1); + + assertThat(context.allAnalysisErrors()).isEmpty(); + } + + @Test + public void save_issue() throws Exception { + inputFile("file.esql"); + + ActiveRules activeRules = (new ActiveRulesBuilder()) + .addRule(new NewActiveRule.Builder().setRuleKey(RuleKey.of(CheckList.REPOSITORY_KEY, "MissingNewlineAtEndOfFile")).build()) + .addRule(new NewActiveRule.Builder().setRuleKey(RuleKey.of(CheckList.REPOSITORY_KEY, "InitializeVariables")).build()) + .build(); + + checkFactory = new CheckFactory(activeRules); + createSensor().execute(context); + Collection issues = context.allIssues(); + assertThat(issues).hasSize(2); + } + + @Test + public void custom_rule() throws Exception { + inputFile("file.esql"); + ActiveRules activeRules = (new ActiveRulesBuilder()) + .addRule(new NewActiveRule.Builder().setRuleKey(RuleKey.of("customKey", "key")).build()).build(); + checkFactory = new CheckFactory(activeRules); + createSensorWithCustomRules().execute(context); + + Collection issues = context.allIssues(); + assertThat(issues).hasSize(1); + Issue issue = issues.iterator().next(); + assertThat(issue.gap()).isEqualTo(42); + assertThat(issue.primaryLocation().message()).isEqualTo("Message of custom rule"); + assertThat(issue.primaryLocation().textRange()) + .isEqualTo(new DefaultTextRange(new DefaultTextPointer(1, 0), new DefaultTextPointer(1, 24))); + } + + @Test + public void progress_report_should_be_stopped() throws Exception { + InputFile inputFile = inputFile("cpd/Person.esql"); + createSensor().analyseFiles(context, ImmutableList.of(), ImmutableList.of(inputFile), progressReport); + verify(progressReport).stop(); + } + + @Test + public void progress_report_should_be_stopped_without_files() throws Exception { + createSensor().analyseFiles(context, ImmutableList.of(), ImmutableList.of(), progressReport); + verify(progressReport).stop(); + } + + @Test + public void cancelled_analysis() throws Exception { + EsqlCheck check = new ExceptionRaisingCheck(new IllegalStateException(new InterruptedException())); + analyseFileWithException(check, inputFile("cpd/Person.esql"), "Analysis cancelled"); + assertThat(context.allAnalysisErrors()).hasSize(1); + } + + @Test + public void cancelled_analysis_causing_recognition_exception() throws Exception { + EsqlCheck check = new ExceptionRaisingCheck( + new RecognitionException(42, "message", new InterruptedIOException())); + analyseFileWithException(check, inputFile("cpd/Person.esql"), "Analysis cancelled"); + assertThat(context.allAnalysisErrors()).hasSize(1); + } + + @Test + public void exception_should_report_file_name() throws Exception { + EsqlCheck check = new ExceptionRaisingCheck(new IllegalStateException(new InterruptedException())); + analyseFileWithException(check, inputFile("cpd/Person.esql"), "Analysis cancelled"); + assertThat(context.allAnalysisErrors()).hasSize(1); + } + + @Test + public void cancelled_context_should_cancel_progress_report_and_return_with_no_exception() { + EsqlCheck check = new DoubleDispatchVisitorCheck() { + }; + EsqlSensor sensor = createSensor(); + SensorContextTester cancelledContext = SensorContextTester.create(baseDir); + cancelledContext.setCancelled(true); + sensor.analyseFiles(cancelledContext, ImmutableList.of((TreeVisitor) check), + ImmutableList.of(inputFile("cpd/Person.esql")), progressReport); + verify(progressReport).cancel(); + } + + private void analyseFileWithException(EsqlCheck check, InputFile inputFile, + String expectedMessageSubstring) { + EsqlSensor sensor = createSensor(); + thrown.expectMessage(expectedMessageSubstring); + try { + sensor.analyseFiles(context, ImmutableList.of((TreeVisitor) check), ImmutableList.of(inputFile), + progressReport); + } finally { + verify(progressReport).cancel(); + } + } + + + private InputFile inputFile(String relativePath) { + DefaultInputFile inputFile = new TestInputFileBuilder("moduleKey", relativePath) + .setModuleBaseDir(baseDir.toPath()) + .setType(Type.MAIN) + .setLanguage(EsqlLanguage.KEY) + .setCharset(StandardCharsets.UTF_8) + .build(); + + context.fileSystem().add(inputFile); + + try { + inputFile.setMetadata(new FileMetadata().readMetadata(new FileInputStream(inputFile.file()), Charsets.UTF_8, inputFile.absolutePath())); + } catch (FileNotFoundException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + return inputFile; + } + + private final class ExceptionRaisingCheck extends DoubleDispatchVisitorCheck { + + private final RuntimeException exception; + + ExceptionRaisingCheck(RuntimeException exception) { + this.exception = exception; + } + + @Override + public TreeVisitorContext getContext() { + return null; + } + + @Override + public LineIssue addLineIssue(Tree tree, String message) { + throw new NotImplementedException(); + } + + @Override + public void visitProgram(ProgramTree tree) { + throw exception; + } + } + + @Rule(key = "key", name = "name", description = "desc", tags = {"bug"}) + public static class MyCustomRule extends DoubleDispatchVisitorCheck { + @RuleProperty(key = "customParam", description = "Custome parameter", defaultValue = "value") + public String customParam = "value"; + + @Override + public void visitProgram(ProgramTree tree) { + addIssue(new LineIssue(this, 1, "Message of custom rule")).cost(42); + } + } + +} diff --git a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlSquidSensorTest.java b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlSquidSensorTest.java deleted file mode 100644 index 6d348ea4..00000000 --- a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/EsqlSquidSensorTest.java +++ /dev/null @@ -1,371 +0,0 @@ -/* - * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG - * http://www.exxeta.com - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.exxeta.iss.sonar.esql; - -import static org.assertj.core.api.Assertions.assertThat; -import static org.mockito.Matchers.any; -import static org.mockito.Mockito.mock; -import static org.mockito.Mockito.verify; -import static org.mockito.Mockito.when; - -import java.io.File; -import java.io.FileInputStream; -import java.io.FileNotFoundException; -import java.io.InterruptedIOException; -import java.nio.charset.StandardCharsets; -import java.util.Collection; - -import org.apache.commons.lang.NotImplementedException; -import org.junit.Before; -import org.junit.Test; -import org.junit.rules.ExpectedException; -import org.sonar.api.SonarQubeSide; -import org.sonar.api.SonarRuntime; -import org.sonar.api.batch.fs.InputFile; -import org.sonar.api.batch.fs.InputFile.Type; -import org.sonar.api.batch.fs.internal.DefaultInputFile; -import org.sonar.api.batch.fs.internal.DefaultTextPointer; -import org.sonar.api.batch.fs.internal.DefaultTextRange; -import org.sonar.api.batch.fs.internal.FileMetadata; -import org.sonar.api.batch.fs.internal.TestInputFileBuilder; -import org.sonar.api.batch.rule.ActiveRules; -import org.sonar.api.batch.rule.CheckFactory; -import org.sonar.api.batch.rule.internal.ActiveRulesBuilder; -import org.sonar.api.batch.sensor.internal.DefaultSensorDescriptor; -import org.sonar.api.batch.sensor.internal.SensorContextTester; -import org.sonar.api.batch.sensor.issue.Issue; -import org.sonar.api.internal.SonarRuntimeImpl; -import org.sonar.api.issue.NoSonarFilter; -import org.sonar.api.measures.CoreMetrics; -import org.sonar.api.measures.FileLinesContext; -import org.sonar.api.measures.FileLinesContextFactory; -import org.sonar.api.rule.RuleKey; -import org.sonar.api.utils.Version; -import org.sonar.api.utils.log.LogTester; -import org.sonar.check.Rule; -import org.sonar.check.RuleProperty; -import org.sonar.squidbridge.ProgressReport; -import org.sonar.squidbridge.api.AnalysisException; - -import com.exxeta.iss.sonar.esql.EsqlSquidSensor.ProductDependentExecutor; -import com.exxeta.iss.sonar.esql.EsqlSquidSensor.SonarLintProductExecutor; -import com.exxeta.iss.sonar.esql.api.CustomEsqlRulesDefinition; -import com.exxeta.iss.sonar.esql.api.EsqlCheck; -import com.exxeta.iss.sonar.esql.api.tree.ProgramTree; -import com.exxeta.iss.sonar.esql.api.tree.Tree; -import com.exxeta.iss.sonar.esql.api.visitors.DoubleDispatchVisitorCheck; -import com.exxeta.iss.sonar.esql.api.visitors.LineIssue; -import com.exxeta.iss.sonar.esql.api.visitors.TreeVisitor; -import com.exxeta.iss.sonar.esql.api.visitors.TreeVisitorContext; -import com.exxeta.iss.sonar.esql.check.CheckList; -import com.google.common.base.Charsets; -import com.google.common.collect.ImmutableList; -import com.sonar.sslr.api.RecognitionException; - -public class EsqlSquidSensorTest { - - private static final Version SONARLINT_DETECTABLE_VERSION = Version.create(6, 0); - private static final SonarRuntime SONARLINT_RUNTIME = SonarRuntimeImpl.forSonarLint(SONARLINT_DETECTABLE_VERSION); - private static final SonarRuntime NOSONARLINT_RUNTIME = SonarRuntimeImpl.forSonarQube(SONARLINT_DETECTABLE_VERSION, - SonarQubeSide.SERVER); - - private static final ProductDependentExecutor executor = new SonarLintProductExecutor(); - - @org.junit.Rule - public final ExpectedException thrown = ExpectedException.none(); - - @org.junit.Rule - public LogTester logTester = new LogTester(); - - private FileLinesContextFactory fileLinesContextFactory; - private CheckFactory checkFactory = new CheckFactory(mock(ActiveRules.class)); - private final CustomEsqlRulesDefinition[] CUSTOM_RULES = { new CustomEsqlRulesDefinition() { - @Override - public String repositoryName() { - return "custom name"; - } - - @Override - public String repositoryKey() { - return "customKey"; - } - - @Override - public Class[] checkClasses() { - return new Class[] { MyCustomRule.class }; - } - } }; - - private File baseDir = new File("src/test/resources"); - private final ProgressReport progressReport = mock(ProgressReport.class); - private SensorContextTester context = SensorContextTester.create(baseDir); - - private EsqlSquidSensor createSensor() { - return new EsqlSquidSensor(checkFactory, fileLinesContextFactory, context.fileSystem(), new NoSonarFilter(), - CUSTOM_RULES); - } - - @Before - public void setUp() { - fileLinesContextFactory = mock(FileLinesContextFactory.class); - FileLinesContext fileLinesContext = mock(FileLinesContext.class); - when(fileLinesContextFactory.createFor(any(InputFile.class))).thenReturn(fileLinesContext); - } - - @Test - public void sensor_descriptor() { - DefaultSensorDescriptor descriptor = new DefaultSensorDescriptor(); - - createSensor().describe(descriptor); - assertThat(descriptor.name()).isEqualTo("ESQL Squid Sensor"); - assertThat(descriptor.languages()).containsOnly("esql"); - assertThat(descriptor.type()).isEqualTo(Type.MAIN); - } - - @Test - public void should_analyse() { - String relativePath = "cpd/Person.esql"; - inputFile(relativePath); - - createSensor().execute(context); - - String key = "moduleKey:" + relativePath; - - - //assertThat(context.measure(key, CoreMetrics.FILES).value()).isEqualTo(1); - //assertThat(context.measure(key, CoreMetrics.LINES).value()).isEqualTo(20); - assertThat(context.measure(key, CoreMetrics.NCLOC).value()).isEqualTo(18); - assertThat(context.measure(key, CoreMetrics.FUNCTIONS).value()).isEqualTo(1); - assertThat(context.measure(key, CoreMetrics.STATEMENTS).value()).isEqualTo(8); - assertThat(context.measure(key, CoreMetrics.COMPLEXITY).value()).isEqualTo(7); - assertThat(context.measure(key, CoreMetrics.COMMENT_LINES).value()).isEqualTo(3); - } - - @Test - public void parsing_error() { - String relativePath = "cpd/parsingError.esql"; - inputFile(relativePath); - - String parsingErrorCheckKey = "ParsingError"; - - ActiveRules activeRules = (new ActiveRulesBuilder()) - .create(RuleKey.of(CheckList.REPOSITORY_KEY, parsingErrorCheckKey)).setName("ParsingError").activate() - .build(); - - checkFactory = new CheckFactory(activeRules); - - context.setActiveRules(activeRules); - createSensor().execute(context); - Collection issues = context.allIssues(); - assertThat(issues).hasSize(1); - Issue issue = issues.iterator().next(); - assertThat(issue.primaryLocation().textRange().start().line()).isEqualTo(3); - assertThat(issue.primaryLocation().message()).isEqualTo("Parse error"); - - assertThat(context.allAnalysisErrors()).hasSize(1); - } - - @Test - public void technical_error_should_add_error_to_context() { - thrown.expect(AnalysisException.class); - - EsqlCheck check = new ExceptionRaisingCheck(new NullPointerException("NPE forcibly raised by check class")); - - createSensor().analyseFiles(context, ImmutableList.of((TreeVisitor) check), - ImmutableList.of(inputFile("file.esql")), executor, progressReport); - assertThat(context.allAnalysisErrors()).hasSize(1); - } - - @Test - public void analysis_with_no_issue_should_not_add_error_to_context() { - inputFile("file.esql"); - - createSensor().execute(context); - - Collection issues = context.allIssues(); - assertThat(issues).hasSize(0); - - assertThat(context.allAnalysisErrors()).isEmpty(); - } - - @Test - public void analysis_with_issues_should_not_add_error_to_context() { - inputFile("file.esql"); - - ActiveRules activeRules = (new ActiveRulesBuilder()) - .create(RuleKey.of(CheckList.REPOSITORY_KEY, "MissingNewlineAtEndOfFile")).activate().build(); - checkFactory = new CheckFactory(activeRules); - - createSensor().execute(context); - - Collection issues = context.allIssues(); - assertThat(issues).hasSize(1); - - assertThat(context.allAnalysisErrors()).isEmpty(); - } - - @Test - public void save_issue() throws Exception { - inputFile("file.esql"); - - ActiveRules activeRules = (new ActiveRulesBuilder()) - .create(RuleKey.of(CheckList.REPOSITORY_KEY, "MissingNewlineAtEndOfFile")) - .activate() - .create(RuleKey.of(CheckList.REPOSITORY_KEY, "InitializeVariables")) - .activate() - .build(); - - checkFactory = new CheckFactory(activeRules); - createSensor().execute(context); - Collection issues = context.allIssues(); - assertThat(issues).hasSize(2); - } - - @Test - public void custom_rule() throws Exception { - inputFile("file.esql"); - ActiveRules activeRules = (new ActiveRulesBuilder()).create(RuleKey.of("customKey", "key")).activate().build(); - checkFactory = new CheckFactory(activeRules); - createSensor().execute(context); - - Collection issues = context.allIssues(); - assertThat(issues).hasSize(1); - Issue issue = issues.iterator().next(); - assertThat(issue.gap()).isEqualTo(42); - assertThat(issue.primaryLocation().message()).isEqualTo("Message of custom rule"); - assertThat(issue.primaryLocation().textRange()) - .isEqualTo(new DefaultTextRange(new DefaultTextPointer(1, 0), new DefaultTextPointer(1, 24))); - } - - @Test - public void progress_report_should_be_stopped() throws Exception { - InputFile inputFile = inputFile("cpd/Person.esql"); - createSensor().analyseFiles(context, ImmutableList.of(), ImmutableList.of(inputFile), executor, progressReport); - verify(progressReport).stop(); - } - - @Test - public void progress_report_should_be_stopped_without_files() throws Exception { - createSensor().analyseFiles(context, ImmutableList.of(), ImmutableList.of(), executor, progressReport); - verify(progressReport).stop(); - } - - @Test - public void cancelled_analysis() throws Exception { - EsqlCheck check = new ExceptionRaisingCheck(new IllegalStateException(new InterruptedException())); - analyseFileWithException(check, inputFile("cpd/Person.esql"), "Analysis cancelled"); - assertThat(context.allAnalysisErrors()).hasSize(1); - } - - @Test - public void cancelled_analysis_causing_recognition_exception() throws Exception { - EsqlCheck check = new ExceptionRaisingCheck( - new RecognitionException(42, "message", new InterruptedIOException())); - analyseFileWithException(check, inputFile("cpd/Person.esql"), "Analysis cancelled"); - assertThat(context.allAnalysisErrors()).hasSize(1); - } - - @Test - public void exception_should_report_file_name() throws Exception { - EsqlCheck check = new ExceptionRaisingCheck(new IllegalStateException()); - analyseFileWithException(check, inputFile("cpd/Person.esql"), "Person.esql"); - assertThat(context.allAnalysisErrors()).hasSize(1); - } - - @Test - public void cancelled_context_should_cancel_progress_report_and_return_with_no_exception() { - EsqlCheck check = new DoubleDispatchVisitorCheck() { - }; - EsqlSquidSensor sensor = createSensor(); - SensorContextTester cancelledContext = SensorContextTester.create(baseDir); - cancelledContext.setCancelled(true); - sensor.analyseFiles(cancelledContext, ImmutableList.of((TreeVisitor) check), - ImmutableList.of(inputFile("cpd/Person.esql")), executor, progressReport); - verify(progressReport).cancel(); - } - - private void analyseFileWithException(EsqlCheck check,InputFile inputFile, - String expectedMessageSubstring) { - EsqlSquidSensor sensor = createSensor(); - thrown.expect(AnalysisException.class); - thrown.expectMessage(expectedMessageSubstring); - try { - sensor.analyseFiles(context, ImmutableList.of((TreeVisitor) check), ImmutableList.of(inputFile), executor, - progressReport); - } finally { - verify(progressReport).cancel(); - } - } - - - - private InputFile inputFile(String relativePath) { - DefaultInputFile inputFile = new TestInputFileBuilder("moduleKey", relativePath) - .setModuleBaseDir(baseDir.toPath()) - .setType(Type.MAIN) - .setLanguage(EsqlLanguage.KEY) - .setCharset(StandardCharsets.UTF_8) - .build(); - - context.fileSystem().add(inputFile); - - try { - inputFile.setMetadata(new FileMetadata().readMetadata(new FileInputStream(inputFile.file()), Charsets.UTF_8, inputFile.absolutePath())); - } catch (FileNotFoundException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - return inputFile; - } - - private final class ExceptionRaisingCheck extends DoubleDispatchVisitorCheck { - - private final RuntimeException exception; - - ExceptionRaisingCheck(RuntimeException exception) { - this.exception = exception; - } - - @Override - public TreeVisitorContext getContext() { - return null; - } - - @Override - public LineIssue addLineIssue(Tree tree, String message) { - throw new NotImplementedException(); - } - - @Override - public void visitProgram(ProgramTree tree) { - throw exception; - } - } - - @Rule(key = "key", name = "name", description = "desc", tags = { "bug" }) - public static class MyCustomRule extends DoubleDispatchVisitorCheck { - @RuleProperty(key = "customParam", description = "Custome parameter", defaultValue = "value") - public String customParam = "value"; - - @Override - public void visitProgram(ProgramTree tree) { - addIssue(new LineIssue(this, 1, "Message of custom rule")).cost(42); - } - } - -} diff --git a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/rules/EsqlRulesDefinitionTest.java b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/rules/EsqlRulesDefinitionTest.java index b25f68ad..4099eb70 100644 --- a/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/rules/EsqlRulesDefinitionTest.java +++ b/esql-plugin/src/test/java/com/exxeta/iss/sonar/esql/rules/EsqlRulesDefinitionTest.java @@ -1,6 +1,6 @@ /* * Sonar ESQL Plugin - * Copyright (C) 2013-2018 Thomas Pohl and EXXETA AG + * Copyright (C) 2013-2020 Thomas Pohl and EXXETA AG * http://www.exxeta.com * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -36,7 +36,7 @@ public class EsqlRulesDefinitionTest { @Test public void test() { - RulesDefinition.Repository repository = buildRepository(Version.parse("5.6")); + RulesDefinition.Repository repository = buildRepository(); assertThat(repository.name()).isEqualTo("SonarAnalyzer"); assertThat(repository.language()).isEqualTo("esql"); @@ -47,8 +47,8 @@ public void test() { assertAllRuleParametersHaveDescription(repository); } - private RulesDefinition.Repository buildRepository(Version sonarRuntimeVersion) { - EsqlRulesDefinition rulesDefinition = new EsqlRulesDefinition(sonarRuntimeVersion); + private RulesDefinition.Repository buildRepository() { + EsqlRulesDefinition rulesDefinition = new EsqlRulesDefinition(); RulesDefinition.Context context = new RulesDefinition.Context(); rulesDefinition.define(context); RulesDefinition.Repository repository = context.repository("esql"); @@ -57,10 +57,10 @@ private RulesDefinition.Repository buildRepository(Version sonarRuntimeVersion) private void assertParameterProperties(Repository repository) { // TooManyLinesInFunctionCheck - Param max = repository.rule("NestedIfDepth").param("maximumNestingLevel"); + Param max = repository.rule("TooManyLinesInFile").param("maximum"); assertThat(max).isNotNull(); - assertThat(max.defaultValue()).isEqualTo("5"); - assertThat(max.description()).isEqualTo("Allowed nesting depth"); + assertThat(max.defaultValue()).isEqualTo("2000"); + assertThat(max.description()).isEqualTo("the maximum authorized lines"); assertThat(max.type()).isEqualTo(RuleParamType.INTEGER); } diff --git a/pom.xml b/pom.xml index 78128911..6335072e 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ com.exxeta.iss sonar-esql-plugin - 2.3.5 + 0.0.1-SNAPSHOT pom http://exxeta.com @@ -46,50 +46,58 @@ https://github.com/EXXETA/sonar-esql-plugin scm:git:git@github.com:EXXETA/sonar-esql-plugin.git + + Github + https://github.com/EXXETA/sonar-esql-plugin/issues + + + Travis + https://travis-ci.org/EXXETA/sonar-esql-plugin + - 6.7 - 1.17 - 1.8 + 7.9 + 1.18.0.372 + 1.8 UTF-8 - 3.0.5 + 3.0.5 3.5.2 2.5 2.6 - 19.0 - 4.10 + 28.0-jre + 4.12 1.0.13 - 1.9.0 + 2.21.0 1.7.21 - 6.7 - 3.14.0.887 - 3.0.0.1140 - 1.22 - 2.6.1 + 7.9 + 3.26.0.2111 + 4.3.1.2486 + 1.23 + 2.7.0.377 2.6.2 + 1.11.0.541 ${project.groupId}:sonar-esql-plugin:jar - 2.4 - 3.4 - 3.0.2 + + 3.1.0 + 3.7.1 + 3.1.0 3.2.1 - 3.0.2 + 3.1.2 1.4 - 3.0.0 - 3.5.1 - 2.9 + 3.1.0 + 3.8.1 + 3.1.1 2.8.2 3.0.0-M1 - 2.18 + 2.22.2 2.0 - 2.5.2 - 2.18 - - ${project.build.directory}/coverage-reports/jacoco-ut.exec + 3.0.0-M1 + 2.22.2 @@ -127,6 +135,11 @@ sslr-core ${sslr.version} + + org.sonarsource.analyzer-commons + sonar-analyzer-commons + ${analyzer-commons.version} + org.sonarsource.sslr-squid-bridge sslr-squid-bridge @@ -193,7 +206,7 @@ org.mockito - mockito-all + mockito-core ${mockito.version} test @@ -660,9 +673,7 @@ prepare-agent - - ${project.build.directory}/coverage-reports/jacoco-ut.exec - surefireArgLine @@ -675,12 +686,6 @@ report - - - ${project.build.directory}/coverage-reports/jacoco-ut.exec - - ${project.reporting.outputDirectory}/jacoco-ut - diff --git a/sampleWorkspace/BinaryOperatorSpace.esql b/sampleWorkspace/BinaryOperatorSpace.esql new file mode 100644 index 00000000..2ebdcca1 --- /dev/null +++ b/sampleWorkspace/BinaryOperatorSpace.esql @@ -0,0 +1,23 @@ +CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN +DECLARE versionRef REFERENCE TO InputRoot.SOAP.Context.SOAP_Version; + CASE + WHEN versionRef>= 1 THEN + SET Environment.Fault.faultcode='soapenv:Client'; + WHEN versionRef<1.2 THEN + SET Environment.Fault.faultcode='soapenv:Sender'; + END CASE; +CREATE FIELD Environment.LogData; + DECLARE refEnv REFERENCE TO Environment.LogData; + SET refEnv.serviceOperationName=InputRoot.SOAP.Context.operation; + SET refEnv.operationId = EVAL(Environment.LogData.serviceOperationName); + SET refEnv.serviceName = InputRoot.SOAP.Context.service; + SET refEnv.interfaceId = InputRoot.SOAP.Header.ns:Info.consumerId; + SET refEnv.serviceVersion = SUBSTRING(SUBSTRING(SUBSTRING(InputRoot.SOAP.Context.portTypeNamespace AFTER InputRoot.SOAP.Context.service) AFTER '/')BEFORE '/'); + SET OutputRoot = + InputRoot; + DECLARE myInt,myInt3 INTEGER 1; + DECLARE myInt2, myInt4 INTEGER 1; + DECLARE inMsg REFERENCE TO InputRoot.XMLNSC.*:*[<]; + RETURN TRUE; + END; diff --git a/sampleWorkspace/BlankLineBeforeComments.esql b/sampleWorkspace/BlankLineBeforeComments.esql new file mode 100644 index 00000000..d6a9a68e --- /dev/null +++ b/sampleWorkspace/BlankLineBeforeComments.esql @@ -0,0 +1,27 @@ +BROKER SCHEMA generic +DECLARE soapenv NAMESPACE 'http://schemas.xmlsoap.org/soap/envelope/'; +CREATE COMPUTE MODULE initialize +/**************************************************************************** +* This module will initialize the service/operation related variables +which are used to trace the message. +*****************************************************************************/ + +CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE versionRef REFERENCE TO InputRoot.SOAP.Context.SOAP_Version; + CASE + WHEN versionRef = '1.1' THEN + SET Environment.Fault.faultcode = 'soapenv:Client'; + END CASE; + --this is comment line + CREATE FIELD Environment.LogData; + DECLARE refEnv REFERENCE TO Environment.LogData; + + --Another comment line + RETURN TRUE; + END; + + /* + * And a comment block + */ +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/CyclomaticComplexity.esql b/sampleWorkspace/CyclomaticComplexity.esql new file mode 100644 index 00000000..4ddb7df1 --- /dev/null +++ b/sampleWorkspace/CyclomaticComplexity.esql @@ -0,0 +1,55 @@ +CREATE COMPUTE MODULE a + create FUNCTION Main() RETURNS BOOLEAN + BEGIN + IF x='ANS' OR y = 'AND' THEN + RETURN TRUE; + END IF; + WHILE I<5 DO + IF x='ANS1' THEN + RETURN TRUE; + ELSEIF x='ANS1' THEN + RETURN FALSE; + ELSEIF x='AN3' THEN + RETURN FALSE; + ELSEIF x='AN4' THEN + RETURN FALSE; + ELSE + RETURN FALSE; + END IF; + SET I = I + 1; + END WHILE; + RETURN TRUE; + IF x='ANS' OR y = 'AND' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' THEN + RETURN TRUE; + END IF; + END; + END MODULE; + CREATE COMPUTE MODULE b + + CREATE FUNCTION Main() RETURNS CHAR + BEGIN + RETURN A<2; + END; + CREATE Procedure Main2() RETURNS BOOLEAN + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2,myInt4 INTEGER; + IF x='ANS' OR y = 'AND' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' THEN + RETURN TRUE; + END IF; + IF x='ANS' OR y = 'AND' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' THEN + RETURN TRUE; + END IF; + IF x='ANS' OR y = 'AND' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' THEN + RETURN TRUE; + END IF; + IF x='ANS' OR y = 'AND' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' AND z = 'XYZ' OR a='space' THEN + RETURN TRUE; + END IF; + END; + +END MODULE; + + + + diff --git a/sampleWorkspace/DeprecatedMethod.esql b/sampleWorkspace/DeprecatedMethod.esql new file mode 100644 index 00000000..5856c6de --- /dev/null +++ b/sampleWorkspace/DeprecatedMethod.esql @@ -0,0 +1,26 @@ +BROKER SCHEMA generic +DECLARE soapenv NAMESPACE 'http://schemas.xmlsoap.org/soap/envelope/'; +DECLARE ns NAMESPACE 'http://com/abnamro/Services/AccessFacilityAgreement/v2/' ; +DECLARE createAccessFacilityAgreement EXTERNAL CHAR ''; +declare updateAccessFacilityAgreement EXTERNAL CHAR ''; +CREATE COMPUTE MODULE initialize +CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN +DECLARE versionRef REFERENCE TO InputRoot.SOAP.Context.SOAP_Version; + CASE + WHEN versionRef = '1.1' THEN + SET Environment.Fault.faultcode = 'soapenv:Client'; + WHEN versionRef = '1.2' THEN + SET Environment.Fault.faultcode = 'soapenv:Sender'; + END CASE; +CREATE FIELD Environment.LogData; + DECLARE refEnv REFERENCE TO Environment.LogData; + SET refEnv.serviceOperationName = InputRoot.SOAP.Context.operation; + SET refEnv.operationId = EVAL(Environment.LogData.serviceOperationName); + SET refEnv.serviceName = BITSTREAM(InputRoot.MQMD.UserIdentifier); --Noncompliant {{Do not use BITSTREAM it is deprecated.}} + SET refEnv.interfaceId = InputRoot.SOAP.Header.ns:Info.consumerId; + SET refEnv.serviceVersion = SUBSTRING(SUBSTRING(SUBSTRING(InputRoot.SOAP.Context.portTypeNamespace AFTER InputRoot.SOAP.Context.service) AFTER '/')BEFORE '/'); + SET OutputRoot=InputRoot; + RETURN TRUE; + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/FilterNodeHaveOnlyOneReturn.esql b/sampleWorkspace/FilterNodeHaveOnlyOneReturn.esql new file mode 100644 index 00000000..df58742d --- /dev/null +++ b/sampleWorkspace/FilterNodeHaveOnlyOneReturn.esql @@ -0,0 +1,63 @@ +CREATE FILTER MODULE Flow1_Filter + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + RETURN FALSE; + END; +END MODULE; + +CREATE COMPUTE MODULE Flow2_Compute + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + IF A > B THEN + RETURN TRUE; + ELSE + THROW USER EXCEPTION; + END IF; + END; +END MODULE; + +CREATE FILTER MODULE Flow3_Filter + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + RETURN TRUE; + END; +END MODULE; + +CREATE FILTER MODULE Flow3_Filter + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + THROW USER EXCEPTION; + END; +END MODULE; + +CREATE FILTER MODULE Flow4_Filter + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + IF A > B THEN + RETURN TRUE; + ELSE + RETURN FALSE; + END IF; + END; +END MODULE; + +CREATE FILTER MODULE Flow5_Filter + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + RETURN getResult(); + END; +END MODULE; + +CREATE FILTER MODULE Flow6_Filter + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + END; +END MODULE; + diff --git a/sampleWorkspace/FilterNodeModifyMessage.esql b/sampleWorkspace/FilterNodeModifyMessage.esql new file mode 100644 index 00000000..c15435ae --- /dev/null +++ b/sampleWorkspace/FilterNodeModifyMessage.esql @@ -0,0 +1,19 @@ +CREATE FILTER MODULE Flow2_Filter + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + SET a = 'a'; + SET a.a = 'a'; + RETURN FALSE; + END; +END MODULE; + +CREATE COMPUTE MODULE Flow2 + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + SET a = 'a'; + SET a.a = 'a'; + RETURN FALSE; + END; +END MODULE; diff --git a/sampleWorkspace/FunctionLength.esql b/sampleWorkspace/FunctionLength.esql new file mode 100644 index 00000000..cbe636f6 --- /dev/null +++ b/sampleWorkspace/FunctionLength.esql @@ -0,0 +1,604 @@ + +/**************************************************************************** +File Name: +Purpose: This module performs request and response tranformation. +Author: Ekta Patel +Version: +Date: 07-07-2017 +*****************************************************************************/ +/* +* Change log goes here +*/ +BROKER SCHEMA serviceOperations +DECLARE soapenv NAMESPACE 'http://schemas.xmlsoap.org/soap/envelope/'; +--DECLARE nsconOper NAMESPACE 'http://api.topicus.finance/fbl/documentgenerationservice/2017/6/operations'; +--DECLARE nsconDat NAMESPACE 'http://api.topicus.finance/fbl/documentgeneration/2017/6/datatypes'; +--DECLARE nsProvider NAMESPACE 'http://com/abnamro/nl/DocumentFulfillment/v1/'; +DECLARE nsError NAMESPACE 'http://api.topicus.finance/fbl/common/2016/7/metadata'; + + +DECLARE ns15 NAMESPACE 'http://api.topicus.finance/fbl/documentgenerationservice/2017/8/operations'; +DECLARE ns19 NAMESPACE 'http://com/abnamro/nl/DocumentFulfillment/v1/'; +DECLARE ns31 NAMESPACE 'http://api.topicus.finance/fbl/documentgeneration/2017/8/datatypes'; +/**************************************************************************** +* A procedure that will build the request message for FR151 +* IN inRef : Reference to Soap Body +* IN outRef : Reference to OutputRoot. +* IN Environment: Reference to Enviroment. +*****************************************************************************/ +CREATE PROCEDURE AdapterffCreateDocumentRequest(IN inRef REFERENCE, IN outRef REFERENCE, IN Environment REFERENCE) + +BEGIN + -- --DECLARE inRefReq REFERENCE TO inRef.SOAP.Body.nsconOper:CreateDocumentRequest; + -- CREATE FIELD outRef.SOAP.Body.ns19:createDocument.requestParameters; + -- DECLARE outRefReq REFERENCE TO outRef.SOAP.Body.ns19:createDocument.requestParameters; + -- DECLARE inRefReq REFERENCE TO inRef.SOAP.Body.ns15:CreateDocumentRequest.DocumentGenerationContainer; + -- DECLARE inRefDGC REFERENCE TO inRefReq.FTB; + -- DECLARE inRefFTB REFERENCE TO inRefDGC.ns31:PledgingCover; + -- -- CREATING REFERENCE FIELDS + -- CREATE LASTCHILD OF outRef DOMAIN 'SOAP'; + -- SET outRef.SOAP.Context.Namespace.(SOAP.NamespaceDecl)xmlns:soapenv = soapenv; + -- + -- CREATE FIELD outRef.SOAP.Header.ns19:Info; + -- DECLARE SOHeader REFERENCE TO outRef.SOAP.Header.ns19:Info; + -- + -- IF EXISTS(inRef.SOAP.Header.ns15:Info.consumerId[]) THEN + -- IF FIELDVALUE(inRef.SOAP.Header.ns15:Info.consumerId) <> '' THEN + -- + -- SET SOHeader.consumerId = inRef.SOAP.Header.ns15:Info.consumerId; + -- ELSE + -- SET SOHeader.consumerId = 'CID00004'; + -- END IF; + -- ELSE + -- SET SOHeader.consumerId = 'CID00004'; + -- END IF; + -- -- DECLARE outRef REFERENCE TO outRef.SOAP; + -- -- CREATE FIELD outRef.Body.nsProvider:createDocument; + -- -- CREATE LASTCHILD OF outReqPar.customer.party NAME 'partyTypeId'; + -- -- CREATE LASTCHILD OF outReqPar.customer.party.partyTypeId NAME 'scheme'; + -- -- CREATE LASTCHILD OF outReqPar.customer.party.partyTypeId NAME 'value'; + -- -- CREATE LASTCHILD OF outReqPar.customer.party NAME 'hasName'; + -- -- + -- -- DECLARE outRefReq REFERENCE TO outRef.SOAP.Body.nsProvider:createDocument; + -- -- -- DECLARE inRefDoc REFERENCE TO inRefReq.DocumentGenerationContainer.DocumentMetadata; + -- -- CREATE LASTCHILD OF outRefReq NAME 'requestParameters'; + -- -- DECLARE outReqPar REFERENCE TO outRefReq.requestParameters; + -- -- CREATE LASTCHILD OF outReqPar NAME 'document'; + -- -- DECLARE docRef REFERENCE TO outReqPar.document; + -- -- DECLARE custRef REFERENCE TO outReqPar.customer; + -- -- BUILDING REQUEST MESSAGE + -- -- SET custRef.party.partyId.scheme = 'BusinessContactNumberNL'; + -- -- SET custRef.party.partyId.value = inRefDoc.MainBorrowerId; + -- -- + -- -- SET custRef.representativeParty.partyId.scheme = 'BusinessContactNumberNL'; + -- -- SET custRef.representativeParty.partyId.value = inRefDoc.MainBorrowerId; + -- -- SET custRef.Party.PartyTypeId.Scheme = 'PartyTypeId'; + -- -- SET custRef.Party.PartyTypeId.value = '0000'; + -- -- SET custRef.representativePartyParty.PartyTypeId.Scheme = 'PartyTypeId'; + -- -- SET custRef.representativePartyParty.PartyTypeId.value = '0000'; + -- -- SET docRef.confidentialityRatingScaleId.scheme = 'ConfidentialityRatingScaleId'; + -- -- SET docRef.confidentialityRatingScaleId.value = '1'; + -- -- SET docRef.reference = inRefDoc.Subject; + -- -- SET docRef.title = inRefDoc.DocumentName; + -- -- SET docRef.documentTypeId.scheme = 'DocumentSubTypeId'; + -- -- SET docRef.documentTypeId.value = '6'; + -- -- SET docRef.documentGroupId.scheme = 'DocumentTypeId'; + -- -- SET docRef.documentGroupId.value = '7'; + -- -- SET outReqPar.organizationUnit.organizationUnitId.scheme = 'boNumber'; + -- -- SET outReqPar.channelTypeId.scheme = 'OutputchannelId'; + -- -- SET outReqPar.channelTypeId.value = 'DUM'; + -- -- SET outReqPar.dossierId.scheme = 'DossierID'; + -- -- SET outReqPar.dossierId.value = inRefDoc.DossierId; + -- -- SET outReqPar.documentPreview = 'false'; + -- -- + -- -- SET outReqPar.agreementId.scheme = 'AgreementIdNL'; + -- -- SET outReqPar.agreementId.value = inRefDoc.AgreementId; + -- -- -- Retrieve Party + -- -- + -- -- DECLARE outRefRet REFERENCE TO outRef.SOAP.Body.nsRetrieve:retrievePartyDetails; + -- -- DECLARE inRetResParam REFERENCE TO inRetRes.responseParameters; + -- -- CREATE LASTCHILD OF outRefRet NAME 'requestParameters'; + -- -- DECLARE outRetParam REFERENCE TO outRefRet.requestParameters; + -- -- SET outRetParam.partyId.value = inRefDoc.MainBorrowerId; + -- -- SET outRetParam.selectCustomerFlag = 'true'; + -- -- SET outReqPar.organizationUnit.organizationUnitId.value = inRetResParam.customer.managingOrganizationUnitId.value; + -- -- + -- -- SET outRefReq.documentPreview = 'false'; + -- -- + -- -- + -- -- SET outRetParam.partyId.value = inRefDGC.Borrower.ExternalRelationNumber; + -- -- SET outRetParam.selectPartyFlag = 'true'; + -- -- + -- -- SET outRetParam.partyId.value = inRefDGC.Borrower.ExternalRelationNumber; + -- -- SET outRetParam.selectResponsiblePartyFlag = 'true'; + -- + -- + -- + -- SET outRefReq.agreementId.scheme = 'AgreementIdNL'; + -- SET outRefReq.agreementId.value = inRefReq.DocumentMetadata.AgreementId; + -- SET outRefReq.customer.party.partyId.scheme = 'BusinessContactNumberNL'; + -- SET outRefReq.customer.party.partyId.value = inRefReq.DocumentMetadata.MainBorrowerId; + -- SET outRefReq.customer.representativeParty.partyId.scheme = 'BusinessContactNumberNL'; + -- SET outRefReq.customer.representativeParty.partyId.value = inRefReq.DocumentMetadata.MainBorrowerId; + -- SET outRefReq.customer.party.partyTypeId.scheme = 'PartyTypeId'; + -- SET outRefReq.customer.party.partyTypeId.value = '0000'; + -- SET outRefReq.customer.representativeParty.partyTypeId.scheme = 'PartyTypeId'; + -- SET outRefReq.customer.representativeParty.partyTypeId.value = '0000'; + -- SET outRefReq.document.confidentialityRatingScaleId.scheme = 'ConfidentialityRatingScaleId'; + -- SET outRefReq.document.confidentialityRatingScaleId.value = '1'; + -- SET outRefReq.document.reference = inRefReq.DocumentMetadata.Subject; + -- SET outRefReq.document.title = inRefReq.DocumentMetadata.DocumentName; + -- SET outRefReq.document.documentTypeId.scheme = 'DocumentSubTypeId'; + -- SET outRefReq.document.documentTypeId.value = '6'; + -- SET outRefReq.document.documentGroupId.scheme = 'DocumentTypeId'; + -- SET outRefReq.document.documentGroupId.value = '7'; + -- SET outRefReq.document.documentContext.scheme = 'DocumentTypeSequenceNumber'; + -- SET outRefReq.document.documentContext.value = 'DOCTYPE205'; + -- + -- SET outRefReq.document.documentContext.scheme = 'BuildingBlockID'; + -- SET outRefReq.document.documentContext.value = '99'; + -- SET outRefReq.document.documentContext.scheme = 'ConsumerSystem'; + -- SET outRefReq.document.documentContext.value = 'DQO00001'; + -- SET outRefReq.document.documentContext.scheme = 'VolgNummer'; + -- SET outRefReq.document.documentContext.value = '205'; + -- SET outRefReq.document.documentContext.scheme = 'DRMDocumentTitlle'; + -- SET outRefReq.document.documentContext.value = 'Offerte_' || CURRENT_TIMESTAMP; + -- SET outRefReq.channelTypeId.scheme = 'OutputchannelId'; + -- SET outRefReq.channelTypeId.value = 'DUM'; + -- SET outRefReq.dossierId.scheme = 'DossierID'; + -- SET outRefReq.dossierId.value = inRefReq.DocumentMetadata.DossierId; + -- SET outRefReq.organizationUnit.organizationUnitId.value = 'boNumber'; + -- -- CALL GetElectronicDocument(inRef,outRef,Environment); + -- -- SET outReqPar.electronicDocument.content.bytes = '1'; + -- -- DECLARE docRequest BLOB ; + -- -- + -- -- SET docRequest = ASBITSTREAM(outRef.XMLNSC ENCODING inRef.Properties.Encoding CCSID inRef.Properties.CodedCharSetId); + -- -- + -- -- DECLARE base64FieldType INTEGER XMLNSC.Field + XMLNSC.base64Binary; + -- -- + -- -- CREATE LASTCHILD OF outReqPar.electronicDocument.content TYPE base64FieldType NAME 'base64binary' VALUE docRequest ; + -- -- + -- -- SET outReqPar.electronicDocument.content.theBinLength = LENGTH(docRequest); + -- -- + -- -- SET outReqPar.electronicDocument.content.theContentType.scheme = 'MIME media type'; + -- -- SET outReqPar.electronicDocument.content.theContentType.value = 'Application/XML'; + -- + -- CALL GetElectronicDocument(inRef,outRef,Environment); + -- SET outRefReq.electronicDocument.content.bytes = '1'; + -- DECLARE docRequest BLOB ; + -- + -- SET docRequest = ASBITSTREAM(outRef.XMLNSC ENCODING inRef.Properties.Encoding CCSID inRef.Properties.CodedCharSetId); + -- + -- DECLARE base64FieldType INTEGER XMLNSC.Field + XMLNSC.base64Binary; + -- + -- CREATE LASTCHILD OF outRefReq.electronicDocument.content TYPE base64FieldType NAME 'base64binary' VALUE docRequest ; + -- + -- SET outRefReq.electronicDocument.content.theBinLength = LENGTH(docRequest); + -- + -- SET outRefReq.electronicDocument.content.theContentType.scheme = 'MIME media type'; + -- SET outRefReq.electronicDocument.content.theContentType.value = 'Application/XML'; + -- + DELETE FIRSTCHILD OF outRef.SOAP; + CREATE FIELD outRef.SOAP.Header; + DECLARE hdrRef REFERENCE TO outRef.SOAP.Header; + SET hdrRef.ns19:Info.consumerId = 'CID00004'; + CREATE FIELD outRef.SOAP.Body.ns19:createDocument.requestParameters; + DECLARE outRefReq REFERENCE TO outRef.SOAP.Body.ns19:createDocument.requestParameters; + DECLARE inRefReq REFERENCE TO inRef.SOAP.Body.ns15:CreateDocumentRequest.DocumentGenerationContainer; + DECLARE inRefDGC REFERENCE TO inRefReq.DocumentGenerationContainer.FTB; + DECLARE inRefFTB REFERENCE TO inRefDGC.ns31:PledgingCover; + CREATE FIELD outRefReq.customer; + DECLARE outRefCust REFERENCE TO outRefReq.customer; + CREATE FIELD outRefReq.agreementId; + DECLARE outRefAg REFERENCE TO outRefReq.agreementId; + CREATE FIELD outRefReq.document; + DECLARE outRefDoc REFERENCE TO outRefReq.document; + DECLARE var_date,var_date1,var_date2,i,j CHARACTER; + + + SET outRefCust.party.partyId.scheme = 'BusinessContactNumberNL'; + SET outRefCust.party.partyId.value = inRefReq.DocumentMetadata.MainBorrowerId; + SET outRefCust.representativeParty.partyId.scheme = 'BusinessContactNumberNL'; + SET outRefCust.representativeParty.partyId.value = inRefReq.DocumentMetadata.MainBorrowerId; + SET outRefCust.party.partyTypeId.scheme = 'PartyTypeId'; + SET outRefCust.party.partyTypeId.value = '0000'; + CREATE FIELD outRefCust.party.hasName; + DECLARE hasRef REFERENCE TO outRefCust.party.hasName; + CREATE LASTCHILD OF hasRef NAME 'fullName'; + CREATE FIELD hasRef.partyNameTypeId; + DECLARE hasPartyRef REFERENCE TO hasRef.partyNameTypeId; + CREATE LASTCHILD OF hasPartyRef NAME 'scheme'; + CREATE LASTCHILD OF hasPartyRef NAME 'value'; + + + SET outRefCust.representativeParty.partyTypeId.scheme = 'PartyTypeId'; + SET outRefCust.representativeParty.partyTypeId.value = '0000'; + -- Has name added + + SET outRefAg.scheme = 'AgreementIdNL'; + SET outRefAg.value = inRefReq.DocumentMetadata.AgreementId; + SET outRefDoc.confidentialityRatingScaleId.scheme = 'ConfidentialityRatingScaleId'; + SET outRefDoc.confidentialityRatingScaleId.value = '1'; + SET outRefDoc.reference = inRefReq.DocumentMetadata.Subject; + SET outRefDoc.title = inRefReq.DocumentMetadata.DocumentName; + + + SET outRefDoc.documentTypeId.scheme = 'DocumentSubTypeId'; + SET outRefDoc.documentTypeId.value = '6'; + SET outRefDoc.documentGroupId.scheme = 'DocumentTypeId'; + SET outRefDoc.documentGroupId.value = '7'; + + + SET outRefDoc.documentContext[1].scheme = 'DocumentTypeSequenceNumber'; + SET outRefDoc.documentContext[1].value = 'DOCTYPE205'; + + SET outRefDoc.documentContext[2].scheme = 'BuildingBlockID'; + SET outRefDoc.documentContext[2].value = '99'; + + SET outRefDoc.documentContext[3].scheme = 'ConsumerSystem'; + SET outRefDoc.documentContext[3].value = 'DQO00001'; + + SET outRefDoc.documentContext[4].scheme = 'VolgNummer'; + SET outRefDoc.documentContext[4].value = '205'; + + SET outRefDoc.documentContext[5].scheme = 'DRMDocumentTitlle'; + SET var_date = CAST(CURRENT_TIMESTAMP AS CHARACTER FORMAT 'YYYY-MM-DD hh:mm:ss.SSSS'); + SET var_date1 = SUBSTRING(var_date BEFORE ' '); + SET var_date2 = SUBSTRING(var_date AFTER ' '); + SET outRefDoc.documentContext[5].value = 'Offerte_'||var_date1||'T'||var_date2; + + + SET outRefReq.channelTypeId.scheme = 'OutputchannelId'; + SET outRefReq.channelTypeId.value = 'DUM'; + SET outRefReq.dossierId.scheme = 'DossierID'; + SET outRefReq.dossierId.value = inRefReq.DocumentMetadata.DossierId; + SET outRefReq.documentPreview = 'false'; + + SET outRefReq.organizationUnit.organizationUnitId.value = COALESCE(Environment.variable.retrieveParty.customer.managingOrganizationUnitId.value, ''); + --SET outRefReq.organizationUnit.organizationUnitId.scheme = 'boNumber'; + -- Binary to Base64 + + CALL GetElectronicDocument(inRef,outRef,Environment); + SET outRefReq.electronicDocument.content.bytes = '1'; + DECLARE docRequest BLOB ; + + SET docRequest = ASBITSTREAM(outRef.XMLNSC ENCODING inRef.Properties.Encoding CCSID inRef.Properties.CodedCharSetId); + + DECLARE base64FieldType INTEGER XMLNSC.Field + XMLNSC.base64Binary; + + CREATE LASTCHILD OF outRefReq.electronicDocument.content TYPE base64FieldType NAME 'base64binary' VALUE docRequest ; + + SET outRefReq.electronicDocument.content.theBinLength = LENGTH(docRequest); + + SET outRefReq.electronicDocument.content.theContentType.scheme = 'MIME media type'; + SET outRefReq.electronicDocument.content.theContentType.value = 'Application/XML'; + +END; +/**************************************************************************** +* A procedure that will build the response message for retrieve operation +* IN inRef : Reference to InputLocalEnvironment +* IN outRef : Reference to Soap Body. +* IN Environment: Reference to Enviroment. +*****************************************************************************/ +CREATE PROCEDURE AdapterffCreateDocumentResponse(IN inRef REFERENCE, IN outRef REFERENCE, IN Environment REFERENCE) + +BEGIN + -------------------- VARIABLE DECLARATIONS ----------------------------------------------------------------- + DECLARE inRefErr REFERENCE TO inRef.SOAP.Body; + -------------------- BUILDING RESPONSE MESSAGE ------------------------------------------------------ + IF EXISTS(inRefErr.soapenv:Fault.detail.ns19:createDocumentException[]) THEN + SET Environment.flag = 'true'; + DECLARE inRefErr1 REFERENCE TO inRefErr.soapenv:Fault.detail; + DECLARE inRefExc REFERENCE TO inRefErr1.ns19:createDocumentException; + CREATE FIELD Environment.LogData.providerError; + DECLARE envRefErr REFERENCE TO Environment.LogData.providerError; + + + SET envRefErr.code = inRefExc.code; + SET envRefErr.description = inRefExc.description; + CREATE FIELD outRef.SOAP.Body.soapenv:Fault; + DECLARE outFaultRef REFERENCE TO outRef.SOAP.Body.soapenv:Fault; + SET outFaultRef.faultcode = inRefErr.soapenv:Fault.faultcode; + SET outFaultRef.faultstring = 'Provider Error Occured.'; + + IF (inRefErr.soapenv:Fault.faultstring) IN ('SC441_DOCGEN_0700nullnull','SC441_SC441OBSERVER_ERROR_0100','100','101','201''200','202','SC441_STOREWORKFILESERVICEIMPL_ERROR_0101') THEN + CASE + + WHEN inRefErr.soapenv:Fault.faultstring = 'SC441_DOCGEN_0700nullnull' + OR inRefErr.soapenv:Fault.faultstring = 'SC441_SC441OBSERVER_ERROR_0100' + OR inRefErr.soapenv:Fault.faultstring = 100 THEN + CREATE LASTCHILD OF outFaultRef NAME 'detail'; + DECLARE detailRef REFERENCE TO outFaultRef.detail; + CREATE FIELD detailRef.nsError:CreateDocumentException.ExceptionElement; + DECLARE outRefExc REFERENCE TO detailRef.nsError:CreateDocumentException.ExceptionElement; + SET outRefExc.code = 102; + SET outRefExc.description = COALESCE(inRefExc.description,''); + + SET outRefExc.status = inRefExc.status; + + WHEN inRefErr.soapenv:Fault.faultstring = 101 + OR inRefErr.soapenv:Fault.faultstring = 201 + OR inRefErr.soapenv:Fault.faultstring = 200 + OR inRefErr.soapenv:Fault.faultstring = 202 + OR inRefErr.soapenv:Fault.faultstring = 'SC441_STOREWORKFILESERVICEIMPL_ERROR_0101' THEN + + CREATE LASTCHILD OF outFaultRef NAME 'detail'; + DECLARE detailRef REFERENCE TO outFaultRef.detail; + CREATE FIELD detailRef.nsError:CreateDocumentException.ExceptionElement; + DECLARE outRefExc REFERENCE TO detailRef.nsError:CreateDocumentException.ExceptionElement; + SET outRefExc.code = 101; + SET outRefExc.description = COALESCE(inRefExc.description,''); + SET outRefExc.status = inRefExc.status; + END CASE; + END IF; + ELSEIF EXISTS(inRefErr.soapenv:Fault[]) THEN + SET Environment.flag = 'true'; + CREATE FIELD Environment.LogData.providerError; + DECLARE envRefErr REFERENCE TO Environment.LogData.providerError; + + SET envRefErr.code = inRefErr.soapenv:Fault.faultcode; + SET envRefErr.description = inRefErr.soapenv:Fault.faultstring; + CREATE FIELD outRef.Body.soapenv:Fault; + DECLARE outFaultRef REFERENCE TO outRef.SOAP.Body.soapenv:Fault; + SET outFaultRef.faultcode = inRefErr.soapenv:Fault.faultcode; + SET outFaultRef.faultstring = 'Provider Error Occured.'; + + ELSE + DECLARE inRefReq REFERENCE TO inRefErr.ns19:createDocumentResponse.responseParameters; + + CREATE FIELD outRef.SOAP.Body.ns15:CreateDocumentResponse; + DECLARE outRefReq REFERENCE TO outRef.SOAP.Body.ns15:CreateDocumentResponse; + SET outRefReq.DocumentId = inRefReq.documentResponseGroup.documentId.value; + + END IF; + +END; +/**************************************************************************** +* A procedure that will build the request message for FR151 +* IN inRef : Reference to Soap Body +* IN outRef : Reference to OutputRoot. +* IN Environment: Reference to Enviroment. +*****************************************************************************/ +Create PROCEDURE GetElectronicDocument(IN inRef REFERENCE, IN outRef REFERENCE, IN Environment REFERENCE) + +BEGIN + CREATE LASTCHILD OF outRef DOMAIN 'XMLNSC'; + CREATE FIELD outRef.XMLNSC.documentRequest; + DECLARE outDoc REFERENCE TO outRef.XMLNSC.documentRequest; + CREATE LASTCHILD OF outDoc NAME 'electronicDocument'; + + DECLARE outElecDoc REFERENCE TO outDoc.electronicDocument; + CREATE FIELD outElecDoc.generalAttrGroup; + DECLARE outGenAttr REFERENCE TO outElecDoc.generalAttrGroup; + DECLARE inRefReq REFERENCE TO inRef.SOAP.Body.ns15:CreateDocumentRequest.DocumentGenerationContainer; + DECLARE inRefDGC REFERENCE TO inRefReq.FTB; + DECLARE inRefFTB REFERENCE TO inRefDGC.ns31:PledgingCover; + DECLARE e_date, e_date1 CHARACTER; + + SET outGenAttr.selectorLogo = '1'; + --SET e_date1 = CAST(inRefDGC.ns31:Offergroup.ns31:ExpectedOfferDate AS CHARACTER FORMAT 'yyyy-MM-dd'); + --SET outGenAttr.communicationCreationDate = e_date1; --CAST(inRefDGC.ns31:Offergroup.ns31:ExpectedOfferDate AS CHARACTER FORMAT 'yyyy-MM-dd'); + + SET outGenAttr.communicationCreationDate = '2017-09-27'; + SET e_date = CAST(inRefDGC.ns31:EffectuationDate AS CHARACTER FORMAT 'yyyy-MM-dd'); + SET outGenAttr.yearEffectiveDateDocument = SUBSTRING(e_date FROM 1 FOR 4); + + SET outGenAttr.version = '1.0.0'; + SET outGenAttr.businessLineClient = 'CMB'; + SET outGenAttr.numberAanbiedingsbrief = '1'; + SET outGenAttr.numberCreditAgreement = '2'; + SET outGenAttr.numberBKR = '0'; + SET outGenAttr.numberBegrippenlijsten = '1'; + + + SET outGenAttr.numbAccountsOverview = '0'; + SET outGenAttr.numbCreditTermsCommercial = '1'; + SET outGenAttr.numbCreditTermsConsumer = '1'; + --SET outGenAttr.numberPledgeLiveStock = '0'; + -- SET outGenAttr.numberGuarantorAgreements = '2'; + SET outGenAttr.numberGuarantorAgreements = '0'; + + SET outGenAttr.numbInfoBalancing = '0'; + + SET outGenAttr.numbClarification = '0'; + ---------------- + + SET outGenAttr.numbToelichting = '0'; + SET outGenAttr.numberBorrowers = '0'; + + SET outGenAttr.numberPledgers = '0'; + SET outGenAttr.numberPledgersAkte = '0'; + SET outGenAttr.numberPledgersWithAuction = '0'; + SET outGenAttr.numberPledgersWithLivestock = '0'; + SET outGenAttr.numberSaldoCompensatie = '1'; + + SET outGenAttr.selectorChapFinanRatio = '0'; + SET outGenAttr.numberFacilities = '0'; + SET outGenAttr.numberLoans = '0'; + SET outGenAttr.numberMortgageRegisterations = '0'; + SET outGenAttr.numberOtherCollaterals = '0'; + SET outGenAttr.selectorBorrowerIsPledger = '0'; + + + + + DECLARE count1, i, j, k INTEGER; + + + IF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '324' OR inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '175' OR inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '255' THEN + SET outGenAttr.numberPledgeAkte = '2'; + ELSE + SET outGenAttr.numberPledgeAkte = '0'; + END IF; + + + + + + IF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '314' THEN + SET outGenAttr.numberPledgeAuction = '2'; + ELSE + SET outGenAttr.numberPledgeAuction = '0'; + END IF; + + + IF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '328' THEN + SET outGenAttr.numberPledgeLiveStock = '2'; + ELSE + SET outGenAttr.numberPledgeLiveStock = '0'; + END IF; + -- IF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '324' THEN + -- SET outGenAttr.numberPledgeAkte[1] = '2'; + -- ELSE + -- SET outGenAttr.numberPledgeAkte[1] = '0'; + -- END IF; + -- + -- IF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '175' THEN + -- SET outGenAttr.numberPledgeAkte[2] = '2'; + -- ELSE + -- SET outGenAttr.numberPledgeAkte[2] = '0'; + -- END IF; + -- + -- IF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '255' THEN + -- SET outGenAttr.numberPledgeAkte[3] = '2'; + -- ELSE + -- SET outGenAttr.numberPledgeAkte[3] = '0'; + -- END IF; + -- + SET k = 1; + SET count1 = CARDINALITY(inRefDGC.ns31:BusinessAgreement.ns31:Facilities[]); + + WHILE (k<=count1) DO + + IF inRefDGC.ns31:BusinessAgreement.ns31:Facilities[k].ns31:Limit.ns31:LimitDefinitionIdentification.ns31:DefinitionCode = 'CompensatingBalanceLimit' THEN + SET outGenAttr.numberTermsSRC = NULL; + END IF; + IF count1>1 AND inRefDGC.ns31:BusinessAgreement.ns31:Facilities[k].ns31:Limit.ns31:LimitDefinitionIdentification.ns31:DefinitionCode = 'CompensatingBalanceLimit' THEN + SET outGenAttr.numberTermsSRC = '1'; + ELSE + SET outGenAttr.numberTermsSRC = '0'; + END IF; + SET k = k+1; + END WHILE; + + + SET outGenAttr.numberTerugboekformulier = '2'; + SET outGenAttr.numberWijzAlgemeen = '0'; + + SET k = 1; + --SET count1 = CARDINALITY(inRefDGC.ns31:BusinessAgreement.ns31:Facilities[]); + WHILE (k<=count1) DO + IF inRefDGC.ns31:BusinessAgreement.ns31:Facilities[k].ns31:ProductLineDefinitionIdentification.ns31:DefinitionCode = '2' THEN + + SET outGenAttr.numbProductinfoCommLoans = '1'; + ELSE + SET outGenAttr.numbProductinfoCommLoans = '0'; + END IF; + IF inRefDGC.ns31:BusinessAgreement.ns31:Facilities[k].ns31:ProductLineDefinitionIdentification.ns31:DefinitionCode = '158' OR inRefDGC.ns31:BusinessAgreement.ns31:Facilities[k].ns31:ProductLineDefinitionIdentification.ns31:DefinitionCode = '19' THEN + + SET outGenAttr.numbProductinfoRC = '1'; + ELSE + SET outGenAttr.numbProductinfoRC = '0'; + END IF; + SET k = k+1; + END WHILE; + + IF outGenAttr.numberPledgersAkte <> '0' THEN + SET outGenAttr.numbTermPledge = '1'; + ELSE + SET outGenAttr.numbTermPledge = '0'; + END IF; + --SET InputRoot.SOAP.Body.ns15:CreateDocumentRequest.DocumentGenerationContainer.FTB.ns31:BusinessAgreement.ns31:Facilities.ns31:ProductLineDefinitionIdentification + --REsponse which came from Retrieve party details will be mapped back + SET i = 1; + SET j = CARDINALITY(inRefDGC.ns31:Borrower.ns31:SelectedCounterpartyRoles[]); + WHILE (i<=j) DO + + IF inRefDGC.ns31:Borrower.ns31:SelectedCounterpartyRoles[i].ns31:DefinitionCode = 'Hoofdaanvrager' THEN + SET outGenAttr.Involved_Parties.naamAdmKlant = Environment.variable.retrieveParty.partyAddressDetails.preferredPostalAddressContactPreference.renderedContactPreference.renderedName; + SET outGenAttr.Involved_Parties.naamContactpersoon = Environment.variable.retrieveParty.partyDetails.party.partyClassification.partyClassificationRelationshipClassificationId.value; + SET outGenAttr.Involved_Parties.straatAdmKlant = Environment.variable.retrieveParty.partyAddressDetails.preferredPostalAddressContactPreference.postalAddress.streetFullName; + SET outGenAttr.Involved_Parties.huisnrAdmKlant = Environment.variable.retrieveParty.partyAddressDetails.preferredPostalAddressContactPreference.postalAddress.fullHouseNumber; + SET outGenAttr.Involved_Parties.postcodeAdmKlant = Environment.variable.retrieveParty.partyAddressDetails.preferredPostalAddressContactPreference.postalAddress.postcodeArea; + SET outGenAttr.Involved_Parties.plaatsAdmKlant = Environment.variable.retrieveParty.partyAddressDetails.preferredPostalAddressContactPreference.postalAddress.cityName; + --SET outGenAttr.Involved_Parties.accMan = COALESCE(Environment.variable.retrieveParty.responsibleParties.responsibleParty.partyName.fullName, ''); + SET outGenAttr.Involved_Parties.accMan = 'George'; + SET outGenAttr.Involved_Parties.afdeling = COALESCE(Environment.variable.retrieveParty.partyAddressDetails.managingOrganizationUnit.fullName, ''); + --SET outGenAttr.Involved_Parties.phoneAccMan = COALESCE(Environment.variable.retrieveParty.responsibleParties.responsibleParty.telephonicAddress.fullTelephoneNumber, ''); + SET outGenAttr.Involved_Parties.phoneAccMan = '3214564569'; + SET outGenAttr.Involved_Parties.geachteJaNee = 'J'; + SET outGenAttr.Involved_Parties.salutationName = 'Default Salutation'; + SET outGenAttr.numbGenTerms = Environment.variable.retrieveParty.partyDetails.party.partyRegistrationLifeCycleStatusTypeId.value; + END IF; + SET i = i+1; + END WHILE; + ----- + IF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '402' THEN + SET outGenAttr.Involved_Parties.guarantors = inRefFTB; + ELSE + SET outGenAttr.Involved_Parties.guarantors = ''; + END IF; + -- Ram + --SET outGenAttr.Involved_Parties.guarantors.nameGuarantor = Environment.variable.retrieveParty.partyDetails.preferredPostalAddressContactPreference.renderedContactPreference.renderedName; + + SET outElecDoc.selectorSaldoCompensation = '1'; + IF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '324' OR inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '255' OR inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '175' OR inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '314' OR inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '328' THEN + SET outElecDoc.selectReturnMoreDocs = '1'; + ELSE + SET outElecDoc.selectReturnMoreDocs = '0'; + END IF; + -- IF inRefFTB.ns31:Offergroup.ns31:DatePreviousSentOffer = NULL THEN + -- SET outElecDoc.datePreviousOffer = NULL; + -- ELSE + -- SET outElecDoc.datePreviousOffer = inRefFTB.ns31:Offergroup.ns31:DatePreviousSentOffer; + -- END IF; + SET outElecDoc.datePreviousOffer = '9999-12-31'; + SET outElecDoc.selectorStatusCompensationAgreement = '0'; + + IF inRefFTB = 'Registry Property Cover Type' AND inRefDGC.ns31:ExecutionGroup.ns31:Notary <> NULL THEN + SET outElecDoc.selectorNewMortgageNotaryKnown = '0'; + ELSE + SET outElecDoc.selectorNewMortgageNotaryKnown = '1'; + END IF; + + SET outElecDoc.numbLoanAgreementToReceive = '0'; + SET outElecDoc.subordinations.selectSubordination = '0'; + SET outElecDoc.subordinations.nameSubordinator = '0'; + SET outElecDoc.subordinations.nameBorrowerSubordination = '0'; + SET outGenAttr.numbSubordinations = '0'; + + IF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '324'THEN + SET outElecDoc.selectorPledgeCombo = '1'; + ELSEIF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '175' THEN + SET outElecDoc.selectorPledgeCombo = '3'; + ELSEIF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '255' THEN + SET outElecDoc.selectorPledgeCombo = '2'; + ELSEIF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '324' AND inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '255' THEN + SET outElecDoc.selectorPledgeCombo = '4'; + ELSEIF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '324' AND inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '175' THEN + SET outElecDoc.selectorPledgeCombo = '5'; + ELSEIF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '255' AND inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '175' THEN + SET outElecDoc.selectorPledgeCombo = '6'; + ELSEIF inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '324' AND inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '255' AND inRefFTB.ns31:CoverDefinitionIdentification.ns31:DefinitionCode = '175' THEN + SET outElecDoc.selectorPledgeCombo = '7'; + ELSE + SET outElecDoc.selectorPledgeCombo = '0'; + END IF; + + + SET outElecDoc.selectSRCOvk = '0'; + +END; + +CREATE FUNCTION aaaa() RETURNS BOOLEAN +BEGIN + RETURN TRUE; +END; + +CREATE FUNCTION b() RETURNS BOOLEAN + RETURN TRUE; + +CREATE FUNCTION myProc1( IN P1 INTEGER, OUT P2 INTEGER, INOUT P3 INTEGER ) + RETURNS INTEGER + LANGUAGE JAVA + EXTERNAL NAME "com.ibm.broker.test.MyClass.myMethod1"; \ No newline at end of file diff --git a/sampleWorkspace/InsertBlankLineBetweenFuncProc.esql b/sampleWorkspace/InsertBlankLineBetweenFuncProc.esql new file mode 100644 index 00000000..bc87f170 --- /dev/null +++ b/sampleWorkspace/InsertBlankLineBetweenFuncProc.esql @@ -0,0 +1,12 @@ +CREATE COMPUTE MODULE Module1 +CREATE FUNCTION Main() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + END; +CREATE Procedure Main2() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + END; + END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/KeyWordCaseCheck.esql b/sampleWorkspace/KeyWordCaseCheck.esql new file mode 100644 index 00000000..ecbd7b03 --- /dev/null +++ b/sampleWorkspace/KeyWordCaseCheck.esql @@ -0,0 +1,33 @@ +BROKER SCHEMA country.common.esql.util --Compliant +/**************************************************************************** + * This module will CALL the procedures which will do the request + transformation for all operations in a given service. + *****************************************************************************/ +CREATE COMPUTE MODULE TestFlow_Compute + Create FUNCTION Badly_Named_Function() RETURNS BOOLEAN + BEGIN + END; + + CREATE FUNCTION too_long_function_name_because_it_has_more_than_30_characters() RETURNS BOOLEAN + BEGIN -- begin is ok +-- begin + END; + CREATE FUNCTION functionOk() RETURNS BOOLEAN + BEGIN + SET I = Badly_Named_Function(); + SET OutputRoot.attach = 'AAA'; + SET Environment.ABC = 'AAA'; + DECLARE count INTEGER 0; + SET count = 15; + IF not condition THEN + END IF; + END; + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + CALL ABC(Environment); + RETURN TRUE;/* + + comment ends here + */ + end; --Noncompliant +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/NavigatingTreeCouldBeReference.esql b/sampleWorkspace/NavigatingTreeCouldBeReference.esql new file mode 100644 index 00000000..63279925 --- /dev/null +++ b/sampleWorkspace/NavigatingTreeCouldBeReference.esql @@ -0,0 +1,28 @@ +CREATE COMPUTE MODULE testModule + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.Response.details.person.age = '20'; + SET OutputRoot.XMLNSC.Response.details.person.name = 'abc'; + SET OutputRoot.XMLNSC.Response.details.person.lname = 'xyz'; + SET OutputRoot.XMLNSC.Response.details.person.middlename = 'sdsd'; + END; + CREATE FUNCTION Main2() RETURNS BOOLEAN + BEGIN + DECLARE ns000 NAMESPACE 'http://www.somewhere.com/v1'; + DECLARE ns002 NAMESPACE 'http://www.somewhere.com/v2'; + DECLARE ns001 NAMESPACE 'http://www.somewhere.com/v3'; + DECLARE inVar REFERENCE TO Environment; + DECLARE outupdateOrderWhenParametersReq_v1Ref REFERENCE TO Environment; + SET outupdateOrderWhenParametersReq_v1Ref.ns001:{'ele01'}.ns001:ele02 = FIELDVALUE(inVar.*:ele01.*:ele02); + IF EXISTS(inVar) THEN + SET outupdateOrderWhenParametersReq_v1Ref.ns001:{'ele01'}.ns001:ele02 = FIELDVALUE(inVar.*:ele01.*:ele02); + END IF; + IF EXISTS(inVar) THEN + SET outupdateOrderWhenParametersReq_v1Ref.ns001:{'ele01'}.ns001:ele02 = FIELDVALUE(inVar.*:ele01.*:ele02); + END IF; + IF EXISTS(inVar) THEN + SET outupdateOrderWhenParametersReq_v1Ref.ns001:{'ele01'}.ns001:ele02 = FIELDVALUE(inVar.*:ele01.*:ele02); + END IF; + RETURN TRUE; + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/PassthruStatementCheck.esql b/sampleWorkspace/PassthruStatementCheck.esql new file mode 100644 index 00000000..c2134fd3 --- /dev/null +++ b/sampleWorkspace/PassthruStatementCheck.esql @@ -0,0 +1,22 @@ +CREATE COMPUTE MODULE a + + CREATE PROCEDURE delete() + BEGIN + SET A = 'AAA'; + PASSTHRU 'SELECT COUNT(*) FROM Database.SHAREHOLDINGS AS S WHERE S.ACCOUNTNO = InputBody.AccountNumber' TO Database.DSN1 VALUES (); --Noncompliant + PASSTHRU 'SELECT COUNT(*) FROM Database.SHAREHOLDINGS AS S WHERE S.ACCOUNTNO = ?' TO Database.DSN1 VALUES (InputBody.AccountNumber); --Compliant + PASSTHRU 'SELECT COUNT(*) FROM Database.SHAREHOLDINGS AS S ' TO Database.DSN1; --Compliant + PASSTHRU 'SELECT COUNT(*) FROM Database.SHAREHOLDINGS AS S WHERE S.ACCOUNTNO = ? GROUP BY S:ACCOUNTNO' TO Database.DSN1 VALUES (InputBody.AccountNumber); --Compliant + PASSTHRU 'SELECT COUNT(*) FROM Database.SHAREHOLDINGS AS S WHERE S.ACCOUNTNO = ? ORDER BY S:ACCOUNTNO' TO Database.DSN1 VALUES (InputBody.AccountNumber); --Compliant + PASSTHRU (STMT, param); --Compliant + PASSTHRU ('' || STMT, param); --Compliant + + SET resultSet.rowReference[]= PASSTHRU('SELECT * FROM '||table||'.ABC A,'||table||'.BCD B,'||table|| --Noncompliant + '.CDE C WHERE A.IDENT = '||Ident||' + AND B.ID_NUMBER = '||inRef.xyz.value||' + AND B.ID_NUMBER = A.ID_NUMBER + AND C.IDENT = '||Ident||' + AND B.DATE_MODIFIED < C.DATE' TO Database.{DB}); + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/ProcessInvokingItself.esql b/sampleWorkspace/ProcessInvokingItself.esql new file mode 100644 index 00000000..327863b5 --- /dev/null +++ b/sampleWorkspace/ProcessInvokingItself.esql @@ -0,0 +1,28 @@ +CREATE COMPUTE MODULE Module1 +CREATE FUNCTION Main() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + DECLARE xyz Boolean; + SET xyz = Main(); + + END; + CREATE PROCEDURE Main2() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + DECLARE abc Boolean; + SET abc = Main2(); + + END; + CREATE PROCEDURE Main3() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + DECLARE abc Boolean; + CALL Main3(); + + END; +END MODULE; + + diff --git a/sampleWorkspace/SelfAssignment.esql b/sampleWorkspace/SelfAssignment.esql new file mode 100644 index 00000000..3680e48e --- /dev/null +++ b/sampleWorkspace/SelfAssignment.esql @@ -0,0 +1,10 @@ +CREATE COMPUTE MODULE a + + CREATE PROCEDURE set() + BEGIN + SET a = a; --Noncompliant + SET OutputRoot.a = OutputRoot.a; --Noncompliant + SET a = OutputRoot.a; --Compliant + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/SubElementName.esql b/sampleWorkspace/SubElementName.esql new file mode 100644 index 00000000..a24899de --- /dev/null +++ b/sampleWorkspace/SubElementName.esql @@ -0,0 +1,20 @@ +CREATE COMPUTE MODULE Module1 + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET Environment.Variables.startVar.xyz ='ABC'; + SET Environment.Variables.Flag ='ABC'; + SET Environment.xyz ='true'; + SET Environment.Fault.faultcode ='soapenv:Client'; + SET Environment.Variables.Mch.Sync.CORRELID + = + InputLocalEnvironment. + WrittenDestination. + MQ. + DestinationData. + msgId; + + + END; + +END MODULE; diff --git a/sampleWorkspace/UnusedVariable.esql b/sampleWorkspace/UnusedVariable.esql new file mode 100644 index 00000000..42897db2 --- /dev/null +++ b/sampleWorkspace/UnusedVariable.esql @@ -0,0 +1,35 @@ +BROKER SCHEMA generic +PATH serviceOperations; + +DECLARE ABC CONSTANT CHARACTER 'ABC'; + +CrEATE COMPUTE MODULE responseTransformation + CReATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE inRef REFERENCE TO InputRoot.SOAP.Body; + DECLARE outRef REFERENCE TO OutputRoot.SOAP.Body; + DECLARE envRef REFERENCE TO Environment.LogData.serviceOperationName; + CASE + WHEN abf = 'createAccessFacilityAgreement' THEN + DECLARE inRef REFERENCE TO InputLocalEnvironment.DFDL.BROKERMESSAGEFROMBB; + CALL createAccessFacilityAgreement_response(inRef,outRef,Environment); + WHEN abf = 'updateAccessFacilityAgreement' THEN + DECLARE inRef REFERENCE TO InputLocalEnvironment.DFDL.BROKERMESSAGEFROMBB; + CALL updateAccessFacilityAgreement_response(inRef,outRef,Environment); + END CASE; + RETURN TRUE; + END; + + CREATE FUNCTION A() RETURNS BOOLEAN + BEGIN + DECLARE refEnv REFERENCE TO Environment.LogData; + SET refEnv.serviceOperationName = InputRoot.SOAP.Context.operation; + SET refEnv.operationId = EVAL(Environment.LogData.serviceOperationName); + END; + + CREATE PROCEDURE B() + BEGIN + DECLARE inputRef REFERENCE TO InputRoot; + DECLARE inReturn REFERENCE TO inputRef.a; + END; +END MOdULE; \ No newline at end of file diff --git a/sampleWorkspace/booleanInversion.esql b/sampleWorkspace/booleanInversion.esql new file mode 100644 index 00000000..4f9e5385 --- /dev/null +++ b/sampleWorkspace/booleanInversion.esql @@ -0,0 +1,12 @@ +CREATE COMPUTE MODULE ABC + CREATE PROCEDURE caseCheck() + BEGIN + + IF NOT ( A>=B ) THEN + SET C = NOT(C false THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "false" boolean value.}} + IF var <> true THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "true" boolean value.}} + IF false = var THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "false" boolean value.}} + IF true = var THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "true" boolean value.}} + IF false <> var THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "false" boolean value.}} + IF true <> var THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "true" boolean value.}} + IF NOT true THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "true" boolean value.}} + IF NOT false THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "false" boolean value.}} + IF false AND foo() THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "false" boolean value.}} + IF foo() OR true THEN SET a=0; END IF; -- Noncompliant {{Remove the literal "true" boolean value.}} + + SET var = foo(true); -- Compliant + IF NOT foo THEN SET a=0; END IF; -- Compliant + IF foo() AND bar() THEN SET a=0; END IF; -- Compliant + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/bugfixeCASE.esql b/sampleWorkspace/bugfixeCASE.esql new file mode 100644 index 00000000..b3951baa --- /dev/null +++ b/sampleWorkspace/bugfixeCASE.esql @@ -0,0 +1,58 @@ + +CREATE COMPUTE MODULE ABC + + + + CREATE PROCEDURE caseCheck() + BEGIN + + CASE size + WHEN minimum + 0 THEN + SET description = 'small'; + WHEN minimum + 1 THEN + SET description = 'medium'; + WHEN minimum + 2 THEN + SET description = 'large'; + CALL handleLargeObject(); + ELSE + SET description = 'unknown'; + CALL handleError(); + END CASE; + +CASE + WHEN i <> 0 THEN + CALL handleI(i); + WHEN j> 1 THEN + CALL handleIZeroAndPositiveJ(j); + ELSE + CALL handleAllOtherCases(j); +END CASE; + + + SET MonthText = + CASE CurrentMonth + WHEN '01' THEN 'January' + WHEN '02' THEN 'February' + WHEN '03' THEN 'March' + WHEN '04' THEN 'April' + WHEN '05' THEN 'May' + WHEN '06' THEN 'June' + ELSE 'Second half of year' + END; + SET MonthText = + CASE + WHEN Month = '01' THEN 'January' + WHEN Month = '02' THEN 'February' + WHEN Month = '03' THEN 'March' + WHEN Month = '04' THEN 'April' + WHEN Month = '05' THEN 'May' + WHEN Month = '06' THEN 'June' + ELSE 'Second half of year' + END; + + + END; + + +END MODULE; + diff --git a/sampleWorkspace/bugfixes.esql b/sampleWorkspace/bugfixes.esql new file mode 100644 index 00000000..3f9e6b26 --- /dev/null +++ b/sampleWorkspace/bugfixes.esql @@ -0,0 +1,164 @@ +BROKER SCHEMA a.b.c +PATH x.y.z, r.t.z + +CREATE COMPUTE MODULE ABC + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + CASE chCheckSqlState + WHEN Const_getSqlDbOk() THEN + -- do nothing, just come back + WHEN Const_getSqlDbDed() THEN + SET description = 'medium'; + END CASE; + END; + + CREATE FUNCTION STD_isWeekendFromDate(IN dtValue DATE) RETURNS BOOLEAN + BEGIN + --see http://publib.boulder.ibm.com/infocenter/wmbhelp/v6r1m0/index.jsp?topic=/com.ibm.etools.mft.doc/ak05420_.htm + DECLARE intDayInWeek INTEGER EXTRACT(DAYOFWEEK FROM dtValue); + + + IF FALSE THEN + -- If we are running on PROD, simply return the given bic + RETURN ch_bic; + ELSE + -- If we are NOT running on PROD, replace the 8th Character with '0' + RETURN OVERLAY(ch_bic PLACING '0' FROM 8 FOR 1); + END IF; + + IF FALSE THEN + RETURN chValue; + ELSEIF intLength>intExpectedLength THEN + RETURN SUBSTRING(chValue FROM 1 FOR intExpectedLength); + ELSE + RETURN OVERLAY(SPACE(intExpectedLength) PLACING COALESCE(chValue, '') FROM 1); + END IF; + + END; + + CREATE PROCEDURE ThrowDisqualify() + BEGIN + THROW USER EXCEPTION + SEVERITY Const_getExceptionListSeverityError(); + + CASE chCheckSqlState + WHEN -1 THEN + SET refEnvironment.{Const_getEnvironmentName()}.STD_SFL.MRM.XGRZA10_UEBERGABE_BEREICH.XGRZA10_UEBERGABE_HEADER.XGRZA10_SEVERITY_CODE + = ' '; + WHEN 0 THEN + WHEN 2 THEN + END CASE; + + END; + + CREATE PROCEDURE escape() + BEGIN + IF data."position" = 0 THEN + END IF; + IF data."position-b" = 0 THEN + END IF; + IF data."position""-b" = 0 THEN + END IF; + END; + + CREATE PROCEDURE keywords() + BEGIN + + IF c NOT IN (A,B,c) THEN + END IF; + IF c BETWEEN a AND b THEN + END IF; + IF c BETWEEN c.from AND currentDayIntervalRef.until THEN + END IF; + + HOUSENR_LOOP: LOOP + SET tmpChar = SUBSTRING(houseNumber FROM pos FOR 1); + IF CONTAINS('0123456789', tmpChar)THEN + SET tmpNumber = tmpNumber||tmpChar; + ELSE + SET houseNumberAdd = SUBSTRING(houseNumber AFTER tmpNumber); + SET houseNumber = tmpNumber; + LEAVE HOUSENR_LOOP; + END IF; + SET pos = pos +1; + SET pos = pos -1; + IF pos > strLength THEN + LEAVE HOUSENR_LOOP; + END IF; + END LOOP; + + + +SET OutRef.From = eMailFrom; + + +DECLARE asOfDateTS TIMESTAMP CAST(asOfDate, TIME '00:00:00' AS TIMESTAMP); + +SET Environment.Variables.Source = InputRoot.XMLNSC.ns:{SAPBW_INFO_MESSAGE_TYPE}.Data.item."_-bic_-detecsour"; + +ATTACH bpFSAAssocRef TO OutputRoot.XMLNSC.ens:Envelope.ens:Body.tns:TFeed.tns:BusinessPartner[2] AS PREVIOUSSIBLING; + + IF NOT first THEN + END IF; + + DECLARE a DECIMAL ROUND(b, 2 MODE ROUND_HALF_UP); + DECLARE a DECIMAL ROUND(CAST(b AS DECIMAL(18,4)), 2 MODE ROUND_HALF_UP); + + + SET CacheFile.AccountTypeRecords[] = refAccountType.[]; + SET OutputRoot.XMLNSC.Error.ExceptionList.[I] = InputExceptionList.*[I]; + SET OutputLocalEnvironment.a = ASBITSTREAM( OutputRoot.[<] OPTIONS FolderBitStream CCSID 1208 ) ; + + DECLARE midnight TIME '00:00:00'; + SET A = FOR ALL Body.Invoice.Purchases."Item"[] AS I (I.Quantity <= 50); + DELETE FROM Database.{Source}.{Schema}.{Table} As R WHERE R.Name = 'Joe'; + + SET duration = (stateRef.Endtime - stateRef.Starttime) HOUR TO SECOND; + CALL ABC() into OutputRoot.ABC; + + CALL GFUNC_BrokerLog( + /* ifName */ 'myTestFlow', + /* msgCode */ 'KZ', /* msgType */ 'INF', + /* srcSys */ 'srcFrom', /* srcMsg */ srcMsgBitStream, + /* trgSys */ 'trgTo', /* trgMsg */ NULL, + /* shrtDsc */ 'abc-def', /* longDsc */ NULL ); + + CALL myFunc(inBody, outBody.ns01:ele01.{}[<], InputLocalEnvironment); + + END; + + +END MODULE; + +CREATE COMPUTE MODULE "TEST_ success" + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + RETURN TRUE; + END; +END MODULE; + +CREATE COMPUTE MODULE "TEST_ success" + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + RETURN TRUE; + END; +END MODULE; + +CREATE COMPUTE MODULE "TEST_ success" + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + -- Issue #106 + DECLARE STANDARD_CHARSET_RANGE CONSTANT ROW ROW( + LIST { + ROW('ABCDEFGHIJKLMNOPQRSTUVWXYZ' AS "[A-Z]"), + ROW('abcdefghijklmnopqrstuvwxyz' AS "[a-z]"), + ROW('АБВГДЕЁЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ' AS "[А-Я]"), + ROW('абвгдеёжзийклмнопрстуфхцчшщъыьэюя' AS "[а-я]"), + ROW('0123456789' AS "[0-9]") + } AS ranges[] + ); + RETURN TRUE; + END; +END MODULE; + diff --git a/sampleWorkspace/cardinalityInLoopTest.esql b/sampleWorkspace/cardinalityInLoopTest.esql new file mode 100644 index 00000000..2b405e50 --- /dev/null +++ b/sampleWorkspace/cardinalityInLoopTest.esql @@ -0,0 +1,41 @@ +CREATE COMPUTE MODULE CardinalityInLoop + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + WHILE ( I < CARDINALITY (InputRoot.MRM.A.B.C[])) DO + SET I = I + 1; + + END WHILE; + + SET ARRAY_SIZE = CARDINALITY (InputRoot.MRM.A.B.C[]); + WHILE ( I < ARRAY_SIZE ) DO + SET I = I + 1; + + END WHILE; + + L : LOOP + SET I = I + 1; + IF I > CARDINALITY (InputRoot.MRM.A.B.C[]) THEN + LEAVE L; + END IF; + END LOOP L; + + REPEAT + SET I = I + 1; + UNTIL ( I > CARDINALITY (InputRoot.MRM.A.B.C[])) + END REPEAT; + + WHILE LASTMOVE(bc) DO + SET a = CAST(b AS CHARACTER); + END WHILE; + WHILE l <= aCount DO + WHILE m <= eCount DO + DECLARE aCount1 INTEGER CARDINALITY(inRef.entity[m].association[]); + END WHILE; + END WHILE; + + + + END; + +END MODULE; diff --git a/sampleWorkspace/caseTest.esql b/sampleWorkspace/caseTest.esql new file mode 100644 index 00000000..b3bd0553 --- /dev/null +++ b/sampleWorkspace/caseTest.esql @@ -0,0 +1,48 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + CASE size + WHEN minimum + 0 THEN + SET description = 'small'; + WHEN minimum + 0 THEN + SET description = 'medium'; + ELSE + SET description = 'unknown'; + CALL handleError(); + END CASE; + + CASE size + WHEN minimum + 0 THEN + SET description = 'small'; + WHEN minimum + 1 THEN + SET description = 'medium'; + WHEN minimum + 1 THEN + SET description = 'large'; + CALL handleLargeObject(); + ELSE + SET description = 'unknown'; + CALL handleError(); + END CASE; + + CASE size + WHEN minimum + 0 THEN + SET description = 'small'; + WHEN minimum + 0 THEN + SET description = 'medium'; + END CASE; + + SET description = CASE size + WHEN minimum + 0 THEN 'small' + WHEN minimum + 1 THEN 'medium' + END; + + SET description = CASE size + WHEN minimum + 0 THEN 'small' + WHEN minimum + 1 THEN 'medium' + ELSE 'unknown' + END; + + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/caseWithTooManyWhens.esql b/sampleWorkspace/caseWithTooManyWhens.esql new file mode 100644 index 00000000..06671b5d --- /dev/null +++ b/sampleWorkspace/caseWithTooManyWhens.esql @@ -0,0 +1,43 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + CASE size -- Compliant + WHEN minimum + 0 THEN + SET description = 'small'; + WHEN minimum + 0 THEN + SET description = 'medium'; + ELSE + SET description = 'unknown'; + CALL handleError(); + END CASE; + + CASE size -- Noncompliant + WHEN minimum + 0 THEN + SET description = 'small'; + WHEN minimum + 1 THEN + SET description = 'medium'; + WHEN minimum + 1 THEN + SET description = 'large'; + CALL handleLargeObject(); + ELSE + SET description = 'unknown'; + CALL handleError(); + END CASE; + + CASE size -- Compliant + WHEN minimum + 0 THEN + SET description = 'small'; + WHEN minimum + 0 THEN + SET description = 'medium'; + END CASE; + + SET A = CASE size --Noncompliant + WHEN 1 THEN 'small' + WHEN 2 THEN 'medium' + WHEN 3 THEN 'large' + END; + + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/commentedCode.esql b/sampleWorkspace/commentedCode.esql new file mode 100644 index 00000000..983d31fe --- /dev/null +++ b/sampleWorkspace/commentedCode.esql @@ -0,0 +1,39 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + -- SET OutputRoot=InputRoot; + DECLARE end BOOLEAN TRUE; + IF FALSE THEN --Non compliant + SET OutputRoot=InputRoot; + --ELSE + -- SET OutputRoot=InputRoot; + END IF; + IF FALSE THEN --Non compliant + SET OutputRoot=InputRoot; + --ELSEIF TRUE THEN + -- SET OutputRoot=InputRoot; + END IF; + + -- Move RetryCountDown to environment + CASE size + WHEN minimum + 0 THEN + SET description = 'small'; + --WHEN minimum + 0 THEN + -- SET description = 'medium'; + ELSE + SET description = 'unknown'; + CALL handleError(); + END CASE; + --something + + --different + + END; + + + --END; + + + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/comments.esql b/sampleWorkspace/comments.esql new file mode 100644 index 00000000..85cef437 --- /dev/null +++ b/sampleWorkspace/comments.esql @@ -0,0 +1,48 @@ +BROKER SCHEMA serviceOperations +DECLARE soapenv NAMESPACE 'http://schemas.xmlsoap.org/soap/envelope/'; +DECLARE ns NAMESPACE 'http://com/abnamro/Services/AccessFacilityAgreement/v2/' ; +CREATE PROCEDURE createAccessFacilityAgreement_request(IN inRef REFERENCE, IN outRef REFERENCE) +BEGIN +-- Single Line Comment + SET outRef.Properties.MessageSet='A0071546_input.xsd'; + SET outRef.Properties.MessageType='BROKERMESSAGETOBB'; + SET outRef.Properties.CodedCharSetId = 500; + SET outRef.Properties.Encoding = 785; + /* Block Comment + please check + it.*/ + DECLARE inputRef REFERENCE TO inRef.Body.ns:createAccessFacilityAgreement.requestParameters; + CREATE LASTCHILD OF outRef DOMAIN 'DFDL'; + CREATE FIELD outRef.DFDL.BROKERMESSAGETOBB; + DECLARE outputRef REFERENCE TO outRef.DFDL.BROKERMESSAGETOBB; + SET outputRef.LL_VELD = '32154'; + SET outputRef.ZZ_VELD = +0; + IF inputRef.classificationValueId = '1' THEN + SET outputRef.IMS_TRANSAKT_KODE ='MU360T01'; + ELSEIF inputRef.classificationValueId = '0' THEN + SET outputRef.IMS_TRANSAKT_KODE ='MU326T01'; + ELSEIF inputRef.classificationValueId = TRUE THEN + SET outputRef.IMS_TRANSAKT_KODE ='MU360T01'; + ELSEIF inputRef.classificationValueId = FALSE THEN + SET outputRef.IMS_TRANSAKT_KODE ='MU326T01'; + END IF; + SET outputRef.SERVICE_INPUT_GROUP.BS_USERID = ''; + SET outputRef.SERVICE_INPUT_GROUP.BS_PROCESS_ID = ''; + SET outputRef.SERVICE_INPUT_GROUP.BS_CHANNEL_ID = ''; + SET outputRef.SERVICE_INPUT_GROUP.BS_APPLICATION_ID = ''; + SET outputRef.SERVICE_INPUT_GROUP.BS_SESSION_ID = ''; + SET outputRef.SERVICE_INPUT_GROUP.BS_LANGUAGE_CODE = ''; + SET outputRef.SERVICE_INPUT_GROUP.BS_LANGUAGE_COUNTRY_CODE = ''; + SET outputRef.SERVICE_INPUT_GROUP.BS_ISSUE_ID = ''; + SET outputRef.SERVICE_INPUT_GROUP.BS_VIEW.BS_VIEW_NR = 0; + SET outputRef.SERVICE_INPUT_GROUP.BS_MPP_BMP = ''; + SET outputRef.SERVICE_INPUT_GROUP.BS_RESERVED = ''; + SET outputRef.BROKER_VERSIE_BERICHT_NAAR_BB = ''; + SET outputRef.MO_BROKER_SUPPLIER_ID = ''; + SET outputRef.MO_SERVICE_CALL_ID = ''; + SET outputRef.MO_BROKER_PROCESS_ID =''; + SET outputRef.BROKER_DESTINATION_TRANSACTIE =''; + DECLARE bcno CHARACTER; + DECLARE modid CHARACTER; + DECLARE verid CHARACTER; +END; \ No newline at end of file diff --git a/sampleWorkspace/conditionBraces.esql b/sampleWorkspace/conditionBraces.esql new file mode 100644 index 00000000..fd18f60a --- /dev/null +++ b/sampleWorkspace/conditionBraces.esql @@ -0,0 +1,31 @@ +CREATE COMPUTE MODULE responseTransformation +CREATE FUNCTION main() RETURNS BOOLEAN +BEGIN +If oprName = 'createAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:createAccessFacilityAgreementException; + DECLARE faultRef REFERENCE TO OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:createAccessFacilityAgreementException; + SET faultRef.ExceptionElement.description = messageTextDetail; +ELSEIF oprName = 'updateAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; + DECLARE faultRef REFERENCE TO OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; + SET faultRef.ExceptionElement.description = messageTextDetail; +END IF; +WHILE count <= providerCount DO + SET faultRef.ExceptionElement.description = messageTextDetail; +END WHILE; +/*If oprName = 'createAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:createAccessFacilityAgreementException; + DECLARE faultRef REFERENCE TO OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:createAccessFacilityAgreementException; +ELSEIF oprName = 'updateAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; + DECLARE faultRef REFERENCE TO OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; + SET faultRef.ExceptionElement.description = messageTextDetail; +END IF;*/ +If oprName = 'createAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:createAccessFacilityAgreementException; +--ELSEIF oprName = 'updateAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; + DECLARE faultRef REFERENCE TO OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; +END IF; +END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/declareCombine.esql b/sampleWorkspace/declareCombine.esql new file mode 100644 index 00000000..e5e0ab14 --- /dev/null +++ b/sampleWorkspace/declareCombine.esql @@ -0,0 +1,65 @@ +BROKER SCHEMA generic +CREATE COMPUTE MODULE initialize +CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE fa EXTERNAL CHARACTER; + DECLARE frf1 EXTERNAL CHARACTER; --Noncompliant + DECLARE faultE EXTERNAL CHAR; + DECLARE fauE EXTERNAL CHAR;--Noncompliant + DECLARE faultI EXTERNAL INT; + DECLARE faI EXTERNAL INT;--Noncompliant + DECLARE faultEI EXTERNAL INTEGER; + DECLARE fauEI EXTERNAL INTEGER;--Noncompliant + DECLARE fa1 CONSTANT CHARACTER; + DECLARE frf2 CONSTANT CHARACTER; --Noncompliant + DECLARE faultE3 CONSTANT CHAR; + DECLARE fauE4 CONSTANT CHAR;--Noncompliant + DECLARE faultI5 CONSTANT INT; + DECLARE faI6 CONSTANT INT;--Noncompliant + DECLARE faultEI7 CONSTANT INTEGER; + DECLARE fauEI8 CONSTANT INTEGER;--Noncompliant + DECLARE soapenviro GMTTIMESTAMP; + DECLARE soapversion REFERENCE TO; + DECLARE faultReferen TIMESTAMP; + DECLARE soapenvir GMTTIMESTAMP;--Noncompliant + DECLARE soapenviron GMTTIME; + DECLARE faultRefere TIME; + DECLARE soapenvi GMTTIME;--Noncompliant + DECLARE soapver REFERENCE TO;--Noncompliant + DECLARE faultRf TIME;--Noncompliant + DECLARE faultRef TIMESTAMP;--Noncompliant + DECLARE providerCo INTEGER; + DECLARE providerCo INTEGER;--Noncompliant + DECLARE providerC BOOLEAN; + DECLARE providerCb BOOLEAN;--Noncompliant + DECLARE providerCF FLOAT; + DECLARE provider FLOAT;--Noncompliant + DECLARE providerCoun DATE; + DECLARE provid DATE;--Noncompliant + DECLARE soapenviroc CHAR; + DECLARE soapenvioc CHAR;--Noncompliant + DECLARE soapenvirb BLOB; + DECLARE s BLOB;--Noncompliant + DECLARE sb BIT; + DECLARE sv BIT;--Noncompliant + DECLARE faultF ROW; + DECLARE faultRfe ROW;--Noncompliant + DECLARE prov DECIMAL; + DECLARE prove DECIMAL;--Noncompliant + DECLARE provn NAMESPACE; + DECLARE proven NAMESPACE;--Noncompliant + DECLARE provN NAME; + DECLARE proveN NAME;--Noncompliant + RETURN TRUE; + END; + DECLARE myShared SHARED ROW; + DECLARE myShareS SHARED ROW; --Noncompliant [[secondary=+1]] + DECLARE myShareS2 SHARED ROW; + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE fa EXTERNAL CHARACTER; + END; +END MODULE; + + + \ No newline at end of file diff --git a/sampleWorkspace/deleteFrom.esql b/sampleWorkspace/deleteFrom.esql new file mode 100644 index 00000000..d06cf673 --- /dev/null +++ b/sampleWorkspace/deleteFrom.esql @@ -0,0 +1,22 @@ +CREATE COMPUTE MODULE a + + CREATE PROCEDURE delete() + BEGIN + DELETE FROM Database.SHAREHOLDINGS; --Noncompliant + DELETE FROM Database.SHAREHOLDINGS AS S; --Noncompliant + DELETE FROM Database.SHAREHOLDINGS AS S WHERE S.ACCOUNTNO = InputBody.AccountNumber; --Compliant + PASSTHRU('DELETE FROM users'); --Noncompliant + PASSTHRU 'DELETE FROM users'; --Noncompliant + PASSTHRU(('DELETE FROM users')); --Noncompliant + PASSTHRU(('DELETE FROM users WHERE NAME=''name''')); --Compliant + PASSTHRU(STMT); --Compliant + PASSTHRU('SELECT * FROM dual'); --Compliant + PASSTHRU loadStatement(); --Compliant + PASSTHRU (); --Compliant + SET resultSet.rowReference[] = PASSTHRU('DELETE FROM ABC A' TO Database.{dsDB}); --Noncompliant + SET resultSet.rowReference[] = PASSTHRU('DELETE FROM '||db2_table||'.ABC A' TO Database.{dsDB}); --Noncompliant + PASSTHRU('DELETE FROM '||THE(PASSTHRU('SELECT MAX(tblName) from tbls WHERE empty=1'))); --Noncompliant + PASSTHRU('DELETE FROM '||THE(PASSTHRU('SELECT MAX(tblName) from tbls WHERE empty=1'))|| ' where a=2'); --Compliant + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/empty.esql b/sampleWorkspace/empty.esql new file mode 100644 index 00000000..3149fa97 --- /dev/null +++ b/sampleWorkspace/empty.esql @@ -0,0 +1 @@ +--TODO:Ich bin fast leer \ No newline at end of file diff --git a/sampleWorkspace/emptyBlock.esql b/sampleWorkspace/emptyBlock.esql new file mode 100644 index 00000000..53f06082 --- /dev/null +++ b/sampleWorkspace/emptyBlock.esql @@ -0,0 +1,63 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE end BOOLEAN TRUE; + IF FALSE THEN + IF FALSE THEN + IF FALSE THEN + IF FALSE THEN + SET OutputRoot=InputRoot; + END IF; + ELSEIF A = B THEN + IF TRUE THEN + SET OutputRoot=InputRoot; + END IF; + ELSEIF A = B THEN + ELSEIF FALSE THEN + ELSEIF end THEN + END IF; + END IF; + ELSE + END IF; + IF FALSE THEN + ELSEIF A = B THEN + ELSE + END IF; + FOR source AS Environment.SourceData.Folder[] DO END FOR; + FOR source AS Environment.SourceData.Folder[] DO + --empty is ok + END FOR; + LOOP + + END LOOP; + REPEAT + UNTIL i>= 3 END REPEAT; + CASE + WHEN versionRef>= 1 THEN + SET Environment.Fault.faultcode='soapenv:Client'; + WHEN versionRef<1.2 THEN + SET Environment.Fault.faultcode='soapenv:Sender'; + END CASE; + CASE + WHEN versionRef>= 1 THEN + SET Environment.Fault.faultcode='soapenv:Client'; + ELSE + SET Environment.Fault.faultcode='soapenv:Sender'; + END CASE; + WHILE ( I < CARDINALITY (InputRoot.MRM.A.B.C[])) DO + SET I = I + 1; + + END WHILE; + END; + + CREATE FUNCTION Main2() RETURNS BOOLEAN + BEGIN + END; + + CREATE FUNCTION Main3() RETURNS BOOLEAN + BEGIN + --Empty blocks with comments are ok. + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/emptyMainFunction.esql b/sampleWorkspace/emptyMainFunction.esql new file mode 100644 index 00000000..58fd7edb --- /dev/null +++ b/sampleWorkspace/emptyMainFunction.esql @@ -0,0 +1,50 @@ +CREATE COMPUTE MODULE a + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + RETURN TRUE; + END; + +END MODULE; + +CREATE COMPUTE MODULE b + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + RETURN A<2; + END; + +END MODULE; + +CREATE COMPUTE MODULE c + + CREATE FUNCTION Main() RETURNS BOOLEAN + RETURN A<2; + + CREATE FUNCTION test() RETURNS BOOLEAN + BEGIN + END; + +END MODULE; + +CREATE COMPUTE MODULE d + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET a = 'a'; + END; + +END MODULE; + + +CREATE COMPUTE MODULE e + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + RETURN TRUE; + SET a = 'a'; + END; + +END MODULE; + + diff --git a/sampleWorkspace/eval.esql b/sampleWorkspace/eval.esql new file mode 100644 index 00000000..a6b60571 --- /dev/null +++ b/sampleWorkspace/eval.esql @@ -0,0 +1,9 @@ +CREATE COMPUTE MODULE a + + CREATE PROCEDURE test() + BEGIN + DECLARE returnValue BOOLEAN; --Compliant + SET returnValue = EVAL('SLEEP(1000)'); --Noncompliant {{EVAL should not be used because untested code could be injected.}} + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/functionName.esql b/sampleWorkspace/functionName.esql new file mode 100644 index 00000000..e71de591 --- /dev/null +++ b/sampleWorkspace/functionName.esql @@ -0,0 +1,16 @@ +CREATE COMPUTE MODULE TestFlow_Compute + CREATE FUNCTION Badly_Named_Function() RETURNS BOOLEAN + BEGIN + END; + CREATE FUNCTION too_long_function_name_because_it_has_more_than_30_characters() RETURNS BOOLEAN + BEGIN + END; + CREATE FUNCTION functionOk() RETURNS BOOLEAN + BEGIN + SET I = Badly_Named_Function(); + END; + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + RETURN TRUE; + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/functionParameter.esql b/sampleWorkspace/functionParameter.esql new file mode 100644 index 00000000..c425f8b5 --- /dev/null +++ b/sampleWorkspace/functionParameter.esql @@ -0,0 +1,18 @@ +CREATE COMPUTE MODULE TestFlow_Compute + CREATE FUNCTION TempFunction(IN Environment REFERENCE,IN EventCode CHARACTER,IN ReplaceValue CHARACTER, + IN RecipientTo CHARACTER,IN Retries INTEGER,IN Name CHARACTER,IN SurName CHARACTER,IN Param1 INTEGER, + OUT Param2 CHARACTER, OUT Param3 CHARACTER, OUT Param4 CHARACTER) RETURNS BOOLEAN + BEGIN + END; + CREATE FUNCTION too_long_function_name_because_it_has_more_than_30_characters() RETURNS BOOLEAN + BEGIN + END; + CREATE FUNCTION functionOk() RETURNS BOOLEAN + BEGIN + SET I = Badly_Named_Function(); + END; + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + RETURN TRUE; + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/github5.esql b/sampleWorkspace/github5.esql new file mode 100644 index 00000000..e14f45cb --- /dev/null +++ b/sampleWorkspace/github5.esql @@ -0,0 +1,29 @@ +--Test-code for bugfixes of githib issue #5 + +PATH com.pag.eai.common, com.pag.eai.common.cs, com.pag.eai.common.logger; +--The smicolon is not required by IBM but is accepted + + +CREATE COMPUTE MODULE ABC + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET refControlRecord_ = ROW( + 'a' , + 'b', + 'c' + ); + SET refControlRecord_ = ROW( + TRIM(SUBSTRING(cIdocHeader FROM 19 FOR 3)) AS LogicalMessageCode , + TRIM(SUBSTRING(cIdocHeader FROM 163 FOR 10)) AS PartnerNumberOfSender, + TRIM(SUBSTRING(cIdocHeader FROM 100 FOR 30)) + ); + SET blResult = TRANSLATE(blSource,x'00'); + CALL PASSTHRU('kbhhkhjbk'); + SET a = PASSTHRU('kbhhkhjbk'); + SET a = PASSTHRU('aaaaa' VALUES ('aaaa')); + SET rowResult.result[] = PASSTHRU('UPDATE EAI_SST.INTERFACE_DATA SET EAI_KEY = ?, EAI_VALUE = ? WHERE INTERFACE_NR = ?' VALUES('S', Environment.Variables.lastChangeId, '22202' )); + CREATE NEXTSIBLING OF refCol AS refCol REPEAT VALUE ''; + DECLARE dAlertDate DATE '1970-01-01'; + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/hardCodedCredentials.esql b/sampleWorkspace/hardCodedCredentials.esql new file mode 100644 index 00000000..541953c4 --- /dev/null +++ b/sampleWorkspace/hardCodedCredentials.esql @@ -0,0 +1,43 @@ +CREATE COMPUTE MODULE hardCodedCredentials + + DECLARE password EXTERNAL CHAR 'defaultPwd'; --Compliant + DECLARE password2 CHAR 'myPwd'; --Noncompliant + DECLARE password3 CHAR ''; --Compliant + DECLARE password4 SHARED CHAR 'defaultPwd'; --Noncompliant + DECLARE text CHAR load(); --Compliant + DECLARE text2 CHAR 'secret'; --Compliant + + CREATE PROCEDURE declareTest() + BEGIN + DECLARE pwd CHARACTER 'test'; --Noncompliant + DECLARE password CHARACTER loadPassword(); --Compliant + END; + + CREATE PROCEDURE setTest() + BEGIN + SET myPassword = 'secret'; --Noncompliant + SET thePassword = loadPassword('configFile.xml'); --Compliant + SET variableWithPasswordInIt = 'abc'; --Noncompliant + SET variableWithPwdInIt = 'abc'; --Noncompliant + SET varKennwort = 'geheim'; --Noncompliant + SET OutputRoot.abc.password = 'aaa'; --Noncompliant + SET OutputRoot.abc:*[].password = 'aaa'; --Noncompliant + SET OutputRoot.abc.password = ''; --Compliant + SET myPassword = loadPassword(); --Compliant + SET abc='abc'; --Compliant + SET abc.a.a.a='abc'; --Compliant + SET abc.a:*='abc'; --Compliant + SET abc.a:*[]='abc'; --Compliant + END; + + CREATE PROCEDURE urlTest() + BEGIN + SET variable1 = 'blabla'; + SET variable2 = 'login=a&password=xxx'; -- Noncompliant [[sc=21;ec=43]] {{Remove this hard-coded password.}} + SET variable3 = 'login=a&passwd=xxx'; -- Noncompliant + SET variable4 = 'login=a&pwd=xxx'; -- Noncompliant + SET variable5 = 'login=a&password='; + SET variable6 = 'login=a&password= '; + SET variable7 = 'login=a&losenord=xxx'; -- Noncompliant + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/hardCodedIP.esql b/sampleWorkspace/hardCodedIP.esql new file mode 100644 index 00000000..af4eb426 --- /dev/null +++ b/sampleWorkspace/hardCodedIP.esql @@ -0,0 +1,16 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET ip = '0.0.0.0'; -- Noncompliant [[sc=11;ec=20]] {{Make this IP '0.0.0.0' address configurable.}} + SET url = 'http://192.168.0.1/admin.html'; -- Noncompliant {{Make this IP '192.168.0.1' address configurable.}} + SET url2 = 'http://www.example.org'; + SET a = 42; + SET notAnIp1 = '0.0.0.1234'; + SET notAnIp2 = '1234.0.0.0'; + SET notAnIp3 = '1234.0.0.0.0.1234'; + SET notAnIp4 = '.0.0.0.0'; + SET notAnIp5 = '0.256.0.0'; + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/hardCodedURI.esql b/sampleWorkspace/hardCodedURI.esql new file mode 100644 index 00000000..0b9b1897 --- /dev/null +++ b/sampleWorkspace/hardCodedURI.esql @@ -0,0 +1,31 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET fileName = '//my-network-drive/folder/file.txt'; -- Noncompliant + SET stuffs = ''; + SET path = '/home/path/to/my/file.txt'; -- Noncompliant [[sc=14;ec=41]] {{Refactor your code to get this URI from a customizable parameter.}} + SET ABC.filename = 'c:\test'; --Noncompliant + SET filename.ABC = 'c:\test'; --Noncompliant + SET aaa.ABC = 'test'; --Compliant + SET OutputRoot.[1].filename = 'c:\test'; --Noncompliant + SET OutputRoot.{abc}.filename = 'c:\test'; --Noncompliant + + SET fileName = '\\blah\blah\'; -- Noncompliant {{Refactor your code to get this URI from a customizable parameter.}} + SET fileNAME = s; -- Compliant + SET stuff = '/home/path/to/my/file.txt'; -- Compliant - requires a variable with adequate name + SET this.fileName = '/home/path/to/my/file.txt'; -- Noncompliant + SET stuffs = '/home/path/to/my/file.txt'; -- Compliant - require a variable with adequate name + + SET fileNAME = s || '//' || s; -- Noncompliant {{Remove this hard-coded path-delimiter.}} + SET fileNAME = s || '\\' || s; -- Noncompliant {{Remove this hard-coded path-delimiter.}}t + SET fileNAME = s || 'hello' || s; -- Compliant + SET fileNAME = 'c:\blah\blah\blah.txt'; -- Noncompliant + + SET fIleNaMe = 14 - 2; + + SET v1 = s || '//' || s; -- Compliant - not a file name + + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/identicalExpressionOnBinaryOperator.esql b/sampleWorkspace/identicalExpressionOnBinaryOperator.esql new file mode 100644 index 00000000..ab61c721 --- /dev/null +++ b/sampleWorkspace/identicalExpressionOnBinaryOperator.esql @@ -0,0 +1,41 @@ +CREATE COMPUTE MODULE ABC + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + + +/** + * NOK + */ + +SET result = (a = b) AND (a = b); -- Noncompliant + +SET result = a = b OR a = b; -- Noncompliant + +SET result = 5 / 5; -- Noncompliant + +SET result = 5 - 5; -- Noncompliant + +SET result = a <> a; -- Noncompliant + +SET result = a = a; -- Noncompliant + + +/** + * OK + */ + +SET result = a = b; + +SET result = a = b AND a = c; + +SET result = a = b OR a = c; + +SET result = 5 / x; + +SET result = 5 - x; + +SET result = 'a' || 'a'; + +END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/ifTest.esql b/sampleWorkspace/ifTest.esql new file mode 100644 index 00000000..75739c69 --- /dev/null +++ b/sampleWorkspace/ifTest.esql @@ -0,0 +1,29 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE end BOOLEAN TRUE; + IF FALSE THEN + IF FALSE THEN + IF FALSE THEN + IF FALSE THEN --Non compliant + SET OutputRoot=InputRoot; + END IF; + ELSEIF A = B THEN --Compliant + IF TRUE THEN --Non compliant + SET OutputRoot=InputRoot; + END IF; + ELSEIF A = B THEN --Compliant + ELSEIF FALSE THEN --Compliant + ELSEIF end THEN + END IF; + END IF; + ELSE + END IF; + END; + + CREATE FUNCTION Main2() RETURNS BOOLEAN + BEGIN + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/initializeVariables.esql b/sampleWorkspace/initializeVariables.esql new file mode 100644 index 00000000..5c173e82 --- /dev/null +++ b/sampleWorkspace/initializeVariables.esql @@ -0,0 +1,13 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + DECLARE deployEnvironment EXTERNAL CHARACTER 'Dev'; --Compliant + DECLARE integrationEnvironment EXTERNAL CHARACTER; --Noncompliant + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE myInt INTEGER 1; --Compliant + DECLARE myInt2 INTEGER; --Noncompliant + + END; + +END MODULE; diff --git a/sampleWorkspace/issue7.esql b/sampleWorkspace/issue7.esql new file mode 100644 index 00000000..b7a34d54 --- /dev/null +++ b/sampleWorkspace/issue7.esql @@ -0,0 +1,8 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + CREATE FIELD OutputRoot.JSON.Data.item.featureList IDENTITY (JSON.Array)featureList; + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/leaveIterate.esql b/sampleWorkspace/leaveIterate.esql new file mode 100644 index 00000000..a4c8ebf0 --- /dev/null +++ b/sampleWorkspace/leaveIterate.esql @@ -0,0 +1,90 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE i INTEGER; + SET i = 0; + X : REPEAT + SET i = i + 1; + + -- Some statements 1 + + IF i IN(2, 3) THEN + ITERATE X; + END IF; + + IF i IN(2, 3) THEN + ITERATE X; + END IF; + + -- Some statements 2 + + UNTIL + i >= 4 + END REPEAT X; + X : REPEAT + SET i = i + 1; + + -- Some statements 1 + + IF i IN(2, 3) THEN + LEAVE X; + END IF; + + IF i IN(2, 3) THEN + LEAVE X; + END IF; + + -- Some statements 2 + + UNTIL + i >= 4 + END REPEAT X; + END; + + CREATE PROCEDURE Main2() + B: BEGIN + DECLARE i INTEGER; + SET i = 1; + X : WHILE i <= 3 DO + + SET i = i + 1; + LEAVE X; + END WHILE X; + + SET i = 1; + Y : LOOP + IF i>= 4 THEN + LEAVE Y; + END IF; + SET i = i + 1; + END LOOP Y; + + + END B; +CREATE PROCEDURE Main3() + BEGIN + DECLARE i INTEGER; + SET i = 1; + WHILE i <= 3 DO + + SET i = i + 1; + LEAVE X; + END WHILE; + + SET i = 1; + LOOP + IF i>= 4 THEN + LEAVE Y; + END IF; + SET i = i + 1; + END LOOP; + REPEAT + SET i = i + 1; + + UNTIL + i >= 4 + END REPEAT; + + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/loopWithoutLeave.esql b/sampleWorkspace/loopWithoutLeave.esql new file mode 100644 index 00000000..b05c3c87 --- /dev/null +++ b/sampleWorkspace/loopWithoutLeave.esql @@ -0,0 +1,13 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + + A: LOOP + LEAVE A; + END LOOP A; + B: LOOP + END LOOP B; + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/lowerCaseKeyword.esql b/sampleWorkspace/lowerCaseKeyword.esql new file mode 100644 index 00000000..3034d0ed --- /dev/null +++ b/sampleWorkspace/lowerCaseKeyword.esql @@ -0,0 +1,7 @@ +create COMPUTE MODULE TestFlow_Compute + CREATE PROCEDURE abc() + BEGIN + DECLARE COUNT, BLOB CHAR; + CREATE LASTCHILD OF Environment DOMAIN('XMLNSC') PARSE(inBitStream, InputProperties.Encoding, InputProperties.CodedCharSetId); + END; +END module; \ No newline at end of file diff --git a/sampleWorkspace/missingSyntax.esql b/sampleWorkspace/missingSyntax.esql new file mode 100644 index 00000000..314a2e6f --- /dev/null +++ b/sampleWorkspace/missingSyntax.esql @@ -0,0 +1,15 @@ +CREATE COMPUTE MODULE MyModule + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot = InputRoot; + DECLARE ref1 REFERENCE TO OutputRoot.XMLNSC; + DECLARE ref1 REFERENCE TO OutputRoot.XMLNSC.Data; + DECLARE ref1 REFERENCE TO OutputRoot.XMLNSC.aData.aOrder[1].aItem[1]; + DETACH ref1; + ATTACH ref1 + TO OutputRoot.XMLNSC.aData.aOrder[2] + AS LASTCHILD; + END; + +END MODULE; diff --git a/sampleWorkspace/moduleName.esql b/sampleWorkspace/moduleName.esql new file mode 100644 index 00000000..2866fd41 --- /dev/null +++ b/sampleWorkspace/moduleName.esql @@ -0,0 +1,9 @@ +CREATE COMPUTE MODULE Badly_Named_Module + +END MODULE; +CREATE COMPUTE MODULE too_long_module_name_because_it_has_more_than_30_characters + +END MODULE; +CREATE COMPUTE MODULE ModuleOk + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/noSchema.esql b/sampleWorkspace/noSchema.esql new file mode 100644 index 00000000..a0f07e61 --- /dev/null +++ b/sampleWorkspace/noSchema.esql @@ -0,0 +1,3 @@ +CREATE COMPUTE MODULE modulename + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/oneStatementPerLine.esql b/sampleWorkspace/oneStatementPerLine.esql new file mode 100644 index 00000000..b99fa5f5 --- /dev/null +++ b/sampleWorkspace/oneStatementPerLine.esql @@ -0,0 +1,28 @@ +BROKER SCHEMA A; +CREATE COMPUTE MODULE testModule + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET OutputRoot=InputRoot; SET OutputRoot=InputRoot; + SET OutputRoot=InputRoot; SET OutputRoot=InputRoot; SET OutputRoot=InputRoot; + IF oprName = 'createAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:createAccessFacilityAgreementException; DECLARE faultRef REFERENCE TO OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:createAccessFacilityAgreementException; + SET faultRef.ExceptionElement.description = messageTextDetail; + ELSEIF oprName = 'updateAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; DECLARE faultRef REFERENCE TO OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; + SET faultRef.ExceptionElement.description = messageTextDetail; + END IF; + + END; + + CREATE FUNCTION Main() RETURNS BOOLEAN BEGIN + + DECLARE EXIT HANDLER FOR SQLSTATE VALUE 'U11222' BEGIN + SET OutputRoot.XMLNSC.Top.WHILE.mySQLCODE = SQLCODE; + END; + + THROW USER EXCEPTION VALUES( -1, 'U11222', 42, 'error text' ); + + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/parameterWithDirection.esql b/sampleWorkspace/parameterWithDirection.esql new file mode 100644 index 00000000..e0f14e2d --- /dev/null +++ b/sampleWorkspace/parameterWithDirection.esql @@ -0,0 +1,13 @@ +CREATE COMPUTE MODULE testModule + + CREATE FUNCTION a(IN a CHAR, b INT) RETURNS BOOLEAN + BEGIN + SET OutputRoot=InputRoot; + END; + + CREATE PROCEDURE b(INOUT a CHAR, bb BOOLEAN) RETURNS BOOLEAN + BEGIN + SET OutputRoot=InputRoot; + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/pathTest.esql b/sampleWorkspace/pathTest.esql new file mode 100644 index 00000000..2ff0a972 --- /dev/null +++ b/sampleWorkspace/pathTest.esql @@ -0,0 +1,6 @@ +BROKER SCHEMA a.b.c +PATH x.y.z, r.t.z + +CREATE COMPUTE MODULE ABC + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/procedureName.esql b/sampleWorkspace/procedureName.esql new file mode 100644 index 00000000..447c73ec --- /dev/null +++ b/sampleWorkspace/procedureName.esql @@ -0,0 +1,13 @@ +CREATE COMPUTE MODULE TestFlow_Compute + CREATE PROCEDURE Badly_Named_Procedure() + BEGIN + END; + CREATE PROCEDURE tooLongProcedureNameBecauseItHasMoreThan30characters() RETURNS CHARACTER + BEGIN + END; + CREATE PROCEDURE procedureOk() + BEGIN + CALL Badly_Named_Procedure(); + SET a = tooLongProcedureNameBecauseItHasMoreThan30characters(); + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/procedureParameter.esql b/sampleWorkspace/procedureParameter.esql new file mode 100644 index 00000000..d3605914 --- /dev/null +++ b/sampleWorkspace/procedureParameter.esql @@ -0,0 +1,18 @@ +CREATE COMPUTE MODULE TestFlow_Compute + CREATE PROCEDURE ProcedureWithTooManyParams(IN Environment REFERENCE,IN EventCode CHARACTER,IN ReplaceValue CHARACTER, + IN RecipientTo CHARACTER,IN Retries INTEGER,IN Name CHARACTER,IN SurName CHARACTER,IN Param1 INTEGER, + OUT Param2 CHARACTER, OUT Param3 CHARACTER, OUT Param4 CHARACTER) + BEGIN + END; + CREATE FUNCTION too_long_function_name_because_it_has_more_than_30_characters() RETURNS BOOLEAN + BEGIN + END; + CREATE FUNCTION functionOk() RETURNS BOOLEAN + BEGIN + SET I = Badly_Named_Function(); + END; + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + RETURN TRUE; + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/propagateToLabel.esql b/sampleWorkspace/propagateToLabel.esql new file mode 100644 index 00000000..4fd342e9 --- /dev/null +++ b/sampleWorkspace/propagateToLabel.esql @@ -0,0 +1,8 @@ +CREATE COMPUTE MODULE TestFlow_Compute + CREATE PROCEDURE Procedure() + BEGIN + PROPAGATE TO LABEL 'ABC'; + PROPAGATE TO TERMINAL 1; + PROPAGATE; + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/routineComments.esql b/sampleWorkspace/routineComments.esql new file mode 100644 index 00000000..3a575c94 --- /dev/null +++ b/sampleWorkspace/routineComments.esql @@ -0,0 +1,74 @@ +CREATE COMPUTE MODULE Module1 + + CREATE FUNCTION Main() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + --This comment is irrelevant. + /* + * + * + */ + CREATE FUNCTION Main2() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + /* + * Function description goes here. + * Parameters: + * IN: REFERENCE parameter1 - Description goes here. + * INOUT: INTEGER parameter2 - Description goes here. + * OUT: TIMESTAMP result - Description goes here. + * RETURNS: BOOLEAN Description goes here. + * + */ + CREATE FUNCTION Main3() RETURNS BOOLEAN --Compliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + /* + * Function description goes here. + * But not the right syntax + */ + CREATE FUNCTION Main4() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + + + + +END MODULE; + +CREATE COMPUTE MODULE Module1 + + CREATE PROCEDURE ABC() --Noncompliant + BEGIN + SET OutputRoot.XMLNSC.A.B='ABC'; + END; + + + /* + * This comment explains the functionality of this procedure. + */ + CREATE PROCEDURE ABC() --Compliant + BEGIN + SET OutputRoot.XMLNSC.A.B='ABC'; + END; + + +END MODULE; + + diff --git a/sampleWorkspace/routineWithExcessiveReturns.esql b/sampleWorkspace/routineWithExcessiveReturns.esql new file mode 100644 index 00000000..a5e956de --- /dev/null +++ b/sampleWorkspace/routineWithExcessiveReturns.esql @@ -0,0 +1,60 @@ +CREATE COMPUTE MODULE Module1 + + CREATE FUNCTION Main() RETURNS BOOLEAN --Noncompliant + BEGIN + IF a=1 THEN + RETURN TRUE; + END IF; + IF a=1 THEN + RETURN TRUE; + END IF; + IF a=1 THEN + RETURN TRUE; + END IF; + IF a=1 THEN + RETURN TRUE; + END IF; + END; + + CREATE FUNCTION Main2() RETURNS BOOLEAN --Compliant + BEGIN + IF a=1 THEN + RETURN; + END IF; + IF a=1 THEN + RETURN; + END IF; + IF a=1 THEN + RETURN; + END IF; + END; +CREATE PROCEDURE Main3() RETURNS BOOLEAN --Noncompliant + BEGIN + IF a=1 THEN + RETURN TRUE; + END IF; + IF a=1 THEN + RETURN TRUE; + END IF; + IF a=1 THEN + RETURN TRUE; + END IF; + IF a=1 THEN + RETURN TRUE; + END IF; + END; + + CREATE PROCEDURE Main4() RETURNS BOOLEAN --Compliant + BEGIN + IF a=1 THEN + RETURN; + END IF; + IF a=1 THEN + RETURN; + END IF; + IF a=1 THEN + RETURN; + END IF; + END; + +END MODULE; diff --git a/sampleWorkspace/selectAll.esql b/sampleWorkspace/selectAll.esql new file mode 100644 index 00000000..dc79b894 --- /dev/null +++ b/sampleWorkspace/selectAll.esql @@ -0,0 +1,28 @@ +CREATE COMPUTE MODULE a + + CREATE PROCEDURE delete() + BEGIN + SET a = SELECT * FROM Database.SHAREHOLDINGS; --Noncompliant + SET a = SELECT S.* FROM Database.SHAREHOLDINGS AS S; --Noncompliant + SET a = SELECT COUNT(*) FROM Database.SHAREHOLDINGS AS S WHERE S.ACCOUNTNO = InputBody.AccountNumber; --Compliant + SET a = SELECT A FROM Database.SHAREHOLDINGS; --Compliant + SET a = SELECT S.A FROM Database.SHAREHOLDINGS AS S; --Compliant + SET a = PASSTHRU('SELECT * FROM DUAL'); --Noncompliant + SET a = PASSTHRU('SELECT A FROM B'); --Compliant + SET a = PASSTHRU('DROP SCHEMA ABC'); --Compliant + SET a = PASSTHRU(loadSQL()); --Compliant + SET resultSet.rowReference[] = PASSTHRU('SELECT * FROM '||schema||'.table1 A,' --Noncompliant + ||schema||'.table2 B,' + ||schema||'.table3 C + WHERE A.ID = '''||value1||''' + AND B.b_NUMBER = '||tree.some.value2||' + AND B.b_NUMBER = A.b_NUMBER + AND C.ID = '''||value1||''' + AND B.a_DATE < C.a_DATE' TO Database.{xyz}); + SET resultSet.rowReference[]=PASSTHRU('SELECT * FROM '||table||'.ABC A,' --Noncompliant + ||table||'.BCD B,'||table||'.CDE C + WHERE A.IDENT = '''||Ident||''' + ' TO Database.{DB}); + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/sleep.esql b/sampleWorkspace/sleep.esql new file mode 100644 index 00000000..c6118799 --- /dev/null +++ b/sampleWorkspace/sleep.esql @@ -0,0 +1,9 @@ +CREATE COMPUTE MODULE a + + CREATE PROCEDURE delete() + BEGIN + DECLARE returnValue BOOLEAN; --Compliant + SET returnValue = SLEEP(1000); --Noncompliant {{SLEEP should not be used because it blocks the executing thread.}} + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/sonar-project.properties b/sampleWorkspace/sonar-project.properties new file mode 100644 index 00000000..9cf8e1e7 --- /dev/null +++ b/sampleWorkspace/sonar-project.properties @@ -0,0 +1,15 @@ +# must be unique in a given SonarQube instance +sonar.projectKey=sample.esql + +# --- optional properties --- + +# defaults to project key +sonar.projectName=Test project ESQL +# defaults to 'not provided' +#sonar.projectVersion=1.0 + +# Path is relative to the sonar-project.properties file. Defaults to . +sonar.sources=. + +# Encoding of the source code. Default is default system encoding +sonar.sourceEncoding=UTF-8 diff --git a/sampleWorkspace/test.esql b/sampleWorkspace/test.esql new file mode 100644 index 00000000..e5d5fd65 --- /dev/null +++ b/sampleWorkspace/test.esql @@ -0,0 +1,3 @@ +CREATE COMPUTE MODULE testModule + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/tooManyParameters.esql b/sampleWorkspace/tooManyParameters.esql new file mode 100644 index 00000000..85dec758 --- /dev/null +++ b/sampleWorkspace/tooManyParameters.esql @@ -0,0 +1,43 @@ +CREATE COMPUTE MODULE Module1 + + CREATE FUNCTION Main() RETURNS BOOLEAN --Compliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + CREATE FUNCTION Main2(A INTEGER, B INTEGER, C INTEGER) RETURNS BOOLEAN --Compliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + CREATE FUNCTION Main3(A INTEGER, B INTEGER, C INTEGER, D CHAR) RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + + CREATE PROCEDURE ABC() --Compliant + BEGIN + SET OutputRoot.XMLNSC.A.B='ABC'; + END; + + + CREATE PROCEDURE ABC(A INTEGER, B INTEGER, C INTEGER) --Compliant + BEGIN + SET OutputRoot.XMLNSC.A.B='ABC'; + END; + + CREATE PROCEDURE ABC(A INTEGER, B INTEGER, C INTEGER, D CHAR) --Noncompliant + BEGIN + SET OutputRoot.XMLNSC.A.B='ABC'; + END; + + +END MODULE; + diff --git a/sampleWorkspace/trailingComments.esql b/sampleWorkspace/trailingComments.esql new file mode 100644 index 00000000..5e258563 --- /dev/null +++ b/sampleWorkspace/trailingComments.esql @@ -0,0 +1,27 @@ +CREATE COMPUTE MODULE responseTransformation +CREATE FUNCTION main() RETURNS BOOLEAN +BEGIN +---------Begin comment--------- +/*---------Begin block comment---------*/ +IF oprName = 'createAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN +-- Noncompliant@+1 {{Move this trailing comment on the previous empty line.}} + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:createAccessFacilityAgreementException; -- Create field statement. +-- ^^^^^^^^^^^^^^^^^^^^^^^^^^ + DECLARE faultRef REFERENCE TO OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:createAccessFacilityAgreementException; + SET faultRef.ExceptionElement.description = messageTextDetail; +ELSEIF oprName = 'updateAccessFacilityAgreement' OR refIpSrvcOpName = '"http://com/abnamro/Services/AccessFacilityAgreement/v2/AccessFacilityAgreement/IAccessFacilityAgreementPort"' THEN + CREATE FIELD OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; +-- Noncompliant@+1 {{Move this trailing comment on the previous empty line.}} + DECLARE faultRef REFERENCE TO OutputRoot.SOAP.Body.soapenv:Fault.detail.ns:updateAccessFacilityAgreementException; -- Declare statement trailing comment, +-- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + SET faultRef.ExceptionElement.description = messageTextDetail; +END IF; --NOSONAR +-- Noncompliant@+1 {{Move this trailing comment on the previous empty line.}} +WHILE count <= providerCount DO--while statement. +-- ^^^^^^^^^^^^^^^^^^ +-- Noncompliant@+1 {{Move this trailing comment on the previous empty line.}} + SET faultRef.ExceptionElement.description = messageTextDetail; -- Set statement. +-- ^^^^^^^^^^^^^^^^^ +END WHILE; +END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/trailingWhitespace.esql b/sampleWorkspace/trailingWhitespace.esql new file mode 100644 index 00000000..5048b2a1 --- /dev/null +++ b/sampleWorkspace/trailingWhitespace.esql @@ -0,0 +1,3 @@ +-- next line is empty and OK + +-- this line has trailing whitespace: \ No newline at end of file diff --git a/sampleWorkspace/undocumentedModule.esql b/sampleWorkspace/undocumentedModule.esql new file mode 100644 index 00000000..ffaba034 --- /dev/null +++ b/sampleWorkspace/undocumentedModule.esql @@ -0,0 +1,40 @@ +CREATE COMPUTE MODULE Module1 --Noncompliant + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + +END MODULE; + +--This comment is irrelevant. +/* + * + */ +CREATE COMPUTE MODULE Module2 --Noncompliant + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + +END MODULE; + +/* + * This module filters data base on the message type. + * It has the sample code of the second module in the ESQL file. + */ + CREATE COMPUTE MODULE Module3 --Compliant + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + +END MODULE; diff --git a/sampleWorkspace/undocumentedRoutine.esql b/sampleWorkspace/undocumentedRoutine.esql new file mode 100644 index 00000000..325b8ef6 --- /dev/null +++ b/sampleWorkspace/undocumentedRoutine.esql @@ -0,0 +1,49 @@ +CREATE COMPUTE MODULE Module1 + + CREATE FUNCTION Main() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + --This comment is irrelevant. + /* + * + * + */ + CREATE FUNCTION Main2() RETURNS BOOLEAN --Noncompliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + /* + * This comment explains the functionality of this function. + */ + CREATE FUNCTION Main3() RETURNS BOOLEAN --Compliant + BEGIN + DECLARE myInt INTEGER 1; + DECLARE myInt2 INTEGER; + + END; + + + CREATE PROCEDURE ABC() --Noncompliant + BEGIN + SET OutputRoot.XMLNSC.A.B='ABC'; + END; + + + /* + * This comment explains the functionality of this procedure. + */ + CREATE PROCEDURE ABC() --Compliant + BEGIN + SET OutputRoot.XMLNSC.A.B='ABC'; + END; + + +END MODULE; + diff --git a/sampleWorkspace/unknownMessageDomain.esql b/sampleWorkspace/unknownMessageDomain.esql new file mode 100644 index 00000000..8871667b --- /dev/null +++ b/sampleWorkspace/unknownMessageDomain.esql @@ -0,0 +1,21 @@ +CREATE COMPUTE MODULE TestFlow_Compute + CREATE FUNCTION message_domain() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.test='a'; -- Compliant + SET OutputRoot.MRM.test='a'; -- Compliant + SET OutputRoot.MLNSC.test='a'; -- Noncompliant + SET OutputRoot.XMLNS.test='a'; -- Compliant + SET OutputRoot.MQRFH2.test='a'; -- Compliant + SET OutputRoot.a.test='a'; -- Noncompliant + SET OutputRoot=InputRoot; -- Compliant + SET OutputRoot.[].a='a'; -- Compliant + SET Environment.a.b='a'; --Compliant + SET OutputRoot.*='a'; --Compliant + DECLARE refColl REFERENCE TO InputRoot.Collection.[>]; --Compliant + SET OutputRoot.HTTPReplyHeader."Content-Type"=contentType; --Compliant + CREATE FIELD OutputRoot.MQPCF; --Compliant + CREATE LASTCHILD OF OutputRoot DOMAIN ('SOAP'); --Compliant + SET a = SELECT * from Database; + RETURN TRUE; + END; +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/unreachableCode.esql b/sampleWorkspace/unreachableCode.esql new file mode 100644 index 00000000..e969debc --- /dev/null +++ b/sampleWorkspace/unreachableCode.esql @@ -0,0 +1,105 @@ +CREATE COMPUTE MODULE TestFlow_Compute + CREATE FUNCTION message_domain() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.test='a'; + SET OutputRoot.MRM.test='a'; + RETURN TRUE; --Compliant + END; + CREATE FUNCTION unreachable() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.test='a'; + RETURN TRUE; --Noncompliant + RETURN TRUE; + SET OutputRoot.MRM.test='a'; + END; + CREATE FUNCTION unreachable2() RETURNS BOOLEAN + BEGIN + SET OutputRoot.XMLNSC.test='a'; + THROW USER EXCEPTION; --Noncompliant + SET OutputRoot.MRM.test='a'; + END; + + + CREATE FUNCTION unreachableLeaveContinue () RETURNS BOOLEAN + BEGIN + DECLARE i INTEGER; + SET i = 0; + X : REPEAT + SET i = i + 1; + + ITERATE X; --Noncompliant + + + IF i IN(2, 3) THEN + ITERATE X; + END IF; + + -- Some statements 2 + + UNTIL + i >= 4 + END REPEAT X; + X : REPEAT + SET i = i + 1; + + LEAVE X; --Noncompliant + + IF i IN(2, 3) THEN + LEAVE X; + END IF; + + -- Some statements 2 + + UNTIL + i >= 4 + END REPEAT X; + END; + + +END MODULE; + +CREATE COMPUTE MODULE initialize +CREATE FUNCTION main() RETURNS BOOLEAN + BEGIN + + DECLARE VersionRef REFERENCE TO InputRoot.SOAP.Context.SOAP_Version; + + CASE + WHEN versionRef = '1.1' THEN + SET Environment.soapenv:Client = 'soapenv:Client'; + + WHEN versionRef = '1.2' THEN + SET Environment.Fault.faultcode = 'soapenv:Sender'; + +END CASE; +IF envRefVar.inputNoOfAccounts > maxNoOfAccountsCons THEN + -- throw function error + SET envRefVar.firstFlag = 'Y'; + SET envRefVar.flag='Y'; + THROW USER EXCEPTION MESSAGE 5001 VALUES('Maximum account number limit of 300 exceeded'); --Noncompliant + DECLARE fa1 CONSTANT CHARACTER; + END IF; + + +CREATE FIELD Environment.LogData; + +DECLARE refEnv REFERENCE TO Environment.LogData; + +SET refEnv.serviceOperationName = InputRoot.SOAP.Context.operation; + +SET refEnv.operationId = EVAL(Environment.LogData.serviceOperationName); + +SET refEnv.serviceName = InputRoot.SOAP.Context.service; + +SET refEnv.interfaceId = InputRoot.SOAP.Header.ns:Info.consumerId; + +SET refEnv.serviceVersion = SUBSTRING(SUBSTRING(SUBSTRING(InputRoot.SOAP.Context.portTypeNamespace AFTER InputRoot.SOAP.Context.service) AFTER '/')BEFORE '/'); +DECLARE VersionRef REFERENCE TO InputRoot.SOAP.Context.SOAP_Version; +SET OutputRoot=InputRoot; + +RETURN TRUE; + + +END; + +END MODULE; diff --git a/sampleWorkspace/uselessParentheses.esql b/sampleWorkspace/uselessParentheses.esql new file mode 100644 index 00000000..a77cf3da --- /dev/null +++ b/sampleWorkspace/uselessParentheses.esql @@ -0,0 +1,18 @@ +CREATE COMPUTE MODULE ProcessCardAccount + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + IF (A = B) THEN --Non compliant + SET a = (b);--Non compliant + ELSEIF A = B THEN --Compliant + SET a = b;--Compliant + ELSE + + END IF; + END; + + CREATE FUNCTION Main2() RETURNS BOOLEAN + BEGIN + END; + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/vaiablesSubtree.esql b/sampleWorkspace/vaiablesSubtree.esql new file mode 100644 index 00000000..5c9fce0d --- /dev/null +++ b/sampleWorkspace/vaiablesSubtree.esql @@ -0,0 +1,14 @@ +CREATE COMPUTE MODULE Module1 + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + SET Environment.ABC='ABC'; --Noncompliant + SET Environment.{abc}='ABC'; --Noncompliant + SET Environment.Variables.abc='ABC'; --Compliant + SET Environment.[]='ABC'; --Noncompliant + SET OutputRoot.XMLNSC.abc='ABC'; --Compliant + SET Environment='ABC'; --Compliant + + END; + +END MODULE; diff --git a/sampleWorkspace/variableNames.esql b/sampleWorkspace/variableNames.esql new file mode 100644 index 00000000..7fd775f0 --- /dev/null +++ b/sampleWorkspace/variableNames.esql @@ -0,0 +1,16 @@ +CREATE COMPUTE MODULE MyModule + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + DECLARE Ref1 REFERENCE TO OutputRoot.XMLNSC; + DECLARE deployEnvironment CHARACTER 'Dev'; + DECLARE a,b777_777,c CHARACTER 'a'; + DECLARE d CONSTANT CHARACTER 'a'; + DECLARE b777_777 CONSTANT CHARACTER 'a'; + DECLARE CONSTANT_WITH_SPACE CONSTANT CHARACTER 'a'; + DECLARE EXTERNAL_WITH_SPACE EXTERNAL CHARACTER 'a'; + DECLARE wrong EXTERNAL CHARACTER 'a'; + DECLARE UDP_SCHEMANAME EXTERNAL CHAR 'APP'; + END; + +END MODULE; diff --git a/sampleWorkspace/withSchema.esql b/sampleWorkspace/withSchema.esql new file mode 100644 index 00000000..ff5046f9 --- /dev/null +++ b/sampleWorkspace/withSchema.esql @@ -0,0 +1,4 @@ +BROKER SCHEMA test +CREATE COMPUTE MODULE testModule + +END MODULE; \ No newline at end of file diff --git a/sampleWorkspace/xmlnscDomain.esql b/sampleWorkspace/xmlnscDomain.esql new file mode 100644 index 00000000..9478c44e --- /dev/null +++ b/sampleWorkspace/xmlnscDomain.esql @@ -0,0 +1,27 @@ +CREATE COMPUTE MODULE Module1 + + CREATE FUNCTION Main() RETURNS BOOLEAN + BEGIN + + CREATE LASTCHILD OF OutputRoot DOMAIN 'XMLNS' NAME 'XMLNS'; --Noncompliant {{Use the XMLNSC domain instead of XMLNS.}} + CREATE LASTCHILD OF OutputRoot DOMAIN 'XML' NAME 'XML'; --Noncompliant {{Use the XMLNSC domain instead of XML.}} + CREATE LASTCHILD OF OutputRoot DOMAIN 'XMLNSC' NAME 'XMLNSC'; --Compliant + CREATE LASTCHILD OF OutputRoot DOMAIN ('XMLNS'); --Noncompliant {{Use the XMLNSC domain instead of XMLNS.}} + CREATE LASTCHILD OF OutputRoot DOMAIN (loadDomain()); --Compliant + CREATE LASTCHILD OF OutputRoot NAME 'XMLNS'; --Compliant + + SET OutputRoot.XML.abc.abc='ABC'; --Noncompliant {{Use the XMLNSC domain instead of XML.}} + SET OutputRoot.XMLNS.abc.abc='ABC'; --Noncompliant {{Use the XMLNSC domain instead of XMLNS.}} + SET OutputRoot.XMLNSC.abc.abc='ABC'; --Compliant + SET OutputRoot.XMLNSC.abc.(XML.Attribute)abc='ABC'; --Noncompliant {{Use the XMLNSC domain instead of XML.}} + SET OutputRoot.*='a'; --Compliant + SET OutputRoot.[]='a'; --Compliant + SET Environment.a = InputRoot.XMLNS; --Noncompliant {{Use the XMLNSC domain instead of XMLNS.}} + SET OutputRoot = InputRoot; --Compliant + DECLARE C INTEGER SELECT COUNT(*) FROM Database.DUAL; --Compliant + CREATE FIELD OutputRoot.JSON.Data.Item[1] IDENTITY(JSON.Object); --Compliant + + + END; + +END MODULE;