Class Deprecation
- java.lang.Object
- org.springframework.boot.configurationmetadata.Deprecation
- All Implemented Interfaces:
Serializable
public class Deprecation extends Object implements Serializable
Indicate that a property is deprecated. Provide additional information about the deprecation.- Since:
- 1.3.0
- See Also:
- Serialized Form
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Deprecation.Level
Define the deprecation level.
Constructor Summary
Constructors Constructor Description Deprecation()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Deprecation.Level
getLevel()
Define theDeprecation.Level
of deprecation.String
getReason()
A reason why the related property is deprecated, if any.String
getReplacement()
The full name of the property that replaces the related deprecated property, if any.String
getShortReason()
A single-line, single-sentence reason why the related property is deprecated, if any.void
setLevel(Deprecation.Level level)
void
setReason(String reason)
void
setReplacement(String replacement)
void
setShortReason(String shortReason)
String
toString()
Constructor Detail
Deprecation
public Deprecation()
Method Detail
getLevel
public Deprecation.Level getLevel()
Define theDeprecation.Level
of deprecation.- Returns:
- the deprecation level
setLevel
public void setLevel(Deprecation.Level level)
getReason
public String getReason()
A reason why the related property is deprecated, if any. Can be multi-lines.- Returns:
- the deprecation reason
- See Also:
getShortReason()
getShortReason
public String getShortReason()
A single-line, single-sentence reason why the related property is deprecated, if any.- Returns:
- the short deprecation reason
- See Also:
getReason()
setShortReason
public void setShortReason(String shortReason)
getReplacement
public String getReplacement()
The full name of the property that replaces the related deprecated property, if any.- Returns:
- the replacement property name
setReplacement
public void setReplacement(String replacement)