code: public boolean setBooleanValue(boolean value) throws IOException, SaneException {
      ControlOptionResult result = writeOption(SaneWord.forInt(value ? 1 : 0));
      Preconditions.checkState(result.getType() == OptionValueType.BOOLEAN);
  
      return SaneWord.fromBytes(result.getValue()).integerValue() != 0;
    }
docs: Sets the value of the current option to the supplied boolean value. Option value must be of
  boolean type. SANE may ignore your preference, so if you need to ensure the value has been set
  correctly, you should examine the return value of this method.
  
  @return the value that the option now has according to SANE