code: public static String readValue(String keyName, String valueName) throws RegistryException {
          try (Key key = Key.open(keyName, KEY_READ)) {
              return fromByteArray(invoke(Methods.REG_QUERY_VALUE_EX.get(), key.id, toByteArray(valueName)));
          }
      }
docs: Reads a string value from the given key and value name.
  
  @param keyName Name of the key, which contains the value to read.
  @param valueName Name of the value to read.
  @return Content of the specified value.
  @throws RegistryException