docs: public Object getAsObject(FacesContext facesContext, UIComponent uiComponent, String value)
      {
          if (facesContext == null)
          {
              throw new NullPointerException("facesContext");
          }
          if (uiComponent == null)
          {
              throw new NullPointerException("uiComponent");
          }
  
          if (value != null)
          {
              value = value.trim();
              if (value.length() > 0)
              {
                  NumberFormat format = getNumberFormat(facesContext);
                  format.setParseIntegerOnly(_integerOnly);
                  
                  DecimalFormat df = (DecimalFormat)format;
                  
                  // The best we can do in this case is check if there is a ValueExpression
                  // with a BigDecimal as returning type , and if that so enable BigDecimal parsing
                  // to prevent loss in precision, and do not break existing examples (since
                  // in those cases it is expected to return Double). See MYFACES-1890 and TRINIDAD-1124
                  // for details
                  ValueExpression valueBinding = uiComponent.getValueExpression("value");
                  if (valueBinding != null)
                  {
                      Class<?> destType = valueBinding.getType(facesContext.getELContext());
                      if (destType != null && BigDecimal.class.isAssignableFrom(destType))
                      {
                          df.setParseBigDecimal(true);
                      }
                  }
                  
                  DecimalFormatSymbols dfs = df.getDecimalFormatSymbols();
                  boolean changed = false;
                  if(dfs.getGroupingSeparator() == '\u00a0')
                  {
                    dfs.setGroupingSeparator(' ');
                    df.setDecimalFormatSymbols(dfs);
                    value = value.replace('\u00a0', ' ');
                    changed = true;
                  }
                  
                  formatCurrency(format);
                  
                  try
                  {
                      return format.parse(value);
                  }
                  catch (ParseException e)
                  {
                    if(changed)
                    {
                      dfs.setGroupingSeparator('\u00a0');
                      df.setDecimalFormatSymbols(dfs);
                    }
                    try
                    {
                      return format.parse(value);
                    }
                    catch (ParseException pe)
                    {
  
                      if(getPattern() != null)
                      {
                          throw new ConverterException(_MessageUtils.getErrorMessage(facesContext,
                                  PATTERN_ID,
                                  new Object[]{value, "$###,###", _MessageUtils.getLabel(facesContext, uiComponent)}));
                      }
                      else if(getType().equals("number"))
                      {
                          throw new ConverterException(_MessageUtils.getErrorMessage(facesContext,
                                  NUMBER_ID,
                                  new Object[]{value, format.format(21),
                                               _MessageUtils.getLabel(facesContext, uiComponent)}));
                      }
                      else if(getType().equals("currency"))
                      {
                          throw new ConverterException(_MessageUtils.getErrorMessage(facesContext,
                                  CURRENCY_ID,
                                  new Object[]{value, format.format(42.25),
                                               _MessageUtils.getLabel(facesContext, uiComponent)}));
                      }
                      else if(getType().equals("percent"))
                      {
                          throw new ConverterException(_MessageUtils.getErrorMessage(facesContext,
                                  PERCENT_ID,
                                  new Object[]{value, format.format(.90),
                                               _MessageUtils.getLabel(facesContext, uiComponent)}));
                      }
                    }
                  }
              }
          }
          return null;
      }