Skip to content

Commit 953f50b

Browse files
author
rpseng
committed
A single instace, otherwise a static get() method makes no sense.
1 parent 14d60bc commit 953f50b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

OCPP-J/src/main/java/eu/chargetime/ocpp/JSONConfiguration.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,10 @@ public class JSONConfiguration {
4949

5050
private JSONConfiguration() {}
5151

52+
private static final JSONConfiguration instance = new JSONConfiguration();
53+
5254
public static JSONConfiguration get() {
53-
return new JSONConfiguration();
55+
return instance;
5456
}
5557

5658
public <T> JSONConfiguration setParameter(String name, T value) {

0 commit comments

Comments
 (0)