code: @Override
    public ServerEvaluationCall addVariableAs(String name, Object value) {
      if (value == null) return this;
  
      Class<?> as = value.getClass();
      AbstractWriteHandle writeHandle = null;
      if (AbstractWriteHandle.class.isAssignableFrom(as)) {
        writeHandle = (AbstractWriteHandle) value;
      } else {
        ContentHandle<?> contentHandle = handleRegistry.makeHandle(as);
        Utilities.setHandleContent(contentHandle, value);
        writeHandle = contentHandle;
      }
      return addVariable(name, writeHandle);
    }
docs: Like other *As convenience methods throughout the API, the Object value
  is managed by the Handle registered for that Class.