Skip to content

Commit a4dbd53

Browse files
committed
chore: fix checkstyle issues
1 parent c975c63 commit a4dbd53

19 files changed

+328
-130
lines changed

src/main/java/de/rwth/idsg/steve/config/OcppConfiguration.java

+6-3
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,7 @@
3535
import org.springframework.context.annotation.Bean;
3636
import org.springframework.context.annotation.Configuration;
3737
import org.springframework.context.event.ContextRefreshedEvent;
38-
import org.springframework.context.event.ContextStartedEvent;
3938
import org.springframework.context.event.EventListener;
40-
import org.springframework.stereotype.Component;
4139

4240
import java.util.Collection;
4341
import java.util.Collections;
@@ -67,7 +65,12 @@ public class OcppConfiguration {
6765
private final List<Feature> logging;
6866
private final String routerEndpointPath;
6967

70-
public OcppConfiguration(CentralSystemService ocpp12Server, ocpp.cs._2012._06.CentralSystemService ocpp15Server, ocpp.cs._2015._10.CentralSystemService ocpp16Server, @Qualifier("MessageHeaderInterceptor") PhaseInterceptor<Message> messageHeaderInterceptor) {
68+
public OcppConfiguration(
69+
CentralSystemService ocpp12Server,
70+
ocpp.cs._2012._06.CentralSystemService ocpp15Server,
71+
ocpp.cs._2015._10.CentralSystemService ocpp16Server,
72+
@Qualifier("MessageHeaderInterceptor") PhaseInterceptor<Message> messageHeaderInterceptor
73+
) {
7174
this.ocpp12Server = ocpp12Server;
7275
this.ocpp15Server = ocpp15Server;
7376
this.ocpp16Server = ocpp16Server;

src/main/java/de/rwth/idsg/steve/ocpp/ChargePointService12_InvokerImpl.java

+33-11
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232
import de.rwth.idsg.steve.ocpp.ws.ChargePointServiceInvoker;
3333
import de.rwth.idsg.steve.ocpp.ws.SessionContextStore;
3434
import de.rwth.idsg.steve.ocpp.ws.ocpp12.Ocpp12TypeStore;
35-
import de.rwth.idsg.steve.ocpp.ws.ocpp12.Ocpp12WebSocketEndpoint;
3635
import de.rwth.idsg.steve.ocpp.ws.pipeline.OutgoingCallPipeline;
3736
import de.rwth.idsg.steve.repository.dto.ChargePointSelect;
3837
import ocpp.cp._2010._08.ChargePointService;
@@ -44,20 +43,27 @@
4443
* @since 10.03.2018
4544
*/
4645
@Service
46+
@Qualifier("ChargePointService12_Invoker")
4747
public class ChargePointService12_InvokerImpl implements ChargePointService12_Invoker {
4848

4949
private final ChargePointServiceInvoker wsHelper;
5050
private final ClientProviderWithCache<ChargePointService> soapHelper;
5151

52-
public ChargePointService12_InvokerImpl(OutgoingCallPipeline pipeline, @Qualifier("sessionContextStore12") SessionContextStore sessionContextStore, ClientProvider clientProvider) {
52+
public ChargePointService12_InvokerImpl(
53+
OutgoingCallPipeline pipeline,
54+
@Qualifier("sessionContextStore12") SessionContextStore sessionContextStore,
55+
ClientProvider clientProvider
56+
) {
5357
this.wsHelper = new ChargePointServiceInvoker(pipeline, sessionContextStore, Ocpp12TypeStore.INSTANCE);
5458
this.soapHelper = new ClientProviderWithCache<>(clientProvider);
5559
}
5660

5761
@Override
5862
public void reset(ChargePointSelect cp, ResetTask task) {
5963
if (cp.isSoap()) {
60-
create(cp).resetAsync(task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId()));
64+
create(cp).resetAsync(
65+
task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId())
66+
);
6167
} else {
6268
runPipeline(cp, task);
6369
}
@@ -66,7 +72,9 @@ public void reset(ChargePointSelect cp, ResetTask task) {
6672
@Override
6773
public void clearCache(ChargePointSelect cp, ClearCacheTask task) {
6874
if (cp.isSoap()) {
69-
create(cp).clearCacheAsync(task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId()));
75+
create(cp).clearCacheAsync(
76+
task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId())
77+
);
7078
} else {
7179
runPipeline(cp, task);
7280
}
@@ -75,7 +83,9 @@ public void clearCache(ChargePointSelect cp, ClearCacheTask task) {
7583
@Override
7684
public void getDiagnostics(ChargePointSelect cp, GetDiagnosticsTask task) {
7785
if (cp.isSoap()) {
78-
create(cp).getDiagnosticsAsync(task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId()));
86+
create(cp).getDiagnosticsAsync(
87+
task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId())
88+
);
7989
} else {
8090
runPipeline(cp, task);
8191
}
@@ -84,7 +94,9 @@ public void getDiagnostics(ChargePointSelect cp, GetDiagnosticsTask task) {
8494
@Override
8595
public void updateFirmware(ChargePointSelect cp, UpdateFirmwareTask task) {
8696
if (cp.isSoap()) {
87-
create(cp).updateFirmwareAsync(task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId()));
97+
create(cp).updateFirmwareAsync(
98+
task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId())
99+
);
88100
} else {
89101
runPipeline(cp, task);
90102
}
@@ -93,7 +105,9 @@ public void updateFirmware(ChargePointSelect cp, UpdateFirmwareTask task) {
93105
@Override
94106
public void unlockConnector(ChargePointSelect cp, UnlockConnectorTask task) {
95107
if (cp.isSoap()) {
96-
create(cp).unlockConnectorAsync(task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId()));
108+
create(cp).unlockConnectorAsync(
109+
task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId())
110+
);
97111
} else {
98112
runPipeline(cp, task);
99113
}
@@ -102,7 +116,9 @@ public void unlockConnector(ChargePointSelect cp, UnlockConnectorTask task) {
102116
@Override
103117
public void changeAvailability(ChargePointSelect cp, ChangeAvailabilityTask task) {
104118
if (cp.isSoap()) {
105-
create(cp).changeAvailabilityAsync(task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId()));
119+
create(cp).changeAvailabilityAsync(
120+
task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId())
121+
);
106122
} else {
107123
runPipeline(cp, task);
108124
}
@@ -111,7 +127,9 @@ public void changeAvailability(ChargePointSelect cp, ChangeAvailabilityTask task
111127
@Override
112128
public void changeConfiguration(ChargePointSelect cp, ChangeConfigurationTask task) {
113129
if (cp.isSoap()) {
114-
create(cp).changeConfigurationAsync(task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId()));
130+
create(cp).changeConfigurationAsync(
131+
task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId())
132+
);
115133
} else {
116134
runPipeline(cp, task);
117135
}
@@ -120,7 +138,9 @@ public void changeConfiguration(ChargePointSelect cp, ChangeConfigurationTask ta
120138
@Override
121139
public void remoteStartTransaction(ChargePointSelect cp, RemoteStartTransactionTask task) {
122140
if (cp.isSoap()) {
123-
create(cp).remoteStartTransactionAsync(task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId()));
141+
create(cp).remoteStartTransactionAsync(
142+
task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId())
143+
);
124144
} else {
125145
runPipeline(cp, task);
126146
}
@@ -129,7 +149,9 @@ public void remoteStartTransaction(ChargePointSelect cp, RemoteStartTransactionT
129149
@Override
130150
public void remoteStopTransaction(ChargePointSelect cp, RemoteStopTransactionTask task) {
131151
if (cp.isSoap()) {
132-
create(cp).remoteStopTransactionAsync(task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId()));
152+
create(cp).remoteStopTransactionAsync(
153+
task.getOcpp12Request(), cp.getChargeBoxId(), task.getOcpp12Handler(cp.getChargeBoxId())
154+
);
133155
} else {
134156
runPipeline(cp, task);
135157
}

src/main/java/de/rwth/idsg/steve/ocpp/ChargePointService15_InvokerImpl.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@
3838
import de.rwth.idsg.steve.ocpp.ws.ChargePointServiceInvoker;
3939
import de.rwth.idsg.steve.ocpp.ws.SessionContextStore;
4040
import de.rwth.idsg.steve.ocpp.ws.ocpp15.Ocpp15TypeStore;
41-
import de.rwth.idsg.steve.ocpp.ws.ocpp15.Ocpp15WebSocketEndpoint;
4241
import de.rwth.idsg.steve.ocpp.ws.pipeline.OutgoingCallPipeline;
4342
import de.rwth.idsg.steve.repository.dto.ChargePointSelect;
4443
import ocpp.cp._2012._06.ChargePointService;
@@ -50,12 +49,17 @@
5049
* @since 10.03.2018
5150
*/
5251
@Service
52+
@Qualifier("ChargePointService15_Invoker")
5353
public class ChargePointService15_InvokerImpl implements ChargePointService15_Invoker {
5454

5555
private final ChargePointServiceInvoker wsHelper;
5656
private final ClientProviderWithCache<ChargePointService> soapHelper;
5757

58-
public ChargePointService15_InvokerImpl(OutgoingCallPipeline pipeline, @Qualifier("sessionContextStore15") SessionContextStore sessionContextStore, ClientProvider clientProvider) {
58+
public ChargePointService15_InvokerImpl(
59+
OutgoingCallPipeline pipeline,
60+
@Qualifier("sessionContextStore15") SessionContextStore sessionContextStore,
61+
ClientProvider clientProvider
62+
) {
5963
this.wsHelper = new ChargePointServiceInvoker(pipeline, sessionContextStore, Ocpp15TypeStore.INSTANCE);
6064
this.soapHelper = new ClientProviderWithCache<>(clientProvider);
6165
}

0 commit comments

Comments
 (0)