Enum ApiVersion
- All Implemented Interfaces:
Serializable
,Comparable<ApiVersion>
,Constable
,Producible<ApiVersion>
API versions supported for the actuator API. This enum may be injected into actuator
endpoints in order to return a response compatible with the requested version.
- Since:
- 2.4.0
- Author:
- Phillip Webb
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionMime type that can be produced.static ApiVersion
Returns the enum constant of this type with the specified name.static ApiVersion[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.Methods inherited from class java.lang.Enum
clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
Methods inherited from interface org.springframework.boot.actuate.endpoint.Producible
isDefault
-
Enum Constant Details
-
V2
Version 2 (supported by Spring Boot 2.0+). -
V3
Version 3 (supported by Spring Boot 2.2+).
-
-
Field Details
-
LATEST
The latest API version.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
getProducedMimeType
Description copied from interface:Producible
Mime type that can be produced.- Specified by:
getProducedMimeType
in interfaceProducible<ApiVersion>
- Returns:
- the producible mime type
-