commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mart...@apache.org
Subject cvs commit: jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters BigDecimalLocaleConverter.java BigIntegerLocaleConverter.java ByteLocaleConverter.java DateLocaleConverter.java DecimalLocaleConverter.java DoubleLocaleConverter.java FloatLocaleConverter.java IntegerLocaleConverter.java LongLocaleConverter.java ShortLocaleConverter.java SqlDateLocaleConverter.java SqlTimeLocaleConverter.java SqlTimestampLocaleConverter.java StringLocaleConverter.java
Date Sat, 11 Jan 2003 22:06:24 GMT
martinc     2003/01/11 14:06:24

  Modified:    beanutils/src/java/org/apache/commons/beanutils/locale/converters
                        BigDecimalLocaleConverter.java
                        BigIntegerLocaleConverter.java
                        ByteLocaleConverter.java DateLocaleConverter.java
                        DecimalLocaleConverter.java
                        DoubleLocaleConverter.java
                        FloatLocaleConverter.java
                        IntegerLocaleConverter.java
                        LongLocaleConverter.java ShortLocaleConverter.java
                        SqlDateLocaleConverter.java
                        SqlTimeLocaleConverter.java
                        SqlTimestampLocaleConverter.java
                        StringLocaleConverter.java
  Log:
  Fix line ends.
  
  PR: 15908
  Submitted by: Dirk Heydtmann
  
  Revision  Changes    Path
  1.2       +243 -243  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/BigDecimalLocaleConverter.java
  
  Index: BigDecimalLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/BigDecimalLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- BigDecimalLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ BigDecimalLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,243 +1,243 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.math.BigDecimal</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class BigDecimalLocaleConverter extends DecimalLocaleConverter {
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public BigDecimalLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigDecimalLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public BigDecimalLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigDecimalLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public BigDecimalLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigDecimalLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public BigDecimalLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigDecimalLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public BigDecimalLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigDecimalLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public BigDecimalLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigDecimalLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern);
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.math.BigDecimal</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class BigDecimalLocaleConverter extends DecimalLocaleConverter {
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public BigDecimalLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigDecimalLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public BigDecimalLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigDecimalLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public BigDecimalLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigDecimalLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public BigDecimalLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigDecimalLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public BigDecimalLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigDecimalLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public BigDecimalLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigDecimalLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern);
  +    }
  +}
  
  
  
  1.2       +243 -243  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/BigIntegerLocaleConverter.java
  
  Index: BigIntegerLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/BigIntegerLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- BigIntegerLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ BigIntegerLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,243 +1,243 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.util.Locale;
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.math.BigInteger</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class BigIntegerLocaleConverter extends DecimalLocaleConverter {
  -
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public BigIntegerLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigIntegerLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public BigIntegerLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigIntegerLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public BigIntegerLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigIntegerLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public BigIntegerLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigIntegerLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public BigIntegerLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigIntegerLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public BigIntegerLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public BigIntegerLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern);
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.util.Locale;
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.math.BigInteger</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class BigIntegerLocaleConverter extends DecimalLocaleConverter {
  +
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public BigIntegerLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigIntegerLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public BigIntegerLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigIntegerLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public BigIntegerLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigIntegerLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public BigIntegerLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigIntegerLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public BigIntegerLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigIntegerLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public BigIntegerLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public BigIntegerLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern);
  +    }
  +}
  
  
  
  1.2       +244 -244  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/ByteLocaleConverter.java
  
  Index: ByteLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/ByteLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ByteLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ ByteLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,244 +1,244 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.lang.Byte</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class ByteLocaleConverter extends DecimalLocaleConverter {
  -
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public ByteLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ByteLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public ByteLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ByteLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public ByteLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ByteLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public ByteLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ByteLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public ByteLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ByteLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public ByteLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ByteLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern);
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.lang.Byte</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class ByteLocaleConverter extends DecimalLocaleConverter {
  +
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public ByteLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ByteLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public ByteLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ByteLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public ByteLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ByteLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public ByteLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ByteLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public ByteLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ByteLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public ByteLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ByteLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern);
  +    }
  +}
  
  
  
  1.2       +278 -278  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/DateLocaleConverter.java
  
  Index: DateLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/DateLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DateLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ DateLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,278 +1,278 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import org.apache.commons.beanutils.locale.BaseLocaleConverter;
  -
  -import java.text.ParseException;
  -import java.text.ParsePosition;
  -import java.text.SimpleDateFormat;
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.util.Date</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class DateLocaleConverter extends BaseLocaleConverter {
  -
  -    // ----------------------------------------------------- Instance Variables
  -
  -    /** The Date formatter */
  -    private SimpleDateFormat formatter = new SimpleDateFormat(pattern, locale);
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public DateLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DateLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public DateLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DateLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public DateLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DateLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public DateLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DateLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public DateLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DateLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public DateLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DateLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern, locPattern);
  -    }
  -
  -    // --------------------------------------------------------- Methods
  -
  -    /**
  -     * Convert the specified locale-sensitive input object into an output object of the
  -     * specified type.
  -     *
  -     * @param value The input object to be converted
  -     * @param pattern The pattern is used for the convertion
  -     *
  -     * @exception ConversionException if conversion cannot be performed
  -     *  successfully
  -     */
  -    protected Object parse(Object value, String pattern) throws ParseException {
  -
  -        if (locPattern) {
  -            formatter.applyLocalizedPattern(pattern);
  -        }
  -        else {
  -            formatter.applyPattern(pattern);
  -        }
  -
  -        return formatter.parse((String) value, new ParsePosition(0));
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import org.apache.commons.beanutils.locale.BaseLocaleConverter;
  +
  +import java.text.ParseException;
  +import java.text.ParsePosition;
  +import java.text.SimpleDateFormat;
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.util.Date</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class DateLocaleConverter extends BaseLocaleConverter {
  +
  +    // ----------------------------------------------------- Instance Variables
  +
  +    /** The Date formatter */
  +    private SimpleDateFormat formatter = new SimpleDateFormat(pattern, locale);
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public DateLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DateLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public DateLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DateLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public DateLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DateLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public DateLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DateLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public DateLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DateLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public DateLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DateLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern, locPattern);
  +    }
  +
  +    // --------------------------------------------------------- Methods
  +
  +    /**
  +     * Convert the specified locale-sensitive input object into an output object of the
  +     * specified type.
  +     *
  +     * @param value The input object to be converted
  +     * @param pattern The pattern is used for the convertion
  +     *
  +     * @exception ConversionException if conversion cannot be performed
  +     *  successfully
  +     */
  +    protected Object parse(Object value, String pattern) throws ParseException {
  +
  +        if (locPattern) {
  +            formatter.applyLocalizedPattern(pattern);
  +        }
  +        else {
  +            formatter.applyPattern(pattern);
  +        }
  +
  +        return formatter.parse((String) value, new ParsePosition(0));
  +    }
  +}
  
  
  
  1.2       +277 -277  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/DecimalLocaleConverter.java
  
  Index: DecimalLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/DecimalLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DecimalLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ DecimalLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,277 +1,277 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import org.apache.commons.beanutils.locale.BaseLocaleConverter;
  -
  -import java.text.DecimalFormat;
  -import java.text.ParseException;
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.lang.Decimal</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class DecimalLocaleConverter extends BaseLocaleConverter {
  -
  -
  -    // ----------------------------------------------------- Instance Variables
  -
  -    /** The Decimal formatter */
  -    private DecimalFormat formatter = (DecimalFormat) DecimalFormat.getInstance(locale);
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public DecimalLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DecimalLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public DecimalLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DecimalLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public DecimalLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DecimalLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public DecimalLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DecimalLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public DecimalLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DecimalLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public DecimalLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DecimalLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern, locPattern);
  -    }
  -
  -    // --------------------------------------------------------- Methods
  -
  -    /**
  -     * Convert the specified locale-sensitive input object into an output object of the
  -     * specified type.
  -     *
  -     * @param value The input object to be converted
  -     * @param pattern The pattern is used for the convertion
  -     *
  -     * @exception ConversionException if conversion cannot be performed
  -     *  successfully
  -     */
  -    protected Object parse(Object value, String pattern) throws ParseException {
  -
  -        if (locPattern) {
  -            formatter.applyLocalizedPattern(pattern);
  -        }
  -        else {
  -            formatter.applyPattern(pattern);
  -        }
  -
  -        return formatter.parse((String) value);
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import org.apache.commons.beanutils.locale.BaseLocaleConverter;
  +
  +import java.text.DecimalFormat;
  +import java.text.ParseException;
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.lang.Decimal</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class DecimalLocaleConverter extends BaseLocaleConverter {
  +
  +
  +    // ----------------------------------------------------- Instance Variables
  +
  +    /** The Decimal formatter */
  +    private DecimalFormat formatter = (DecimalFormat) DecimalFormat.getInstance(locale);
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public DecimalLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DecimalLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public DecimalLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DecimalLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public DecimalLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DecimalLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public DecimalLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DecimalLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public DecimalLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DecimalLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public DecimalLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DecimalLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern, locPattern);
  +    }
  +
  +    // --------------------------------------------------------- Methods
  +
  +    /**
  +     * Convert the specified locale-sensitive input object into an output object of the
  +     * specified type.
  +     *
  +     * @param value The input object to be converted
  +     * @param pattern The pattern is used for the convertion
  +     *
  +     * @exception ConversionException if conversion cannot be performed
  +     *  successfully
  +     */
  +    protected Object parse(Object value, String pattern) throws ParseException {
  +
  +        if (locPattern) {
  +            formatter.applyLocalizedPattern(pattern);
  +        }
  +        else {
  +            formatter.applyPattern(pattern);
  +        }
  +
  +        return formatter.parse((String) value);
  +    }
  +}
  
  
  
  1.2       +246 -246  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/DoubleLocaleConverter.java
  
  Index: DoubleLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/DoubleLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DoubleLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ DoubleLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,246 +1,246 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.lang.Double</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class DoubleLocaleConverter extends DecimalLocaleConverter {
  -
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public DoubleLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DoubleLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public DoubleLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DoubleLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public DoubleLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DoubleLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public DoubleLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DoubleLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public DoubleLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DoubleLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public DoubleLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public DoubleLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern);
  -    }
  -}
  -
  -
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.lang.Double</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class DoubleLocaleConverter extends DecimalLocaleConverter {
  +
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public DoubleLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DoubleLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public DoubleLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DoubleLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public DoubleLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DoubleLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public DoubleLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DoubleLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public DoubleLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DoubleLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public DoubleLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public DoubleLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern);
  +    }
  +}
  +
  +
  
  
  
  1.2       +244 -244  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/FloatLocaleConverter.java
  
  Index: FloatLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/FloatLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- FloatLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ FloatLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,244 +1,244 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.math.BigDecimal</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class FloatLocaleConverter extends DecimalLocaleConverter {
  -
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public FloatLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public FloatLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public FloatLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public FloatLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public FloatLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public FloatLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public FloatLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public FloatLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public FloatLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public FloatLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public FloatLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public FloatLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern);
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.math.BigDecimal</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class FloatLocaleConverter extends DecimalLocaleConverter {
  +
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public FloatLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public FloatLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public FloatLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public FloatLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public FloatLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public FloatLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public FloatLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public FloatLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public FloatLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public FloatLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public FloatLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public FloatLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern);
  +    }
  +}
  
  
  
  1.2       +245 -245  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/IntegerLocaleConverter.java
  
  Index: IntegerLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/IntegerLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- IntegerLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ IntegerLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,245 +1,245 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.lang.Integer</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class IntegerLocaleConverter extends DecimalLocaleConverter {
  -
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -
  -    public IntegerLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public IntegerLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public IntegerLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public IntegerLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public IntegerLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public IntegerLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public IntegerLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public IntegerLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public IntegerLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public IntegerLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public IntegerLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public IntegerLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern, locPattern);
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.lang.Integer</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class IntegerLocaleConverter extends DecimalLocaleConverter {
  +
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +
  +    public IntegerLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public IntegerLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public IntegerLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public IntegerLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public IntegerLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public IntegerLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public IntegerLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public IntegerLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public IntegerLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public IntegerLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public IntegerLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public IntegerLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern, locPattern);
  +    }
  +}
  
  
  
  1.2       +244 -244  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/LongLocaleConverter.java
  
  Index: LongLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/LongLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LongLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ LongLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,244 +1,244 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.lang.Long</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class LongLocaleConverter extends DecimalLocaleConverter {
  -
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public LongLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public LongLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public LongLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public LongLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public LongLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public LongLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public LongLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public LongLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public LongLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public LongLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public LongLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public LongLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern, locPattern);
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.lang.Long</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class LongLocaleConverter extends DecimalLocaleConverter {
  +
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public LongLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public LongLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public LongLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public LongLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public LongLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public LongLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public LongLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public LongLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public LongLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public LongLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public LongLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public LongLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern, locPattern);
  +    }
  +}
  
  
  
  1.2       +244 -244  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/ShortLocaleConverter.java
  
  Index: ShortLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/ShortLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ShortLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ ShortLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,244 +1,244 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.lang.Short</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class ShortLocaleConverter extends DecimalLocaleConverter {
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public ShortLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ShortLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public ShortLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ShortLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public ShortLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ShortLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public ShortLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ShortLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public ShortLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ShortLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public ShortLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public ShortLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern);
  -    }
  -}
  -
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.lang.Short</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class ShortLocaleConverter extends DecimalLocaleConverter {
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public ShortLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ShortLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public ShortLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ShortLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public ShortLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ShortLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public ShortLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ShortLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public ShortLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ShortLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public ShortLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public ShortLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern);
  +    }
  +}
  +
  
  
  
  1.2       +263 -263  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/SqlDateLocaleConverter.java
  
  Index: SqlDateLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/SqlDateLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SqlDateLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ SqlDateLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,263 +1,263 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.sql.Date;
  -import java.text.ParseException;
  -import java.util.Locale;
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.sql.Date</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class SqlDateLocaleConverter extends DateLocaleConverter {
  -
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public SqlDateLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlDateLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public SqlDateLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlDateLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public SqlDateLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlDateLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public SqlDateLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlDateLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public SqlDateLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlDateLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public SqlDateLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlDateLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern, locPattern);
  -    }
  -
  -
  -    // --------------------------------------------------------- Methods
  -
  -    /**
  -     * Convert the specified locale-sensitive input object into an output object of the
  -     * specified type.
  -     *
  -     * @param value The input object to be converted
  -     * @param pattern The pattern is used for the convertion
  -     *
  -     * @exception ConversionException if conversion cannot be performed
  -     *  successfully
  -     */
  -    protected Object parse(Object value, String pattern) throws ParseException {
  -
  -        return new Date(((java.util.Date) super.parse((String) value, pattern)).getTime());
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.sql.Date;
  +import java.text.ParseException;
  +import java.util.Locale;
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.sql.Date</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class SqlDateLocaleConverter extends DateLocaleConverter {
  +
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public SqlDateLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlDateLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public SqlDateLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlDateLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public SqlDateLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlDateLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public SqlDateLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlDateLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public SqlDateLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlDateLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public SqlDateLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlDateLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern, locPattern);
  +    }
  +
  +
  +    // --------------------------------------------------------- Methods
  +
  +    /**
  +     * Convert the specified locale-sensitive input object into an output object of the
  +     * specified type.
  +     *
  +     * @param value The input object to be converted
  +     * @param pattern The pattern is used for the convertion
  +     *
  +     * @exception ConversionException if conversion cannot be performed
  +     *  successfully
  +     */
  +    protected Object parse(Object value, String pattern) throws ParseException {
  +
  +        return new Date(((java.util.Date) super.parse((String) value, pattern)).getTime());
  +    }
  +}
  
  
  
  1.2       +262 -262  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/SqlTimeLocaleConverter.java
  
  Index: SqlTimeLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/SqlTimeLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SqlTimeLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ SqlTimeLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,262 +1,262 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.sql.Time;
  -import java.text.ParseException;
  -import java.util.Locale;
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.sql.Time</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class SqlTimeLocaleConverter extends DateLocaleConverter {
  -
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public SqlTimeLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimeLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public SqlTimeLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimeLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public SqlTimeLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimeLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public SqlTimeLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimeLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public SqlTimeLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimeLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public SqlTimeLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimeLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern, locPattern);
  -    }
  -
  -    // --------------------------------------------------------- Methods
  -
  -    /**
  -     * Convert the specified locale-sensitive input object into an output object of the
  -     * specified type.
  -     *
  -     * @param value The input object to be converted
  -     * @param pattern The pattern is used for the convertion
  -     *
  -     * @exception ConversionException if conversion cannot be performed
  -     *  successfully
  -     */
  -    protected Object parse(Object value, String pattern) throws ParseException {
  -
  -        return new Time(((java.util.Date) super.parse((String) value, pattern)).getTime());
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.sql.Time;
  +import java.text.ParseException;
  +import java.util.Locale;
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.sql.Time</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class SqlTimeLocaleConverter extends DateLocaleConverter {
  +
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public SqlTimeLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimeLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public SqlTimeLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimeLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public SqlTimeLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimeLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public SqlTimeLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimeLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public SqlTimeLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimeLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public SqlTimeLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimeLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern, locPattern);
  +    }
  +
  +    // --------------------------------------------------------- Methods
  +
  +    /**
  +     * Convert the specified locale-sensitive input object into an output object of the
  +     * specified type.
  +     *
  +     * @param value The input object to be converted
  +     * @param pattern The pattern is used for the convertion
  +     *
  +     * @exception ConversionException if conversion cannot be performed
  +     *  successfully
  +     */
  +    protected Object parse(Object value, String pattern) throws ParseException {
  +
  +        return new Time(((java.util.Date) super.parse((String) value, pattern)).getTime());
  +    }
  +}
  
  
  
  1.2       +261 -261  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/SqlTimestampLocaleConverter.java
  
  Index: SqlTimestampLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/SqlTimestampLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SqlTimestampLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ SqlTimestampLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,261 +1,261 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  -
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import java.sql.Timestamp;
  -import java.text.ParseException;
  -import java.util.Locale;
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive String into a <code>java.sql.Timestamp</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class SqlTimestampLocaleConverter extends DateLocaleConverter {
  -
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public SqlTimestampLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimestampLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public SqlTimestampLocaleConverter(Locale locale) {
  -
  -        this(locale, (String) null);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimestampLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public SqlTimestampLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimestampLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public SqlTimestampLocaleConverter(Object defaultValue) {
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimestampLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public SqlTimestampLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimestampLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public SqlTimestampLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public SqlTimestampLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern, locPattern);
  -    }
  -
  -    // --------------------------------------------------------- Methods
  -
  -    /**
  -     * Convert the specified locale-sensitive input object into an output object of the
  -     * specified type.
  -     *
  -     * @param value The input object to be converted
  -     * @param pattern The pattern is used for the convertion
  -     *
  -     * @exception ConversionException if conversion cannot be performed
  -     *  successfully
  -     */
  -    protected Object parse(Object value, String pattern) throws ParseException {
  -
  -        return new Timestamp(((java.util.Date) super.parse(value, pattern)).getTime());
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  +
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import java.sql.Timestamp;
  +import java.text.ParseException;
  +import java.util.Locale;
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive String into a <code>java.sql.Timestamp</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class SqlTimestampLocaleConverter extends DateLocaleConverter {
  +
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public SqlTimestampLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimestampLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public SqlTimestampLocaleConverter(Locale locale) {
  +
  +        this(locale, (String) null);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimestampLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public SqlTimestampLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimestampLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public SqlTimestampLocaleConverter(Object defaultValue) {
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimestampLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public SqlTimestampLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimestampLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public SqlTimestampLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public SqlTimestampLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern, locPattern);
  +    }
  +
  +    // --------------------------------------------------------- Methods
  +
  +    /**
  +     * Convert the specified locale-sensitive input object into an output object of the
  +     * specified type.
  +     *
  +     * @param value The input object to be converted
  +     * @param pattern The pattern is used for the convertion
  +     *
  +     * @exception ConversionException if conversion cannot be performed
  +     *  successfully
  +     */
  +    protected Object parse(Object value, String pattern) throws ParseException {
  +
  +        return new Timestamp(((java.util.Date) super.parse(value, pattern)).getTime());
  +    }
  +}
  
  
  
  1.2       +319 -319  jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/StringLocaleConverter.java
  
  Index: StringLocaleConverter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/beanutils/src/java/org/apache/commons/beanutils/locale/converters/StringLocaleConverter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- StringLocaleConverter.java	3 Sep 2002 21:34:20 -0000	1.1
  +++ StringLocaleConverter.java	11 Jan 2003 22:06:23 -0000	1.2
  @@ -1,319 +1,319 @@
  -/*
  - * $Header$
  - * $Revision$
  - * $Date$
  - *
  - * ====================================================================
  - *
  - * The Apache Software License, Version 1.1
  - *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  - * reserved.
  - *
  - * Redistribution and use in source and binary forms, with or without
  - * modification, are permitted provided that the following conditions
  - * are met:
  - *
  - * 1. Redistributions of source code must retain the above copyright
  - *    notice, this list of conditions and the following disclaimer.
  - *
  - * 2. Redistributions in binary form must reproduce the above copyright
  - *    notice, this list of conditions and the following disclaimer in
  - *    the documentation and/or other materials provided with the
  - *    distribution.
  - *
  - * 3. The end-user documentation included with the redistribution, if
  - *    any, must include the following acknowlegement:
  - *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  - *    Alternately, this acknowlegement may appear in the software itself,
  - *    if and wherever such third-party acknowlegements normally appear.
  - *
  - * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  - *    Foundation" must not be used to endorse or promote products derived
  - *    from this software without prior written permission. For written
  - *    permission, please contact apache@apache.org.
  - *
  - * 5. Products derived from this software may not be called "Apache"
  - *    nor may "Apache" appear in their names without prior written
  - *    permission of the Apache Group.
  - *
  - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  - * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  - * SUCH DAMAGE.
  - * ====================================================================
  - *
  - * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation.  For more
  - * information on the Apache Software Foundation, please see
  - * <http://www.apache.org/>.
  - *
  - */
  - 
  -package org.apache.commons.beanutils.locale.converters;
  -
  -import org.apache.commons.beanutils.locale.BaseLocaleConverter;
  -
  -import java.math.BigDecimal;
  -import java.math.BigInteger;
  -import java.text.DecimalFormat;
  -import java.text.NumberFormat;
  -import java.text.ParseException;
  -import java.text.SimpleDateFormat;
  -import java.util.Date;
  -import java.util.Locale;
  -
  -
  -/**
  - * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  - * implementation that converts an incoming
  - * locale-sensitive object into a <code>java.lang.String</code> object,
  - * optionally using a default value or throwing a 
  - * {@link org.apache.commons.beanutils.ConversionException}
  - * if a conversion error occurs.</p>
  - *
  - * @author Yauheny Mikulski
  - */
  -
  -public class StringLocaleConverter extends BaseLocaleConverter {
  -
  -    // ----------------------------------------------------------- Constructors
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     */
  -    public StringLocaleConverter() {
  -
  -        this(false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public StringLocaleConverter(boolean locPattern) {
  -
  -        this(Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     */
  -    public StringLocaleConverter(Locale locale) {
  -
  -        this(locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public StringLocaleConverter(Locale locale, boolean locPattern) {
  -
  -        this(locale, (String) null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public StringLocaleConverter(Locale locale, String pattern) {
  -
  -        this(locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  -     * if a conversion error occurs.
  -     *
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public StringLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  -
  -        super(locale, pattern, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  -     * for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     */
  -    public StringLocaleConverter(Object defaultValue) {
  -
  -        this(defaultValue, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. The locale is the default locale for
  -     * this instance of the Java Virtual Machine.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public StringLocaleConverter(Object defaultValue, boolean locPattern) {
  -
  -        this(defaultValue, Locale.getDefault(), locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     */
  -    public StringLocaleConverter(Object defaultValue, Locale locale) {
  -
  -        this(defaultValue, locale, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public StringLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  -
  -        this(defaultValue, locale, null, locPattern);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     */
  -    public StringLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  -
  -        this(defaultValue, locale, pattern, false);
  -    }
  -
  -    /**
  -     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  -     * that will return the specified default value
  -     * if a conversion error occurs.
  -     *
  -     * @param defaultValue  The default value to be returned
  -     * @param locale        The locale
  -     * @param pattern       The convertion pattern
  -     * @param locPattern    Indicate whether the pattern is localized or not
  -     */
  -    public StringLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  -
  -        super(defaultValue, locale, pattern, locPattern);
  -    }
  -
  -    // --------------------------------------------------------- Methods
  -
  -    /**
  -     * Convert the specified locale-sensitive input object into an output object of the
  -     * specified type.
  -     *
  -     * @param value The input object to be converted
  -     * @param pattern The pattern is used for the convertion
  -     *
  -     * @exception ConversionException if conversion cannot be performed
  -     *  successfully
  -     */
  -    protected Object parse(Object value, String pattern) throws ParseException {
  -
  -        String result = null;
  -
  -        if ((value instanceof Integer) ||
  -                (value instanceof Long) ||
  -                (value instanceof BigInteger) ||
  -                (value instanceof Byte) ||
  -                (value instanceof Short)) {
  -
  -            result = getDecimalFormat(locale, pattern).format(((Number) value).longValue());
  -        }
  -        else if ((value instanceof Double) ||
  -                (value instanceof BigDecimal) ||
  -                (value instanceof Float)) {
  -
  -            result = getDecimalFormat(locale, pattern).format(((Number) value).doubleValue());
  -        }
  -        else if (value instanceof Date) { // java.util.Date, java.sql.Date, java.sql.Time, java.sql.Timestamp
  -
  -            SimpleDateFormat dateFormat =
  -                    new SimpleDateFormat(pattern, locale);
  -
  -            result = dateFormat.format(value);
  -        }
  -        else {
  -            result = value.toString();
  -        }
  -
  -        return result;
  -    }
  -
  -    /**
  -     * Make an instance of DecimalFormat.
  -     *
  -     * @param locale The locale
  -     * @param pattern The pattern is used for the convertion
  -     *
  -     * @exception ConversionException if conversion cannot be performed
  -     *  successfully
  -     */
  -    private DecimalFormat getDecimalFormat(Locale locale, String pattern) {
  -
  -        DecimalFormat numberFormat = (DecimalFormat) NumberFormat.getInstance(locale);
  -
  -        if (locPattern) {
  -            numberFormat.applyLocalizedPattern(pattern);
  -        }
  -        else {
  -            numberFormat.applyPattern(pattern);
  -        }
  -
  -        return numberFormat;
  -    }
  -}
  +/*
  + * $Header$
  + * $Revision$
  + * $Date$
  + *
  + * ====================================================================
  + *
  + * The Apache Software License, Version 1.1
  + *
  + * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution, if
  + *    any, must include the following acknowlegement:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowlegement may appear in the software itself,
  + *    if and wherever such third-party acknowlegements normally appear.
  + *
  + * 4. The names "The Jakarta Project", "Commons", and "Apache Software
  + *    Foundation" must not be used to endorse or promote products derived
  + *    from this software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache"
  + *    nor may "Apache" appear in their names without prior written
  + *    permission of the Apache Group.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + *
  + */
  + 
  +package org.apache.commons.beanutils.locale.converters;
  +
  +import org.apache.commons.beanutils.locale.BaseLocaleConverter;
  +
  +import java.math.BigDecimal;
  +import java.math.BigInteger;
  +import java.text.DecimalFormat;
  +import java.text.NumberFormat;
  +import java.text.ParseException;
  +import java.text.SimpleDateFormat;
  +import java.util.Date;
  +import java.util.Locale;
  +
  +
  +/**
  + * <p>Standard {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  + * implementation that converts an incoming
  + * locale-sensitive object into a <code>java.lang.String</code> object,
  + * optionally using a default value or throwing a 
  + * {@link org.apache.commons.beanutils.ConversionException}
  + * if a conversion error occurs.</p>
  + *
  + * @author Yauheny Mikulski
  + */
  +
  +public class StringLocaleConverter extends BaseLocaleConverter {
  +
  +    // ----------------------------------------------------------- Constructors
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     */
  +    public StringLocaleConverter() {
  +
  +        this(false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public StringLocaleConverter(boolean locPattern) {
  +
  +        this(Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     */
  +    public StringLocaleConverter(Locale locale) {
  +
  +        this(locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public StringLocaleConverter(Locale locale, boolean locPattern) {
  +
  +        this(locale, (String) null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public StringLocaleConverter(Locale locale, String pattern) {
  +
  +        this(locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will throw a {@link org.apache.commons.beanutils.ConversionException}
  +     * if a conversion error occurs.
  +     *
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public StringLocaleConverter(Locale locale, String pattern, boolean locPattern) {
  +
  +        super(locale, pattern, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine and an unlocalized pattern is used
  +     * for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     */
  +    public StringLocaleConverter(Object defaultValue) {
  +
  +        this(defaultValue, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. The locale is the default locale for
  +     * this instance of the Java Virtual Machine.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public StringLocaleConverter(Object defaultValue, boolean locPattern) {
  +
  +        this(defaultValue, Locale.getDefault(), locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     */
  +    public StringLocaleConverter(Object defaultValue, Locale locale) {
  +
  +        this(defaultValue, locale, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public StringLocaleConverter(Object defaultValue, Locale locale, boolean locPattern) {
  +
  +        this(defaultValue, locale, null, locPattern);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs. An unlocalized pattern is used for the convertion.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     */
  +    public StringLocaleConverter(Object defaultValue, Locale locale, String pattern) {
  +
  +        this(defaultValue, locale, pattern, false);
  +    }
  +
  +    /**
  +     * Create a {@link org.apache.commons.beanutils.locale.LocaleConverter} 
  +     * that will return the specified default value
  +     * if a conversion error occurs.
  +     *
  +     * @param defaultValue  The default value to be returned
  +     * @param locale        The locale
  +     * @param pattern       The convertion pattern
  +     * @param locPattern    Indicate whether the pattern is localized or not
  +     */
  +    public StringLocaleConverter(Object defaultValue, Locale locale, String pattern, boolean locPattern) {
  +
  +        super(defaultValue, locale, pattern, locPattern);
  +    }
  +
  +    // --------------------------------------------------------- Methods
  +
  +    /**
  +     * Convert the specified locale-sensitive input object into an output object of the
  +     * specified type.
  +     *
  +     * @param value The input object to be converted
  +     * @param pattern The pattern is used for the convertion
  +     *
  +     * @exception ConversionException if conversion cannot be performed
  +     *  successfully
  +     */
  +    protected Object parse(Object value, String pattern) throws ParseException {
  +
  +        String result = null;
  +
  +        if ((value instanceof Integer) ||
  +                (value instanceof Long) ||
  +                (value instanceof BigInteger) ||
  +                (value instanceof Byte) ||
  +                (value instanceof Short)) {
  +
  +            result = getDecimalFormat(locale, pattern).format(((Number) value).longValue());
  +        }
  +        else if ((value instanceof Double) ||
  +                (value instanceof BigDecimal) ||
  +                (value instanceof Float)) {
  +
  +            result = getDecimalFormat(locale, pattern).format(((Number) value).doubleValue());
  +        }
  +        else if (value instanceof Date) { // java.util.Date, java.sql.Date, java.sql.Time, java.sql.Timestamp
  +
  +            SimpleDateFormat dateFormat =
  +                    new SimpleDateFormat(pattern, locale);
  +
  +            result = dateFormat.format(value);
  +        }
  +        else {
  +            result = value.toString();
  +        }
  +
  +        return result;
  +    }
  +
  +    /**
  +     * Make an instance of DecimalFormat.
  +     *
  +     * @param locale The locale
  +     * @param pattern The pattern is used for the convertion
  +     *
  +     * @exception ConversionException if conversion cannot be performed
  +     *  successfully
  +     */
  +    private DecimalFormat getDecimalFormat(Locale locale, String pattern) {
  +
  +        DecimalFormat numberFormat = (DecimalFormat) NumberFormat.getInstance(locale);
  +
  +        if (locPattern) {
  +            numberFormat.applyLocalizedPattern(pattern);
  +        }
  +        else {
  +            numberFormat.applyPattern(pattern);
  +        }
  +
  +        return numberFormat;
  +    }
  +}
  
  
  

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message