class TypeLiteral implements Serializable {

    public static Type[] getGenericInterfaceTypeParameters(Class<?> clazz, Class<?> interfaceType) {
        Objects.requireNonNull(clazz, "Class parameter must be given.");
        Objects.requireNonNull(interfaceType, "Interface parameter must be given.");

        for (Type type : clazz.getGenericInterfaces()) {
            if (type instanceof ParameterizedType) {
                ParameterizedType parameterizedType = (ParameterizedType) type;
                if(parameterizedType.getRawType().equals(interfaceType)){
                    return parameterizedType.getActualTypeArguments();
                }
            }
        }
        return EMPTY_TYPE_ARRAY;
    }

    public  TypeLiteral(Type definedType);
    public  TypeLiteral();

}