This is an automated email from the ASF dual-hosted git repository.

sunnianjun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git


The following commit(s) were added to refs/heads/master by this push:
     new eeb6c57ead5 Remove useless codes on EncryptTokenGeneratorUtils (#30285)
eeb6c57ead5 is described below

commit eeb6c57ead551af87162da797a300ff8b6d407ed
Author: Liang Zhang <[email protected]>
AuthorDate: Sun Feb 25 23:01:43 2024 +0800

    Remove useless codes on EncryptTokenGeneratorUtils (#30285)
    
    * Revise AgentYamlEngineTest
    
    * Refactor AdviceExecutorFactory
    
    * Add javadoc on AbstractStaticMethodAdvice
    
    * Remove useless codes on EncryptTokenGeneratorUtils
---
 .../rewrite/token/util/EncryptTokenGeneratorUtils.java | 18 ------------------
 1 file changed, 18 deletions(-)

diff --git 
a/features/encrypt/core/src/main/java/org/apache/shardingsphere/encrypt/rewrite/token/util/EncryptTokenGeneratorUtils.java
 
b/features/encrypt/core/src/main/java/org/apache/shardingsphere/encrypt/rewrite/token/util/EncryptTokenGeneratorUtils.java
index 96f8b2ce5fb..b3d03354be4 100644
--- 
a/features/encrypt/core/src/main/java/org/apache/shardingsphere/encrypt/rewrite/token/util/EncryptTokenGeneratorUtils.java
+++ 
b/features/encrypt/core/src/main/java/org/apache/shardingsphere/encrypt/rewrite/token/util/EncryptTokenGeneratorUtils.java
@@ -60,24 +60,6 @@ public final class EncryptTokenGeneratorUtils {
         return true;
     }
     
-    /**
-     * Judge whether all using columns use same encryptor or not.
-     *
-     * @param usingColumns using columns
-     * @param encryptRule encrypt rule
-     * @return whether all using columns use same encryptor or not
-     */
-    public static boolean isAllUsingConditionsUseSameEncryptor(final 
Collection<ColumnSegment> usingColumns, final EncryptRule encryptRule) {
-        for (ColumnSegment each : usingColumns) {
-            EncryptAlgorithm leftColumnEncryptor = 
getColumnEncryptor(each.getColumnBoundedInfo(), encryptRule);
-            EncryptAlgorithm rightColumnEncryptor = 
getColumnEncryptor(each.getOtherUsingColumnBoundedInfo(), encryptRule);
-            if (!isSameEncryptor(leftColumnEncryptor, rightColumnEncryptor)) {
-                return false;
-            }
-        }
-        return true;
-    }
-    
     private static boolean isSameEncryptor(final EncryptAlgorithm 
leftColumnEncryptor, final EncryptAlgorithm rightColumnEncryptor) {
         if (null != leftColumnEncryptor && null != rightColumnEncryptor) {
             if 
(!leftColumnEncryptor.getType().equals(rightColumnEncryptor.getType())) {

Reply via email to