@Override public Future<ActionFuture> setNeutralWhite() throws CouldNotPerformException { return setColor(neutralWhite); }
@Override public UnitConfig applyConfigUpdate(final UnitConfig config) throws CouldNotPerformException, InterruptedException { updateNeutralWhiteValue(config); return super.applyConfigUpdate(config); }
@Override public Future<ActionFuture> setPowerState(final PowerState state) throws CouldNotPerformException { logger.debug("Set " + getUnitType().name() + "[" + getLabel() + "] to PowerState [" + state + "]"); try { Services.verifyOperationServiceState(state); } catch (VerificationFailedException ex) { return FutureProcessor.canceledFuture(ActionFuture.class, ex); } return powerService.setPowerState(state); }
@Override public BrightnessState getBrightnessState() throws NotAvailableException { try { return getData().getBrightnessState(); } catch (CouldNotPerformException ex) { throw new NotAvailableException("brightnessState", ex); } }
@Override public void init(UnitConfigType.UnitConfig config) throws InitializationException, InterruptedException { super.init(config); try { this.powerService = getServiceFactory().newPowerService(this); this.colorService = getServiceFactory().newColorService(this); this.brightnessService = getServiceFactory().newBrightnessService(this); } catch (CouldNotPerformException ex) { throw new InitializationException(this, ex); } }
@Override public Future<ActionFuture> setBrightnessState(final BrightnessState state) throws CouldNotPerformException { logger.debug("Set " + getUnitType().name() + "[" + getLabel() + "] to BrightnessState[" + state + "]"); try { Services.verifyOperationServiceState(state); } catch (VerificationFailedException ex) { return FutureProcessor.canceledFuture(ActionFuture.class, ex); } return brightnessService.setBrightnessState(state); }
@Override public PowerState getPowerState() throws NotAvailableException { try { return getData().getPowerState(); } catch (CouldNotPerformException ex) { throw new NotAvailableException("powerState", ex); } }
@Override public ColorState getColorState() throws NotAvailableException { try { return getData().getColorState(); } catch (CouldNotPerformException ex) { throw new NotAvailableException("colorState", ex); } }