Class MergeRuleUtils


  • public final class MergeRuleUtils
    extends Object
    The merge rule utils to obtain representation or title of a MergeRule.
    • Method Detail

      • getShortRepresentation

        public static String getShortRepresentation​(MergeRule rule)
        Returns a short (4 character) representation of the merge rule.
        Parameters:
        rule - the merge rule to get short representation for, cannot be null
        Returns:
        a short string with representation, never null
      • getTitle

        public static String getTitle​(MergeRule rule)
        Returns the title of the rule for pretty printing.
        Parameters:
        rule - the merge rule to get title for, cannot be null
        Returns:
        the merge rule title, never null
      • getOrderSideTitle

        public static String getOrderSideTitle​(ComparisonSide orderSide)
        Returns the title of the order side for pretty printing.
        Parameters:
        orderSide - the order side to get title for, cannot be null
        Returns:
        the title, never null
      • mergeRuleToOrderSide

        public static ComparisonSide mergeRuleToOrderSide​(MergeRule mergeRule)
        Converts merge rule into order side.
        Parameters:
        mergeRule - the merge rule to convert, cannot be null
        Returns:
        the order side, never null
      • orderSideToMergeRule

        public static MergeRule orderSideToMergeRule​(ComparisonSide orderSide)
        Converts order side into merge rule.
        Parameters:
        orderSide - the side to convert, cannot be null
        Returns:
        the merge rule, never null