code: public <T> T getResourceAsObject(final TypeToken<T> type)
      {
          try
          {
              //noinspection unchecked
              return (T) objectMapper.readValue(((ContentRepresentation) getUnderlyingRepresentation()).getContent(), objectMapper.constructType(type.getType()));
          }
          catch (IOException e)
          {
              LOGGER.warn("failed to parse resource as object: {}", e.getMessage());
              throw new RuntimeException(e);
          }
      }
docs: Parse root resource as an object.
  
  @param type Type
  @return Object representation as an object