Package io.vertx.rxjava3.json.schema
Class JsonSchema
- java.lang.Object
- 
- io.vertx.rxjava3.json.schema.JsonSchema
 
- 
- All Implemented Interfaces:
- io.vertx.lang.rx.RxDelegate
 
 public class JsonSchema extends Object implements io.vertx.lang.rx.RxDelegate A Json-Schema holder.There are 2 kinds of Json-Schema's: - JSON Object based
- Boolean based
 This is a common interface to handle all kinds of schemas. NOTE: This class has been automatically generated from the originalnon RX-ified interface using Vert.x codegen.
- 
- 
Field SummaryFields Modifier and Type Field Description static io.vertx.lang.rx.TypeArg<JsonSchema>__TYPE_ARGstatic Predicate<Map.Entry<String,Object>>EXCLUDE_ANNOTATION_ENTRIESPredicate to filter out annotation keys.static Predicate<String>EXCLUDE_ANNOTATIONSPredicate to filter out annotation keys.
 - 
Constructor SummaryConstructors Constructor Description JsonSchema(JsonSchema delegate)JsonSchema(Object delegate)
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description JsonSchemaannotate(String key, String value)Annotates the schema.booleancontainsKey(String key)Checks if the given key is present in the schema object.booleanequals(Object o)Set<String>fieldNames()Returns the field names on the underlying object.<R> Rget(String key)Get a type casted value by key.<R> Rget(String key, R fallback)Get a type casted value by key.JsonSchemagetDelegate()inthashCode()static JsonSchemanewInstance(JsonSchema arg)static JsonSchemaof(boolean bool)Factory method to create aJsonSchemafrom aBoolean.static JsonSchemaof(JsonObject json)Factory method to create aJsonSchemafrom a .static JsonSchemaof(String id, JsonObject json)Factory method to create aJsonSchemafrom a .StringtoString()
 
- 
- 
- 
Field Detail- 
__TYPE_ARGpublic static final io.vertx.lang.rx.TypeArg<JsonSchema> __TYPE_ARG 
 - 
EXCLUDE_ANNOTATIONSpublic static final Predicate<String> EXCLUDE_ANNOTATIONS Predicate to filter out annotation keys.
 
- 
 - 
Constructor Detail- 
JsonSchemapublic JsonSchema(JsonSchema delegate) 
 - 
JsonSchemapublic JsonSchema(Object delegate) 
 
- 
 - 
Method Detail- 
getDelegatepublic JsonSchema getDelegate() - Specified by:
- getDelegatein interface- io.vertx.lang.rx.RxDelegate
 
 - 
ofpublic static JsonSchema of(JsonObject json) Factory method to create aJsonSchemafrom a .- Parameters:
- json- a JSON Object.
- Returns:
- a wrapper for the input object.
 
 - 
ofpublic static JsonSchema of(String id, JsonObject json) Factory method to create aJsonSchemafrom a .- Parameters:
- id- will force the given id as the schema $id.
- json- a JSON Object.
- Returns:
- a wrapper for the input object.
 
 - 
ofpublic static JsonSchema of(boolean bool) Factory method to create aJsonSchemafrom aBoolean.- Parameters:
- bool- a boolean.
- Returns:
- a wrapper for the input object.
 
 - 
annotatepublic JsonSchema annotate(String key, String value) Annotates the schema. An annotation is a extra key-value added to the schema that are not relevant for validation but can be used to store pre-computed state.- Parameters:
- key- a key
- value- a value
- Returns:
 
 - 
getpublic <R> R get(String key) Get a type casted value by key.- Parameters:
- key- a key
- Returns:
- the value or null
 
 - 
getpublic <R> R get(String key, R fallback) Get a type casted value by key. If the key is missing, then the fallback value is returned.- Parameters:
- key- a key
- fallback- fallback when key is not present
- Returns:
- the value or null
 
 - 
containsKeypublic boolean containsKey(String key) Checks if the given key is present in the schema object.- Parameters:
- key- a key
- Returns:
- trueif present
 
 - 
fieldNamespublic Set<String> fieldNames() Returns the field names on the underlying object.- Returns:
- field names
 
 - 
newInstancepublic static JsonSchema newInstance(JsonSchema arg) 
 
- 
 
-