strongduanmu commented on a change in pull request #10486:
URL: https://github.com/apache/shardingsphere/pull/10486#discussion_r639523292



##########
File path: 
shardingsphere-features/shardingsphere-sharding/shardingsphere-sharding-common/src/main/java/org/apache/shardingsphere/sharding/rule/ShardingRule.java
##########
@@ -339,18 +339,18 @@ public boolean tableRuleExists(final Collection<String> 
logicTableNames) {
      * Judge if single table rule exists or not.
      *
      * @param logicTableNames logic table names
-     * @return whether single table rule exists for logic tables
+     * @return whether single table rule exists for logic tables or not
      */
     public boolean singleTableRuleExists(final Collection<String> 
logicTableNames) {
         return 
singleTableRules.keySet().stream().anyMatch(logicTableNames::contains);
     }
     
     /**
-     * Judge is sharding column or not.
+     * Judge if a column is sharding column or not.

Review comment:
       @KSMASTERS `Judge whether a column is sharding column or not.` may be 
better.

##########
File path: 
shardingsphere-features/shardingsphere-sharding/shardingsphere-sharding-common/src/main/java/org/apache/shardingsphere/sharding/rule/ShardingRule.java
##########
@@ -238,12 +238,12 @@ public TableRule getTableRule(final String 
logicTableName) {
         }
         throw new ShardingSphereConfigurationException("Cannot find table rule 
with logic table: '%s'", logicTableName);
     }
-    

Review comment:
       @KSMASTERS Please keep indents consistent with the previous one.

##########
File path: 
shardingsphere-features/shardingsphere-sharding/shardingsphere-sharding-common/src/main/java/org/apache/shardingsphere/sharding/rule/ShardingRule.java
##########
@@ -273,50 +273,50 @@ public boolean isAllBindingTables(final 
Collection<String> logicTableNames) {
     }
     
     /**
-     * Judge logic tables is all belong to broadcast encryptors.
+     * Judge whether all logic tables are broadcast encryptors or not.
      *
      * @param logicTableNames logic table names
-     * @return logic tables is all belong to broadcast encryptors or not
+     * @return whether all logic tables are binding encryptors or not
      */
     public boolean isAllBroadcastTables(final Collection<String> 
logicTableNames) {
         return !logicTableNames.isEmpty() && 
logicTableNames.stream().allMatch(this::isBroadcastTable);
     }
     
     /**
-     * Judge logic tables is all belong to sharding tables.
+     * Judge whether all logic tables are sharding tables or not.
      *
      * @param logicTableNames logic table names
-     * @return logic tables is all belong to sharding tables or not
+     * @return whether all logic tables are sharding tables or not
      */
     public boolean isAllShardingTables(final Collection<String> 
logicTableNames) {
         return logicTableNames.stream().allMatch(each -> 
findTableRule(each).isPresent());
     }
     
     /**
-     * Judge logic table is belong to sharding tables.
+     * Judge whether logic table is sharding table or not.
      *
      * @param logicTableName logic table name
-     * @return logic table is belong to sharding tables or not
+     * @return whether logic table is sharding table or not
      */
     public boolean isShardingTable(final String logicTableName) {
         return findTableRule(logicTableName).isPresent();
     }
     
     /**
-     * Judge logic table is belong to broadcast tables.
+     * Judge whether logic table are broadcast tables or not.

Review comment:
       @KSMASTERS `Judge whether logic table is broadcast table or not.` may be 
better.

##########
File path: 
shardingsphere-features/shardingsphere-sharding/shardingsphere-sharding-common/src/main/java/org/apache/shardingsphere/sharding/rule/ShardingRule.java
##########
@@ -273,50 +273,50 @@ public boolean isAllBindingTables(final 
Collection<String> logicTableNames) {
     }
     
     /**
-     * Judge logic tables is all belong to broadcast encryptors.
+     * Judge whether all logic tables are broadcast encryptors or not.
      *
      * @param logicTableNames logic table names
-     * @return logic tables is all belong to broadcast encryptors or not
+     * @return whether all logic tables are binding encryptors or not
      */
     public boolean isAllBroadcastTables(final Collection<String> 
logicTableNames) {
         return !logicTableNames.isEmpty() && 
logicTableNames.stream().allMatch(this::isBroadcastTable);
     }
     
     /**
-     * Judge logic tables is all belong to sharding tables.
+     * Judge whether all logic tables are sharding tables or not.
      *
      * @param logicTableNames logic table names
-     * @return logic tables is all belong to sharding tables or not
+     * @return whether all logic tables are sharding tables or not
      */
     public boolean isAllShardingTables(final Collection<String> 
logicTableNames) {
         return logicTableNames.stream().allMatch(each -> 
findTableRule(each).isPresent());
     }
     
     /**
-     * Judge logic table is belong to sharding tables.
+     * Judge whether logic table is sharding table or not.
      *
      * @param logicTableName logic table name
-     * @return logic table is belong to sharding tables or not
+     * @return whether logic table is sharding table or not
      */
     public boolean isShardingTable(final String logicTableName) {
         return findTableRule(logicTableName).isPresent();
     }
     
     /**
-     * Judge logic table is belong to broadcast tables.
+     * Judge whether logic table are broadcast tables or not.
      *
      * @param logicTableName logic table name
-     * @return logic table is belong to broadcast tables or not
+     * @return whether logic table are broadcast tables or not
      */
     public boolean isBroadcastTable(final String logicTableName) {
         return broadcastTables.stream().anyMatch(each -> 
each.equalsIgnoreCase(logicTableName));
     }
     
     /**
-     * Judge if all single tables exist in same data source.
+     * Judge if all single tables exist in same data source or not.

Review comment:
       @KSMASTERS `Judge whether all single tables exist in same data source or 
not.` may be better.

##########
File path: 
shardingsphere-features/shardingsphere-sharding/shardingsphere-sharding-common/src/main/java/org/apache/shardingsphere/sharding/rule/ShardingRule.java
##########
@@ -326,10 +326,10 @@ public boolean isSingleTablesInSameDataSource(final 
Collection<String> logicTabl
     }
     
     /**
-     * Judge if there is at least one table rule for logic tables.
+     * Judge if there is at least one table rule for logic tables or not.

Review comment:
       @KSMASTERS `Judge whether a table rule exists for logic tables or not` 
may be better.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to