package com.speedment.runtime.join.stage;

import static java.util.Objects.requireNonNull;

/**
 *
 * @author Per Minborg
 */
public enum JoinOperator {
    EQUAL("=", true),
    NOT_EQUAL("<>", true),
    LESS_THAN("<", false),
    LESS_OR_EQUAL("<=", false),
    GREATER_THAN(">", false),
    GREATER_OR_EQUAL(">=", false),
    BETWEEN("BETWEEN", false),
    NOT_BETWEEN("NOT BETWEEN", false);

    private final String operator;
    private final boolean symetric;

    private JoinOperator(String operator, boolean symetric) {
        this.operator = requireNonNull(operator);
        this.symetric = symetric;
    }

    public String sqlOperator() {
        return operator;
    }

    public boolean isSymetric() {
        return symetric;
    }

}

@@ -747,10 +747,1015 @@
 %0A    %7D%0A%0A
+    /**%0A     * Returns a JoinOperator that would produce an equivalent predicate when%0A     * the arguments to the operator are applied swapped.%0A     *%0A     * @return a JoinOperator that would produce an equivalent predicate when%0A     * the arguments to the operator are applied swapped.%0A     * @throws IllegalStateException if no such equivalent JoinOperator exists%0A     *%0A     */%0A    public JoinOperator swapEquivalent() %7B%0A        switch (this) %7B%0A            case EQUAL:%0A                return EQUAL;%0A            case NOT_EQUAL:%0A                return NOT_EQUAL;%0A            case LESS_THAN:%0A                return GREATER_THAN;%0A            case LESS_OR_EQUAL:%0A                return GREATER_OR_EQUAL;%0A            case GREATER_THAN:%0A                return LESS_THAN;%0A            case GREATER_OR_EQUAL:%0A                return LESS_OR_EQUAL;%0A        %7D%0A        throw new IllegalStateException(%0A            %22There is no swap-equivalent %22 + JoinOperator.class.getSimpleName() + %22 to %22 + this%0A        );%0A    %7D%0A%0A
 %7D%0A

Add swapEquivalent() method