Interface RuleDefinitionDropUpdater<T extends org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement,R extends RuleConfiguration>

Type Parameters:
T - type of SQL statement
R - type of rule configuration
All Superinterfaces:
RuleDefinitionUpdater<T,R>, org.apache.shardingsphere.infra.util.spi.type.typed.TypedSPI

public interface RuleDefinitionDropUpdater<T extends org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement,R extends RuleConfiguration> extends RuleDefinitionUpdater<T,R>
Drop rule definition updater.
  • Method Details

    • updateCurrentRuleConfiguration

      boolean updateCurrentRuleConfiguration(T sqlStatement, R currentRuleConfig)
      Update current rule configuration.
      Parameters:
      sqlStatement - SQL statement
      currentRuleConfig - current rule configuration to be updated
      Returns:
      current rule configuration is empty or not
    • isExistRuleConfig

      default boolean isExistRuleConfig(R currentRuleConfig)
      Whether there is configuration.
      Parameters:
      currentRuleConfig - current rule configuration
      Returns:
      configuration exists or does not exist
    • hasAnyOneToBeDropped

      default boolean hasAnyOneToBeDropped(T sqlStatement, R currentRuleConfig)
      Whether there is dropped data.
      Parameters:
      sqlStatement - SQL statement
      currentRuleConfig - current rule configuration
      Returns:
      dropped data exists or does not exist
    • getIdenticalData

      default Collection<String> getIdenticalData(Collection<String> currentRules, Collection<String> toBeDroppedRules)
      Get identical data.
      Parameters:
      currentRules - collection
      toBeDroppedRules - collection
      Returns:
      identical data