@Test public void executeWithSelectiveAccess() throws ProtocolAdapterException { DlmsDevice dlmsDevice = new DlmsDevice(); dlmsDevice.setSelectiveAccessSupported(true); executor.execute(conn, dlmsDevice, getPowerQualityProfileRequestDataDto); verify(getPowerQualityProfileSelectiveAccessHandler) .handle(any(DlmsConnectionManager.class), any(DlmsDevice.class), any(GetPowerQualityProfileRequestDataDto.class)); }
@Override public GetPowerQualityProfileResponseDto execute(DlmsConnectionManager conn, DlmsDevice device, GetPowerQualityProfileRequestDataDto getPowerQualityProfileRequestDataDto) throws ProtocolAdapterException { if (device.isSelectiveAccessSupported()) { return this.getPowerQualityProfileSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } else { return this.getPowerQualityProfileNoSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } }
GetPowerQualityProfileCommandExecutor extends AbstractCommandExecutor<GetPowerQualityProfileRequestDataDto, GetPowerQualityProfileResponseDto> { @Override public GetPowerQualityProfileResponseDto execute(DlmsConnectionManager conn, DlmsDevice device, GetPowerQualityProfileRequestDataDto getPowerQualityProfileRequestDataDto) throws ProtocolAdapterException { if (device.isSelectiveAccessSupported()) { return this.getPowerQualityProfileSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } else { return this.getPowerQualityProfileNoSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } } }
GetPowerQualityProfileCommandExecutor extends AbstractCommandExecutor<GetPowerQualityProfileRequestDataDto, GetPowerQualityProfileResponseDto> { @Override public GetPowerQualityProfileResponseDto execute(DlmsConnectionManager conn, DlmsDevice device, GetPowerQualityProfileRequestDataDto getPowerQualityProfileRequestDataDto) throws ProtocolAdapterException { if (device.isSelectiveAccessSupported()) { return this.getPowerQualityProfileSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } else { return this.getPowerQualityProfileNoSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } } GetPowerQualityProfileCommandExecutor(); }
GetPowerQualityProfileCommandExecutor extends AbstractCommandExecutor<GetPowerQualityProfileRequestDataDto, GetPowerQualityProfileResponseDto> { @Override public GetPowerQualityProfileResponseDto execute(DlmsConnectionManager conn, DlmsDevice device, GetPowerQualityProfileRequestDataDto getPowerQualityProfileRequestDataDto) throws ProtocolAdapterException { if (device.isSelectiveAccessSupported()) { return this.getPowerQualityProfileSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } else { return this.getPowerQualityProfileNoSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } } GetPowerQualityProfileCommandExecutor(); @Override GetPowerQualityProfileResponseDto execute(DlmsConnectionManager conn, DlmsDevice device,
            GetPowerQualityProfileRequestDataDto getPowerQualityProfileRequestDataDto); }
GetPowerQualityProfileCommandExecutor extends AbstractCommandExecutor<GetPowerQualityProfileRequestDataDto, GetPowerQualityProfileResponseDto> { @Override public GetPowerQualityProfileResponseDto execute(DlmsConnectionManager conn, DlmsDevice device, GetPowerQualityProfileRequestDataDto getPowerQualityProfileRequestDataDto) throws ProtocolAdapterException { if (device.isSelectiveAccessSupported()) { return this.getPowerQualityProfileSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } else { return this.getPowerQualityProfileNoSelectiveAccessHandler .handle(conn, device, getPowerQualityProfileRequestDataDto); } } GetPowerQualityProfileCommandExecutor(); @Override GetPowerQualityProfileResponseDto execute(DlmsConnectionManager conn, DlmsDevice device,
            GetPowerQualityProfileRequestDataDto getPowerQualityProfileRequestDataDto);  }