Package com.alibaba.fastjson2.schema
Enum JSONSchema.Type
- java.lang.Object
-
- java.lang.Enum<JSONSchema.Type>
-
- com.alibaba.fastjson2.schema.JSONSchema.Type
-
- All Implemented Interfaces:
Serializable,Comparable<JSONSchema.Type>
- Enclosing class:
- JSONSchema
public static enum JSONSchema.Type extends Enum<JSONSchema.Type>
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static JSONSchema.Typeof(String typeStr)static JSONSchema.TypevalueOf(String name)Returns the enum constant of this type with the specified name.static JSONSchema.Type[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
Null
public static final JSONSchema.Type Null
-
Boolean
public static final JSONSchema.Type Boolean
-
Object
public static final JSONSchema.Type Object
-
Array
public static final JSONSchema.Type Array
-
Number
public static final JSONSchema.Type Number
-
String
public static final JSONSchema.Type String
-
Integer
public static final JSONSchema.Type Integer
-
Enum
public static final JSONSchema.Type Enum
-
Const
public static final JSONSchema.Type Const
-
OneOf
public static final JSONSchema.Type OneOf
-
AllOf
public static final JSONSchema.Type AllOf
-
AnyOf
public static final JSONSchema.Type AnyOf
-
Any
public static final JSONSchema.Type Any
-
UnresolvedReference
public static final JSONSchema.Type UnresolvedReference
-
-
Method Detail
-
values
public static JSONSchema.Type[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (JSONSchema.Type c : JSONSchema.Type.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static JSONSchema.Type valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified nameNullPointerException- if the argument is null
-
of
public static JSONSchema.Type of(String typeStr)
-
-