@SuppressWarnings("rawtypes")
  public static MultiColumnComparator createDoubleComparator(NumberName[] numberNames, boolean ascending, String defaultString) throws Exception
  {
    final String type="double";
    if (ascending)
    {
      if (defaultString.equals(""))
      {
        return new MultiColumnComparator(numberNames,ascending,type,defaultString)
        {
          public Comparable generateKey(String[] parts) throws Exception
          {
            return new Double(getDoubleValue(parts));
          }
        };
      }
      else
      {
        final Double defaultKey = Double.valueOf(defaultString);
        return new MultiColumnComparator(numberNames,ascending,type,defaultString)
        {
          public Comparable generateKey(String[] parts) throws Exception
          {
            try
            {
              return new Double(getDoubleValue(parts));
            }
            catch (Exception e)
            {
              return defaultKey;
            }
          }
        };
      }
    }
    else
    {
      if (defaultString.equals(""))
      {
        return new MultiColumnComparator(numberNames,ascending,type,defaultString)
        {
          public Comparable generateKey(String[] parts) throws Exception
          {
            return new Double(-getDoubleValue(parts));
          }
        };
      }
      else
      {
        final Double defaultKey = new Double(-Double.parseDouble(defaultString));
        return new MultiColumnComparator(numberNames,ascending,type,defaultString)
        {
          public Comparable generateKey(String[] parts) throws Exception
          {
            try
            {
              return new Double(-getDoubleValue(parts));
            }
            catch (Exception e)
            {
              return defaultKey;
            }
          }
        };
      }
    }
  }