- private static class SimulatedServiceSnapshot implements NetconfOperationServiceSnapshot {
- private final SessionIdProvider idProvider;
- private final Set<NetconfOperationService> netconfOperationServices;
-
- public SimulatedServiceSnapshot(final SessionIdProvider idProvider, final Set<NetconfOperationService> netconfOperationServices) {
- this.idProvider = idProvider;
- this.netconfOperationServices = netconfOperationServices;
- }
-
- @Override
- public String getNetconfSessionIdForReporting() {
- return String.valueOf(idProvider.getCurrentSessionId());
- }
-
- @Override
- public Set<NetconfOperationService> getServices() {
- return netconfOperationServices;
- }
-
- @Override
- public void close() throws Exception {}
+ @Override
+ public NetconfOperationService createService(final String netconfSessionIdForReporting) {
+ return simulatedOperationService;