java.lang.Object
io.aiven.commons.kafka.config.DeprecatedInfo
Contains the information about a deprecated ConfigKey
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic DeprecatedInfo.Builderbuilder()Creates a new builder.Gets a string that contains the deprecated information.Gets the descriptions.getSince()Gets version in which the option became deprecated.booleanTests whether this option is subject to removal in a future version.voidoverrideSince(SinceInfo.Builder builder) Sets the override for this SinceInfo.voidoverrideSince(Map<SinceInfo.OverrideRange, SinceInfo.Data> overrideMap) Sets the override from the Builder associated with the matching OverrideRange in the overrideMap.toString()
-
Method Details
-
builder
Creates a new builder.- Returns:
- a new builder.
-
getDescription
Gets the descriptions.- Returns:
- the descriptions.
-
getSince
Gets version in which the option became deprecated.- Returns:
- the version in which the option became deprecated.
-
overrideSince
Sets the override for this SinceInfo. The builder must defineversion. ThegroupIdandartifactIdare optional and will be displayed if present.- Parameters:
builder- the builder to define the override.
-
overrideSince
Sets the override from the Builder associated with the matching OverrideRange in the overrideMap. If multiple ranges match the last one in the map will be applied.- Parameters:
overrideMap- the map of OverrideRanges and builders to apply.
-
isForRemoval
public boolean isForRemoval()Tests whether this option is subject to removal in a future version.- Returns:
- whether this option is subject to removal in a future version.
-
toString
-
formatted
Gets a string that contains the deprecated information. The output will read: "namedeprecated for removal sincesince:description". Wherenameis the name argument. Ifnameis empty, the start of the result will be "Deprecated"- "for removal" will not be present if
forRemovalisfalse. - "since
since" will contain thesincetext, or be omitted ifsinceis not set. - ":
description" will contain thedescriptiontext, or be omitted ifdescriptionis empty.
- Parameters:
name- The name to use for the formatted display.- Returns:
- the formatted information.
-