- return getPriority() == that.getPriority() &&
- getTableId() == that.getTableId() &&
- getCookie().equals(that.getCookie()) &&
- MatchComparatorFactory.createMatch().areObjectsEqual(version, getMatch(), that.getMatch());
+ private boolean equalMatch(final Match input) {
+ GeneralAugMatchNodesNodeTableFlow thisAug = match.augmentation(GeneralAugMatchNodesNodeTableFlow.class);
+ GeneralAugMatchNodesNodeTableFlow inputAug = input.augmentation(GeneralAugMatchNodesNodeTableFlow.class);
+ if (thisAug != inputAug) {
+ if (thisAug != null) {
+ if (inputAug == null) {
+ return false;
+ }
+ if (!Objects.equals(match.getEthernetMatch(), input.getEthernetMatch())) {
+ return false;
+ }
+ if (!Objects.equals(match.getIcmpv4Match(), input.getIcmpv4Match())) {
+ return false;
+ }
+ if (!Objects.equals(match.getIcmpv6Match(), input.getIcmpv6Match())) {
+ return false;
+ }
+ if (!Objects.equals(match.getInPhyPort(), input.getInPhyPort())) {
+ return false;
+ }
+ if (!Objects.equals(match.getInPort(), input.getInPort())) {
+ return false;
+ }
+ if (!Objects.equals(match.getIpMatch(), input.getIpMatch())) {
+ return false;
+ }
+ if (!Objects.equals(match.getLayer3Match(), input.getLayer3Match())) {
+ return false;
+ }
+ if (!Objects.equals(match.getLayer4Match(), input.getLayer4Match())) {
+ return false;
+ }
+ if (!Objects.equals(match.getMetadata(), input.getMetadata())) {
+ return false;
+ }
+ if (!Objects.equals(match.getProtocolMatchFields(), input.getProtocolMatchFields())) {
+ return false;
+ }
+ if (!Objects.equals(match.getTcpFlagsMatch(), input.getTcpFlagsMatch())) {
+ return false;
+ }
+ if (!Objects.equals(match.getTunnel(), input.getTunnel())) {
+ return false;
+ }
+ if (!Objects.equals(match.getVlanMatch(), input.getVlanMatch())) {
+ return false;
+ }
+ for (ExtensionList inputExtensionList : inputAug.nonnullExtensionList().values()) {
+ if (!thisAug.nonnullExtensionList().containsValue(inputExtensionList)) {
+ return false;
+ }
+ }
+ }
+ } else {
+ return getMatch().equals(input);
+ }
+ return true;