public static Converter<?> getConverter(FacesContext context, Class<?> forClass) {
        if (forClass == null
                || forClass == Object.class
                || (forClass == String.class
                && !PrimeApplicationContext.getCurrentInstance(context).getConfig().isStringConverterAvailable())) {
            return null;
        }

        return context.getApplication().createConverter(forClass);
    }
Finds appropriate converter for a given value holder

@param context   FacesContext instance
@param component ValueHolder instance to look up converter for
@return          Converter
primefaces/src/main/java/org/primefaces/util/ComponentUtils.java