public class ValueSchema extends java.lang.Object implements java.io.Serializable, SchemaValidator
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.Object |
additionalItems
Validation keywords for arrays
|
protected java.lang.Object |
additionalProperties |
protected java.util.List<java.lang.Object> |
allOf
Validation keywords for any instance type
|
protected java.util.List<java.lang.Object> |
anyOf |
protected java.lang.Object |
defaultValue |
protected java.lang.Object |
definitions |
protected java.lang.Object |
dependencies |
protected java.lang.String |
description |
protected java.util.List<java.lang.Object> |
enums |
protected java.lang.Boolean |
exclusiveMaximum |
protected java.lang.Boolean |
exclusiveMinimum |
protected java.lang.Object |
items |
protected java.lang.Number |
maximum |
protected java.lang.Integer |
maxItems |
protected java.lang.Integer |
maxLength
Validation keywords for strings
|
protected int |
maxProperties
Validation keywords for objects
|
protected java.lang.Number |
minimum
Validation keywords for numeric instances (number and integer)
|
protected java.lang.Integer |
minItems |
protected java.lang.Integer |
minLength |
protected int |
minProperties |
protected java.lang.Number |
multipleOf |
protected java.lang.Object |
not |
protected java.util.List<java.lang.Object> |
oneOf |
protected java.lang.String |
pattern |
protected java.lang.Object |
patternProperties |
protected java.lang.Object |
properties |
protected java.util.List<java.lang.String> |
required |
protected SchemaType |
schemaType |
protected java.lang.String |
title |
protected boolean |
uniqueItems |
protected java.lang.String |
unit |
| Constructor and Description |
|---|
ValueSchema(ValueSchema schema) |
| Modifier and Type | Method and Description |
|---|---|
ArraySchema |
asArray() |
BooleanSchema |
asBoolean() |
IntegerSchema |
asInteger() |
NumberSchema |
asNumber() |
ObjectSchema |
asObject() |
StringSchema |
asString() |
java.util.List<java.lang.Object> |
getAllOf() |
java.util.List<java.lang.Object> |
getAnyOf() |
java.lang.Object |
getDefaultValue() |
java.lang.String |
getDescription() |
java.util.List<java.lang.Object> |
getEnums() |
java.lang.Object |
getNot() |
java.util.List<java.lang.Object> |
getOneOf() |
SchemaType |
getSchemaType()
Returns one of the
SchemaType as defined
in @see documentation |
java.lang.String |
getTitle() |
java.lang.String |
getUnit()
Returns unit of measurement as a String value.
|
boolean |
isArraySchema() |
boolean |
isBooleanSchema() |
boolean |
isIntegerSchema() |
boolean |
isNumberSchema() |
boolean |
isObjectSchema() |
boolean |
isStringSchema() |
boolean |
validate(java.lang.Object value) |
protected boolean |
validateNull(java.lang.Object value) |
protected java.lang.Number minimum
protected java.lang.Boolean exclusiveMinimum
protected java.lang.Number maximum
protected java.lang.Boolean exclusiveMaximum
protected java.lang.Number multipleOf
protected java.lang.Integer maxLength
protected java.lang.Integer minLength
protected java.lang.String pattern
protected java.lang.Object additionalItems
protected java.lang.Object items
protected java.lang.Integer maxItems
protected java.lang.Integer minItems
protected boolean uniqueItems
protected int maxProperties
protected int minProperties
protected java.util.List<java.lang.String> required
protected java.lang.Object additionalProperties
protected java.lang.Object properties
protected java.lang.Object patternProperties
protected java.lang.Object dependencies
protected java.lang.Object defaultValue
protected java.util.List<java.lang.Object> allOf
protected java.util.List<java.lang.Object> anyOf
protected java.util.List<java.lang.Object> oneOf
protected java.lang.Object not
protected java.lang.Object definitions
protected java.util.List<java.lang.Object> enums
protected SchemaType schemaType
protected java.lang.String title
protected java.lang.String description
protected java.lang.String unit
public ValueSchema(ValueSchema schema)
public SchemaType getSchemaType()
SchemaType as defined
in @see documentationpublic boolean isNumberSchema()
SchemaType.NUMBER false otherwisepublic boolean isIntegerSchema()
SchemaType.INTEGER false otherwisepublic boolean isStringSchema()
SchemaType.STRING false otherwisepublic boolean isArraySchema()
SchemaType.ARRAY false otherwisepublic boolean isBooleanSchema()
SchemaType.BOOLEAN false otherwisepublic boolean isObjectSchema()
SchemaType.OBJECT false otherwisepublic java.lang.String getUnit()
DeviceReading accurately.public java.lang.String getTitle()
public java.lang.String getDescription()
public java.util.List<java.lang.Object> getAllOf()
public java.util.List<java.lang.Object> getAnyOf()
public java.util.List<java.lang.Object> getOneOf()
public java.lang.Object getNot()
public java.lang.Object getDefaultValue()
public java.util.List<java.lang.Object> getEnums()
public NumberSchema asNumber()
public IntegerSchema asInteger()
public StringSchema asString()
public ArraySchema asArray()
public BooleanSchema asBoolean()
public ObjectSchema asObject()
public boolean validate(java.lang.Object value)
validate in interface SchemaValidatorprotected boolean validateNull(java.lang.Object value)