public class TSQLResolverConfig extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
GUESS_COLUMN_STRATEGY_FARTHEST
Pick the last candidate table (farthest in FROM clause order)
|
static String[] |
GUESS_COLUMN_STRATEGY_NAMES
Human-readable names for strategy values
|
static int |
GUESS_COLUMN_STRATEGY_NEAREST
Pick the first candidate table (nearest in FROM clause order)
|
static int |
GUESS_COLUMN_STRATEGY_NOT_PICKUP
Do not pick any candidate, leave as unresolved/ambiguous
|
| Constructor and Description |
|---|
TSQLResolverConfig() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canGuessWithConfidence(double confidence)
Check if a confidence value is sufficient to allow guessing.
|
void |
clearGuessColumnStrategy()
Clear any custom guess column strategy, reverting to TBaseType.GUESS_COLUMN_STRATEGY.
|
static TSQLResolverConfig |
createCaseSensitive()
Create configuration for case-sensitive matching
|
static TSQLResolverConfig |
createDefault()
Create a default configuration
|
static TSQLResolverConfig |
createForVendor(EDbVendor vendor)
Create configuration for a specific database vendor.
|
static TSQLResolverConfig |
createForVendorWithDatatype(EDbVendor vendor)
Create configuration for a specific database vendor with datatype display enabled.
|
static TSQLResolverConfig |
createStandalone()
Create configuration for standalone mode (no legacy sync)
|
static TSQLResolverConfig |
createWithCTE()
Create configuration with showCTE enabled.
|
static TSQLResolverConfig |
createWithDatatype()
Create configuration with showDatatype enabled.
|
DisplayNameMode |
getDisplayNameMode()
Get the display name mode.
|
DisplayNamePolicy |
getDisplayNamePolicy()
Get the display name policy.
|
int |
getGuessColumnStrategy()
Get the strategy for handling ambiguous columns.
|
String |
getGuessColumnStrategyName()
Get the human-readable name for the current strategy.
|
double |
getLegacySyncMinConfidence() |
int |
getMaxIterations() |
double |
getMinConfidenceToGuess()
Get the minimum confidence threshold to allow guessing.
|
double |
getMinDefiniteConfidence()
Get the minimum confidence threshold for definite resolutions.
|
double |
getMinProgressRate() |
INameMatcher |
getNameMatcher() |
int |
getStablePassesForConvergence() |
EDbVendor |
getVendor()
Get the database vendor, if set.
|
boolean |
hasCustomGuessColumnStrategy()
Check if a custom guess column strategy has been set on this config.
|
boolean |
hasVendor()
Check if vendor-specific name matching is enabled.
|
boolean |
isAllowGuessWhenAllInferred()
Check if guessing is allowed when all candidates are inferred.
|
boolean |
isCollectFullCandidates() |
boolean |
isDefiniteConfidence(double confidence)
Check if a confidence value represents a definite resolution.
|
boolean |
isEvidenceCollectionEnabled()
Deprecated.
Use NamespaceEnhancer instead
|
boolean |
isLegacyCompatibilityEnabled() |
boolean |
isShowCTE()
Check if CTE (Common Table Expression) tables and columns should be shown in output.
|
boolean |
isShowDatatype()
Check if datatype information should be shown for columns from CREATE TABLE statements.
|
boolean |
isStripDelimitersForDisplay()
Check if delimiters should be stripped for display.
|
void |
setAllowGuessWhenAllInferred(boolean allow)
Set whether to allow guessing when all candidates are inferred.
|
void |
setCollectFullCandidates(boolean collectFullCandidates) |
void |
setDisplayNameMode(DisplayNameMode mode)
Set the display name mode.
|
void |
setDisplayNamePolicy(DisplayNamePolicy policy)
Set the display name policy.
|
void |
setEvidenceCollectionEnabled(boolean enabled)
Deprecated.
Use NamespaceEnhancer instead
|
void |
setGuessColumnStrategy(int strategy)
Set the strategy for handling ambiguous columns.
|
void |
setLegacyCompatibilityEnabled(boolean enabled) |
void |
setLegacySyncMinConfidence(double threshold) |
void |
setMaxIterations(int maxIterations) |
void |
setMinConfidenceToGuess(double threshold)
Set the minimum confidence threshold to allow guessing.
|
void |
setMinDefiniteConfidence(double threshold)
Set the minimum confidence threshold for definite resolutions.
|
void |
setMinProgressRate(double minProgressRate) |
void |
setNameMatcher(INameMatcher nameMatcher) |
void |
setShowCTE(boolean showCTE)
Set whether to show CTE (Common Table Expression) tables and columns in output.
|
void |
setShowDatatype(boolean showDatatype)
Set whether to show datatype information for columns from CREATE TABLE statements.
|
void |
setStablePassesForConvergence(int stablePasses) |
void |
setStripDelimitersForDisplay(boolean stripDelimiters)
Set whether to strip delimiters for display.
|
void |
setVendor(EDbVendor vendor)
Set the database vendor and update name matcher accordingly.
|
String |
toString() |
public static final int GUESS_COLUMN_STRATEGY_NEAREST
public static final int GUESS_COLUMN_STRATEGY_FARTHEST
public static final int GUESS_COLUMN_STRATEGY_NOT_PICKUP
public static final String[] GUESS_COLUMN_STRATEGY_NAMES
public TSQLResolverConfig()
public INameMatcher getNameMatcher()
public void setNameMatcher(INameMatcher nameMatcher)
public boolean isLegacyCompatibilityEnabled()
public void setLegacyCompatibilityEnabled(boolean enabled)
public double getLegacySyncMinConfidence()
public void setLegacySyncMinConfidence(double threshold)
public int getMaxIterations()
public void setMaxIterations(int maxIterations)
public double getMinProgressRate()
public void setMinProgressRate(double minProgressRate)
public int getStablePassesForConvergence()
public void setStablePassesForConvergence(int stablePasses)
public boolean isCollectFullCandidates()
public void setCollectFullCandidates(boolean collectFullCandidates)
public boolean isEvidenceCollectionEnabled()
public void setEvidenceCollectionEnabled(boolean enabled)
public boolean isShowDatatype()
public void setShowDatatype(boolean showDatatype)
showDatatype - true to include datatype informationpublic boolean isShowCTE()
public void setShowCTE(boolean showCTE)
showCTE - true to include CTE tables and columnspublic DisplayNameMode getDisplayNameMode()
public void setDisplayNameMode(DisplayNameMode mode)
mode - the display name modepublic DisplayNamePolicy getDisplayNamePolicy()
public void setDisplayNamePolicy(DisplayNamePolicy policy)
policy - the display name policypublic boolean isStripDelimitersForDisplay()
public void setStripDelimitersForDisplay(boolean stripDelimiters)
stripDelimiters - true to strip delimiterspublic int getGuessColumnStrategy()
public void setGuessColumnStrategy(int strategy)
strategy - One of GUESS_COLUMN_STRATEGY_NEAREST, GUESS_COLUMN_STRATEGY_FARTHEST,
or GUESS_COLUMN_STRATEGY_NOT_PICKUPpublic boolean hasCustomGuessColumnStrategy()
public void clearGuessColumnStrategy()
public String getGuessColumnStrategyName()
public double getMinDefiniteConfidence()
public void setMinDefiniteConfidence(double threshold)
threshold - Threshold value [0.0, 1.0]public double getMinConfidenceToGuess()
public void setMinConfidenceToGuess(double threshold)
threshold - Threshold value [0.0, 1.0]public boolean isAllowGuessWhenAllInferred()
public void setAllowGuessWhenAllInferred(boolean allow)
allow - true to allow guessing with inferred candidatespublic boolean isDefiniteConfidence(double confidence)
confidence - The confidence value to checkpublic boolean canGuessWithConfidence(double confidence)
confidence - The confidence value to checkpublic static TSQLResolverConfig createDefault()
public static TSQLResolverConfig createCaseSensitive()
public static TSQLResolverConfig createStandalone()
public static TSQLResolverConfig createWithDatatype()
public static TSQLResolverConfig createWithCTE()
public static TSQLResolverConfig createForVendor(EDbVendor vendor)
This factory method creates a configuration with vendor-specific name matching rules. The VendorNameMatcher uses IdentifierService to properly handle case sensitivity and quote handling for each vendor.
Example vendor behaviors:
vendor - the database vendorpublic static TSQLResolverConfig createForVendorWithDatatype(EDbVendor vendor)
vendor - the database vendorpublic EDbVendor getVendor()
public void setVendor(EDbVendor vendor)
vendor - the database vendorpublic boolean hasVendor()