mirror of
				https://e.coding.net/circlecloud/YumCore.git
				synced 2025-11-03 23:06:02 +00:00 
			
		
		
		
	@@ -28,4 +28,22 @@ public class StrKit {
 | 
			
		||||
        }
 | 
			
		||||
        return ret;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @param str
 | 
			
		||||
     *            字串
 | 
			
		||||
     * @return 是否为空字串
 | 
			
		||||
     */
 | 
			
		||||
    public static boolean isBlank(final String str) {
 | 
			
		||||
        return str == null || str.isEmpty();
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @param str
 | 
			
		||||
     *            字串
 | 
			
		||||
     * @return 是否不为空字串
 | 
			
		||||
     */
 | 
			
		||||
    public static boolean notBlank(final String str) {
 | 
			
		||||
        return str != null && !str.isEmpty();
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
@@ -2,6 +2,7 @@ package pw.yumc.YumCore.paste;
 | 
			
		||||
 | 
			
		||||
import java.io.File;
 | 
			
		||||
import java.io.IOException;
 | 
			
		||||
import java.nio.charset.Charset;
 | 
			
		||||
import java.nio.file.Files;
 | 
			
		||||
import java.util.ArrayList;
 | 
			
		||||
import java.util.List;
 | 
			
		||||
@@ -31,7 +32,7 @@ public class PasteContent {
 | 
			
		||||
        if (file == null) {
 | 
			
		||||
            throw new IllegalArgumentException("文件不得为Null!");
 | 
			
		||||
        }
 | 
			
		||||
        addLines(Files.readAllLines(file.toPath()));
 | 
			
		||||
        addLines(Files.readAllLines(file.toPath(), Charset.forName("UTF-8")));
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user