@@ -0,0 +1,2970 @@
+/*%0A * Copyright 2020 B2i Healthcare Pte Ltd, http://b2i.sg%0A * %0A * Licensed under the Apache License, Version 2.0 (the %22License%22);%0A * you may not use this file except in compliance with the License.%0A * You may obtain a copy of the License at%0A *%0A *      http://www.apache.org/licenses/LICENSE-2.0%0A *%0A * Unless required by applicable law or agreed to in writing, software%0A * distributed under the License is distributed on an %22AS IS%22 BASIS,%0A * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.%0A * See the License for the specific language governing permissions and%0A * limitations under the License.%0A */%0Apackage com.b2international.snowowl.core.compare;%0A%0Aimport java.util.Objects;%0Aimport java.util.function.BiFunction;%0A%0Aimport com.b2international.snowowl.core.domain.ConceptMapMapping;%0A%0A/**%0A * @since 7.11%0A */%0Apublic enum ConceptMapCompareConfigurationProperties %7B%0A%0A%09CODE_SYSTEM(%0A%09%09%09%22Code System%22, %0A%09%09%09(member1, member2) -%3E Objects.equals(member1.getSourceComponentURI().codeSystem(), member2.getSourceComponentURI().codeSystem()),%0A%09%09%09(member1, member2) -%3E Objects.equals(member1.getTargetComponentURI().codeSystem(), member2.getTargetComponentURI().codeSystem())%0A%09%09%09),%0A%0A%09TERM(%0A%09%09%09%22Term%22, %0A%09%09%09(member1, member2) -%3E Objects.equals(member1.getSourceTerm(), member2.getSourceTerm()),%0A%09%09%09(member1, member2) -%3E Objects.equals(member1.getTargetTerm(), member2.getTargetTerm())%0A%09%09%09),%0A%0A%09CODE(%0A%09%09%09%22Code%22, %0A%09%09%09(member1, member2) -%3E Objects.equals(member1.getSourceComponentURI().identifier(), member2.getSourceComponentURI().identifier()),%0A%09%09%09(member1, member2) -%3E Objects.equals(member1.getTargetComponentURI().identifier(), member2.getTargetComponentURI().identifier())%0A%09%09%09);%0A%0A%09private final String label;%0A%09private final BiFunction%3CConceptMapMapping, ConceptMapMapping, Boolean%3E getSourceEqualFunction;%0A%09private final BiFunction%3CConceptMapMapping, ConceptMapMapping, Boolean%3E getTargetEqualFunction;%0A%0A%09private ConceptMapCompareConfigurationProperties(final String label, %0A%09%09%09final BiFunction%3CConceptMapMapping, ConceptMapMapping, Boolean%3E getSourceEqualFunction, %0A%09%09%09final BiFunction%3CConceptMapMapping, ConceptMapMapping, Boolean%3E getTargetEqualFunction) %7B%0A%09%09this.label = label;%0A%09%09this.getSourceEqualFunction = getSourceEqualFunction;%0A%09%09this.getTargetEqualFunction = getTargetEqualFunction;%0A%09%7D%0A%0A%09public String getLabel() %7B%0A%09%09return label;%0A%09%7D%0A%0A%09public BiFunction%3CConceptMapMapping, ConceptMapMapping, Boolean%3E getSourceEqualFunction() %7B%0A%09%09return getSourceEqualFunction;%0A%09%7D%0A%0A%09public BiFunction%3CConceptMapMapping, ConceptMapMapping, Boolean%3E getTargetEqualFunction() %7B%0A%09%09return getTargetEqualFunction;%0A%09%7D%0A%0A%09public Boolean isSourceEqual(ConceptMapMapping member1, ConceptMapMapping member2) %7B%0A%09%09return getSourceEqualFunction.apply(member1, member2);%0A%09%7D%0A%0A%09public Boolean isTargetEqual(ConceptMapMapping member1, ConceptMapMapping member2) %7B%0A%09%09return getTargetEqualFunction.apply(member1, member2);%0A%09%7D%0A%0A%09@Override%0A%09public String toString() %7B%0A%09%09return label;%0A%09%7D%0A%09%0A%7D%0A

add enum for config props