Skip to content

Commit

Permalink
Merge pull request #395 from liaochong/feature/4.3.0.RELEASE
Browse files Browse the repository at this point in the history
Feature/4.3.0.release
  • Loading branch information
liaochong authored Jun 9, 2023
2 parents 5a34b0a + aa65f56 commit 376271f
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 15 deletions.
6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

<groupId>com.github.liaochong</groupId>
<artifactId>myexcel</artifactId>
<version>4.3.0.RC5</version>
<version>4.3.0.RELEASE</version>
<packaging>jar</packaging>

<name>myexcel</name>
Expand All @@ -28,7 +28,7 @@
<beetl.version>3.15.4.RELEASE</beetl.version>
<velocity.version>2.3</velocity.version>
<freemarker.version>2.3.32</freemarker.version>
<groovy-templates.version>3.0.9</groovy-templates.version>
<groovy-templates.version>4.0.12</groovy-templates.version>
<thymeleaf.version>3.1.1.RELEASE</thymeleaf.version>
<enjoy.version>5.0.3</enjoy.version>
<javax.servlet-api.version>4.0.1</javax.servlet-api.version>
Expand Down Expand Up @@ -89,7 +89,7 @@
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-templates</artifactId>
<version>${groovy-templates.version}</version>
<optional>true</optional>
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/github/liaochong/myexcel/core/Csv.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public class Csv {
/**
* csv文件路径
*/
private Path filePath;
private final Path filePath;

Csv(Path filePath) {
this.filePath = filePath;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
*/
public class WeakCache<K, V> implements Cache<K, V> {

private volatile WeakHashMap<K, V> cacheMap;
private final WeakHashMap<K, V> cacheMap;

public WeakCache() {
cacheMap = new WeakHashMap<>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ public enum FileType {
/**
* 图片
*/
IMAGE;
IMAGE
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,5 @@ public enum LinkType {
/**
* email,如[email protected]
*/
EMAIL;
EMAIL
}
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
*/
public class MappingWriteConverter implements WriteConverter {

private WeakCache<String, Pair<Class, Object>> mappingCache = new WeakCache<>();
private final WeakCache<String, Pair<Class, Object>> mappingCache = new WeakCache<>();

@Override
public boolean support(Field field, Class<?> fieldType, Object fieldVal, ConvertContext convertContext) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,11 @@ public final class StyleParser {
/**
* 各个列样式
*/
private Map<String, Map<String, String>> eachColumnStyle = new HashMap<>();
private final Map<String, Map<String, String>> eachColumnStyle = new HashMap<>();
/**
* 格式样式Map
*/
private Map<String, Map<String, String>> formatsStyleMap = new HashMap<>();
private final Map<String, Map<String, String>> formatsStyleMap = new HashMap<>();
/**
* 自定义宽度
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@
*/
public final class PropertyUtil {

private static WeakCache<ExcelColumnMapping, Properties> mappingCache = new WeakCache<>();
private static final WeakCache<ExcelColumnMapping, Properties> mappingCache = new WeakCache<>();

private static WeakCache<ExcelColumnMapping, Properties> reverseMappingCache = new WeakCache<>();
private static final WeakCache<ExcelColumnMapping, Properties> reverseMappingCache = new WeakCache<>();

private static final Properties EMPTY_PROPERTIES = new Properties();

Expand Down
6 changes: 3 additions & 3 deletions src/main/java/com/github/liaochong/myexcel/utils/TdUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@
*/
public final class TdUtil {

private static Pattern chineseOrCapitalPattern = Pattern.compile("[\u4e00-\u9fa5|A-Z]");
private static final Pattern chineseOrCapitalPattern = Pattern.compile("[\u4e00-\u9fa5|A-Z]");

private static Pattern digitalPattern = Pattern.compile("^\\d+$");
private static final Pattern digitalPattern = Pattern.compile("^\\d+$");

private static Pattern nonDigitalPattern = Pattern.compile("[^\\d]+");
private static final Pattern nonDigitalPattern = Pattern.compile("[^\\d]+");

private static final Cache<String, Integer> SPAN_CACHE = new WeakCache<>();

Expand Down

0 comments on commit 376271f

Please sign in to comment.