private static void addType(final Set<Class<?>> stroomClasses, final Type type) {
        if (Class.class.isAssignableFrom(type.getClass())) {
            addClass(stroomClasses, (Class<?>) type, null);
        } else if (TypeVariable.class.isAssignableFrom(type.getClass())) {
            final Class<?> clazz = (Class<?>) ((TypeVariable<?>) type).getGenericDeclaration();
            addClass(stroomClasses, clazz, null);

        } else if (ParameterizedType.class.isAssignableFrom(type.getClass())) {
            final ParameterizedType parameterizedType = (ParameterizedType) type;
            addType(stroomClasses, parameterizedType.getRawType());
            for (final Type arg : parameterizedType.getActualTypeArguments()) {
                addType(stroomClasses, arg);
            }

        } else {
            throw new RuntimeException("Didn't expect to get here");
        }
    }
Test that classes that will be subject to JSON serialisation have the full complement of JSON annotations.
stroom-app/src/test/java/stroom/importexport/TestJsonSerialisation.java