Ignore:
Timestamp:
2017-12-23T02:40:43+01:00 (8 years ago)
Author:
Don-vip
Message:

see #15682 - upgrade to JSR 374 (JSON Processing) API 1.1.2

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/javax/json/JsonNumber.java

    r6756 r13231  
    22 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
    33 *
    4  * Copyright (c) 2011-2013 Oracle and/or its affiliates. All rights reserved.
     4 * Copyright (c) 2011-2017 Oracle and/or its affiliates. All rights reserved.
    55 *
    66 * The contents of this file are subject to the terms of either the GNU
     
    99 * may not use this file except in compliance with the License.  You can
    1010 * obtain a copy of the License at
    11  * https://glassfish.dev.java.net/public/CDDL+GPL_1_1.html
    12  * or packager/legal/LICENSE.txt.  See the License for the specific
     11 * https://oss.oracle.com/licenses/CDDL+GPL-1.1
     12 * or LICENSE.txt.  See the License for the specific
    1313 * language governing permissions and limitations under the License.
    1414 *
    1515 * When distributing the software, include this License Header Notice in each
    16  * file and include the License file at packager/legal/LICENSE.txt.
     16 * file and include the License file at LICENSE.txt.
    1717 *
    1818 * GPL Classpath Exception:
     
    5151 * value internally.
    5252 * The {@code BigDecimal} object can be constructed from the following types:
    53  * {@link BigDecimal#BigDecimal(int) <code>int</code>},
    54  * {@link BigDecimal#BigDecimal(long) <code>long</code>},
    55  * {@link BigDecimal#BigDecimal(BigInteger) <code>BigInteger</code>},
    56  * {@link BigDecimal#valueOf(double) <code>double</code>}, and
    57  * {@link BigDecimal#BigDecimal(String) <code>String</code>}.
     53 * <code>int</code> {@link BigDecimal#BigDecimal(int)},
     54 * <code>long</code> {@link BigDecimal#BigDecimal(long)},
     55 * <code>BigInteger</code> {@link BigDecimal#BigDecimal(BigInteger)},
     56 * <code>double</code> {@link BigDecimal#valueOf(double)}, and
     57 * <code>String</code> {@link BigDecimal#BigDecimal(String)}.
    5858 * Some of the method semantics in this class are defined using the
    5959 * {@code BigDecimal} semantics.
    60  *
    61  * @author Jitendra Kotamraju
    6260 */
    6361public interface JsonNumber extends JsonValue {
     
    138136
    139137    /**
    140      * Returns this JSON number as a {@link BigDecimal} object. This is a
     138     * Returns this JSON number as a {@link BigInteger} object. This is a
    141139     * convenience method for {@code bigDecimalValue().toBigIntegerExact()}.
    142140     *
     
    167165
    168166    /**
     167     * Returns this JSON number as a {@link Number} object.
     168     *
     169     * @return a {@link Number} representation of the JSON number
     170     *
     171     * @since 1.1
     172     */
     173    default Number numberValue() {
     174        throw new UnsupportedOperationException();
     175    }
     176
     177    /**
    169178     * Returns a JSON text representation of the JSON number. The
    170179     * representation is equivalent to {@link BigDecimal#toString()}.
     
    181190     * objects are <i>equal</i>
    182191     *
    183      * @param obj the object to be compared for equality with 
     192     * @param obj the object to be compared for equality with
    184193     *      this {@code JsonNumber}
    185      * @return {@code true} if the specified object is equal to this 
     194     * @return {@code true} if the specified object is equal to this
    186195     *      {@code JsonNumber}
    187196     */
Note: See TracChangeset for help on using the changeset viewer.