Merge branch 'master' of http://gitlab.fangjia.com/dev0/main
This commit is contained in:
@@ -13,7 +13,7 @@ import java.util.*;
|
||||
*/
|
||||
public class BaiDuApiUtils {
|
||||
|
||||
private static String AK = "9E99D3540e4dafb7894f7b9fe27fa6b5";
|
||||
private static String AK = "ajgWIBd9rYsXed1hcDQqYvkX";
|
||||
public static String[] AKS = new String[]{"hj5KqPjaGA3uivtg8uS8XfAnj9X1kPMr","xjFg7DfDqvQleIZasM3ph8Zi2Lw8kgCg",
|
||||
"4pb6fzrWIzvibDu8L1o8DGoY2h1wRIUq","ZzX6mRFfE5GKn4cpUp24Q3OyUIHnfQAR","79ac4ea49e7dedbf80b0ecd475d07784",
|
||||
"9E99D3540e4dafb7894f7b9fe27fa6b5","W3M5uHfcrmlAdhQjf6v93LCI", "C8bb035aacf602551e829e4c64575224",
|
||||
|
||||
@@ -1435,6 +1435,25 @@ public class DataUtil {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 匹配符合条件的字符串
|
||||
*
|
||||
* @param str
|
||||
* @param pattern
|
||||
* @return
|
||||
*/
|
||||
public static List<String> matchAll(String str, Pattern pattern) {
|
||||
if (str == null) {
|
||||
return null;
|
||||
}
|
||||
List list = new ArrayList();
|
||||
Matcher matcher = pattern.matcher(str);
|
||||
while (matcher.find()) {
|
||||
list.add(matcher.group());
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
public static boolean isNumeric(String str) {
|
||||
try {
|
||||
Double.parseDouble(str);
|
||||
|
||||
@@ -58,7 +58,7 @@ public class ExcelUtil {
|
||||
row.setHeightInPoints(35);
|
||||
Font font = workBook.createFont();
|
||||
font.setFontName("宋体");
|
||||
font.setBoldweight(Font.BOLDWEIGHT_BOLD);
|
||||
// font.setBoldweight(Font.BOLDWEIGHT_BOLD);
|
||||
font.setFontHeightInPoints((short) 12);
|
||||
CellStyle cellStyle = workBook.createCellStyle();
|
||||
cellStyle.setFont(font);
|
||||
|
||||
@@ -39,7 +39,7 @@ public final class RandomUtil extends RandomUtils {
|
||||
|
||||
public static void main(String[] args) {
|
||||
for (int i = 0; i < 1000; i++) {
|
||||
System.out.println(random(0, 10));
|
||||
System.out.println(random(-9, 9));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user