code: private static void stampTypeOnJsonObject(final Object o, final Type t)
      {
          Class clazz = t instanceof Class ? (Class)t : getRawType(t);
  
          if (o instanceof JsonObject && clazz != null)
          {
              JsonObject jObj = (JsonObject) o;
              if ((jObj.type == null || jObj.type.isEmpty()) && jObj.target == null)
              {
                  jObj.type = clazz.getName();
              }
          }
      }
docs: node (no further subtypes in it's parameterized type definition)