public interface GroupedProperties
Modifier and Type | Method and Description |
---|---|
static GroupedProperties |
fromJson(Schema schema,
com.fasterxml.jackson.databind.JsonNode json)
Create an object that implements GroupedProperties from a tree of JsonNode objects
|
static GroupedProperties |
fromJson(Schema schema,
java.lang.String json)
Create an object that implements GroupedProperties from a JSON string,
|
java.lang.Boolean |
getBooleanProp(java.lang.String propertyName)
Retrieve the value of a property with type
Property.Type.BOOLEAN in the schema. |
java.lang.Double |
getDoubleProp(java.lang.String propertyName)
Retrieve the value of a property with type
Property.Type.DOUBLE in the schema. |
FileReference |
getFileReferenceProp(java.lang.String propertyName)
Retrieve the value of a property with type
Property.Type.FILE in the schema. |
java.lang.Long |
getLongProp(java.lang.String propertyName)
Retrieve the value of a property with type
Property.Type.LONG in the schema. |
java.util.regex.Pattern |
getRegexProp(java.lang.String propertyName)
Retrieve the value of a property with type
Property.Type.REGEX in the schema. |
java.util.List<GroupedProperties> |
getRepeatGroup(java.lang.String groupName)
Retrieve a group with type
Group.Type.REPEAT in the schema. |
GroupedProperties |
getSimpleGroup(java.lang.String groupName)
Retrieve a group with type
Group.Type.SIMPLE in the schema. |
java.util.List<java.lang.String> |
getStringListProp(java.lang.String propertyName)
Retrieve the value of a property with type
Property.Type.LIST in the schema. |
java.util.Map<java.lang.String,java.lang.String> |
getStringMapProp(java.lang.String propertyName)
Retrieve the value of a property with type
Property.Type.MAP in the schema. |
java.lang.String |
getStringProp(java.lang.String propertyName)
Retrieve the value of a property with type
Property.Type.STRING or
Property.Type.ENUM in the schema. |
java.lang.String |
toJson()
Serialize the content of this object to a JSON String.
|
com.fasterxml.jackson.databind.JsonNode |
toJsonNode()
Convert this object into a tree of JsonNode objects.
|
static GroupedProperties fromJson(Schema schema, java.lang.String json) throws com.fasterxml.jackson.core.JsonProcessingException
schema
- The schema for the GroupedPropertiesjson
- A Json string containing the property valuescom.fasterxml.jackson.core.JsonProcessingException
- When the JSON is invalidjava.lang.IllegalArgumentException
- When the JSON is valid but does not match the provided
schemastatic GroupedProperties fromJson(Schema schema, com.fasterxml.jackson.databind.JsonNode json) throws com.fasterxml.jackson.core.JsonProcessingException
schema
- The schema for the GroupedPropertiesjson
- The root node of the object treecom.fasterxml.jackson.core.JsonProcessingException
- When the JSON is valid but does not match the provided schemajava.lang.String toJson()
com.fasterxml.jackson.databind.JsonNode toJsonNode()
java.lang.Boolean getBooleanProp(java.lang.String propertyName)
Property.Type.BOOLEAN
in the schema.propertyName
- The name of the propertyjava.lang.Double getDoubleProp(java.lang.String propertyName)
Property.Type.DOUBLE
in the schema.propertyName
- The name of the propertyFileReference getFileReferenceProp(java.lang.String propertyName)
Property.Type.FILE
in the schema.propertyName
- The name of the propertyjava.lang.Long getLongProp(java.lang.String propertyName)
Property.Type.LONG
in the schema.propertyName
- The name of the propertyjava.util.regex.Pattern getRegexProp(java.lang.String propertyName)
Property.Type.REGEX
in the schema.propertyName
- The name of the propertyjava.lang.String getStringProp(java.lang.String propertyName)
Property.Type.STRING
or
Property.Type.ENUM
in the schema.propertyName
- The name of the propertyjava.util.List<java.lang.String> getStringListProp(java.lang.String propertyName)
Property.Type.LIST
in the schema.propertyName
- The name of the propertyjava.util.Map<java.lang.String,java.lang.String> getStringMapProp(java.lang.String propertyName)
Property.Type.MAP
in the schema.propertyName
- The name of the propertyGroupedProperties getSimpleGroup(java.lang.String groupName)
Group.Type.SIMPLE
in the schema.groupName
- The name of the groupjava.util.List<GroupedProperties> getRepeatGroup(java.lang.String groupName)
Group.Type.REPEAT
in the schema.groupName
- The name of the group