private void initGenerics() {
        final TypeVariable<Method>[] methodGenerics = method.getTypeParameters();
        final boolean hasMethodGenerics = methodGenerics.length > 0;
        this.methodGenerics = hasMethodGenerics
                ? new LinkedHashMap<String, Type>() : Collections.<String, Type>emptyMap();
        // important to fill it in time of resolution because method generics could be dependant
        this.allGenerics = hasMethodGenerics
                ? new LinkedHashMap<String, Type>(typeGenerics) : typeGenerics;
        for (TypeVariable<Method> generic : methodGenerics) {
            final Class<?> value = resolveClass(generic.getBounds()[0]);
            this.methodGenerics.put(generic.getName(), value);
            this.allGenerics.put(generic.getName(), value);
        }
    }