Class ConfigurationMetadataProperty
java.lang.Object
org.springframework.boot.configurationmetadata.ConfigurationMetadataProperty
- All Implemented Interfaces:
Serializable
Define a configuration property. Each property is fully identified by its
id which is composed of a namespace prefix (the
group id), if any and the name of the property.- Since:
- 1.3.0
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThe default value, if any.TheDeprecationfor this property, if any.A description of the property, if any.getHints()Return the hints of this item.getId()The full identifier of the property, in lowercase dashed form (e.g.getName()The name of the property, in lowercase dashed form (e.g.A single-line, single-sentence description of this property, if any.getType()The class name of the data type of the property.booleanSpecify if the property is deprecated.voidsetDefaultValue(Object defaultValue) voidsetDeprecation(Deprecation deprecation) voidsetDescription(String description) voidvoidvoidsetShortDescription(String shortDescription) void
-
Constructor Details
-
ConfigurationMetadataProperty
public ConfigurationMetadataProperty()
-
-
Method Details
-
getId
The full identifier of the property, in lowercase dashed form (e.g. my.group.simple-property)- Returns:
- the property id
-
setId
-
getName
The name of the property, in lowercase dashed form (e.g. simple-property). If this item does not belong to any group, the id is returned.- Returns:
- the property name
-
setName
-
getType
The class name of the data type of the property. For example,java.lang.String.For consistency, the type of a primitive is specified using its wrapper counterpart, i.e.
booleanbecomesjava.lang.Boolean. If the type holds generic information, these are provided as well, i.e. aHashMapof String to Integer would be defined asjava.util.HashMap <java.lang.String,java.lang.Integer>.Note that this class may be a complex type that gets converted from a String as values are bound.
- Returns:
- the property type
-
setType
-
getDescription
A description of the property, if any. Can be multi-lines.- Returns:
- the property description
- See Also:
-
setDescription
-
getShortDescription
A single-line, single-sentence description of this property, if any.- Returns:
- the property short description
- See Also:
-
setShortDescription
-
getDefaultValue
The default value, if any.- Returns:
- the default value
-
setDefaultValue
-
getHints
Return the hints of this item.- Returns:
- the hints
-
getDeprecation
TheDeprecationfor this property, if any.- Returns:
- the deprecation
- See Also:
-
setDeprecation
-
isDeprecated
public boolean isDeprecated()Specify if the property is deprecated.- Returns:
- if the property is deprecated
- See Also:
-