クラス JSONNumber


@NullMarked public final class JSONNumber extends JSONPrimitive<Number>
json構造におけるnumber型を表現します。
  • メソッドの詳細

    • getType

      public JSONValueType<?> getType()
      クラスからコピーされた説明: JSONValue
      値の型を取得します。
      定義:
      getType クラス内 JSONValue<Number>
      戻り値:
      この値の型を表現するオブジェクト。
    • byteValue

      public byte byteValue()
      byteとして取得します。
      戻り値:
      byte。
    • shortValue

      public short shortValue()
      shortとして取得します。
      戻り値:
      short。
    • intValue

      public int intValue()
      intとして取得します。
      戻り値:
      int。
    • longValue

      public long longValue()
      longとして取得します。
      戻り値:
      long。
    • floatValue

      public float floatValue()
      floatとして取得します。
      戻り値:
      float。
    • doubleValue

      public double doubleValue()
      doubleとして取得します。
      戻り値:
      double。
    • valueOf

      public static JSONNumber valueOf(Number value)
      NumberをJSONNumberに変換します。
      パラメータ:
      value - Number。
      戻り値:
      JSONNumber。