Interface INameMatcher

All Known Implementing Classes:
DefaultNameMatcher, VendorNameMatcher

public interface INameMatcher
Interface for matching names (tables, columns) with various rules. Handles case sensitivity, database-specific matching rules, etc. Different databases have different name matching rules: - MySQL: case-insensitive on Windows, case-sensitive on Unix - PostgreSQL: case-sensitive for quoted identifiers - Oracle: case-insensitive, converts to uppercase - SQL Server: depends on collation
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Check if the matcher is case-sensitive
    boolean
    matches(String name1, String name2)
    Check if two names match according to the matching rules.
    boolean
    matchesPattern(String name, String pattern)
    Check if a name is a valid match for a pattern.
    Normalize a name according to matching rules.
  • Method Details

    • matches

      boolean matches(String name1, String name2)
      Check if two names match according to the matching rules.
      Parameters:
      name1 - First name
      name2 - Second name
      Returns:
      true if names match
    • matchesPattern

      boolean matchesPattern(String name, String pattern)
      Check if a name is a valid match for a pattern. Used for prefix matching, wildcard matching, etc.
      Parameters:
      name - The name to test
      pattern - The pattern to match against
      Returns:
      true if name matches pattern
    • normalize

      Normalize a name according to matching rules. E.g., convert to uppercase for Oracle, lowercase for PostgreSQL unquoted.
      Parameters:
      name - Name to normalize
      Returns:
      Normalized name
    • isCaseSensitive

      boolean isCaseSensitive()
      Check if the matcher is case-sensitive