Enum Class JsonFormat.Shape
- All Implemented Interfaces:
Serializable, Comparable<JsonFormat.Shape>, Constable
- Enclosing class:
JsonFormat
Shape of the JSON value
JSON 值的形状
- Since:
- JDK 25, opencode-base-json V1.0.0
- Author:
- Leon Soo www.LeonSoo.com
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionDefault shape based on type.Force array output.Force boolean output.Force number output.Force floating-point number output.Force integer number output.Force object output.Force scalar (non-structured) value.Force string output. -
Method Summary
Modifier and TypeMethodDescriptionstatic JsonFormat.ShapeReturns the enum constant of this class with the specified name.static JsonFormat.Shape[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
ANY
Default shape based on type. 基于类型的默认形状。 -
SCALAR
Force scalar (non-structured) value. 强制标量(非结构化)值。 -
ARRAY
Force array output. 强制数组输出。 -
OBJECT
Force object output. 强制对象输出。 -
NUMBER
Force number output. 强制数字输出。 -
NUMBER_INT
Force integer number output. 强制整数输出。 -
NUMBER_FLOAT
Force floating-point number output. 强制浮点数输出。 -
STRING
Force string output. 强制字符串输出。 -
BOOLEAN
Force boolean output. 强制布尔值输出。
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-