public final class ShadowRule extends Object implements org.apache.shardingsphere.infra.rule.identifier.scope.SchemaRule, org.apache.shardingsphere.infra.rule.identifier.type.DataSourceContainedRule
| Constructor and Description |
|---|
ShadowRule(AlgorithmProvidedShadowRuleConfiguration shadowRuleConfig) |
ShadowRule(ShadowRuleConfiguration shadowRuleConfig) |
public ShadowRule(ShadowRuleConfiguration shadowRuleConfig)
public ShadowRule(AlgorithmProvidedShadowRuleConfiguration shadowRuleConfig)
public Optional<ShadowAlgorithm> getDefaultShadowAlgorithm()
public Collection<String> getRelatedShadowTables(Collection<String> tableNames)
tableNames - table namespublic Collection<String> getAllShadowTableNames()
public Collection<HintShadowAlgorithm<Comparable<?>>> getAllHintShadowAlgorithms()
public Collection<HintShadowAlgorithm<Comparable<?>>> getRelatedHintShadowAlgorithms(String tableName)
tableName - table namepublic Collection<ColumnShadowAlgorithm<Comparable<?>>> getRelatedColumnShadowAlgorithms(String tableName, ShadowOperationType shadowOperationType)
tableName - table nameshadowOperationType - shadow operation typepublic Map<String,String> getRelatedShadowDataSourceMappings(String tableName)
tableName - table namepublic Map<String,String> getAllShadowDataSourceMappings()
public Optional<String> getSourceDataSourceName(String actualDataSourceName)
actualDataSourceName - actual data source namepublic Map<String,Collection<String>> getDataSourceMapper()
getDataSourceMapper in interface org.apache.shardingsphere.infra.rule.identifier.type.DataSourceContainedRulepublic String getType()
getType in interface org.apache.shardingsphere.infra.rule.ShardingSphereRuleCopyright © 2022 The Apache Software Foundation. All rights reserved.