code: private static JsonStructure toJson( TupleRef tuple)
      {
      JsonObjectBuilder builder = Json.createObjectBuilder();
  
      toStream( tuple.getVarBindings()).forEach( binding -> builder.add( binding.getVar(), String.valueOf( binding.getValue())));
      
      return builder.build();
      }
docs: Returns the JSON object that represents the given once tuple.