Package org.springframework.boot.ansi
Class AnsiColors
java.lang.Object
org.springframework.boot.ansi.AnsiColors
Utility for working with
AnsiColor
in the context of AWT Colors
.- Since:
- 1.4.0
- Author:
- Craig Burke, Ruben Dijkstra, Phillip Webb, Michael Simons
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
Bit depths supported by this class. -
Constructor Summary
ConstructorDescriptionAnsiColors
(AnsiColors.BitDepth bitDepth) Create a newAnsiColors
instance with the specified bit depth. -
Method Summary
Modifier and TypeMethodDescriptionfindClosest
(Color color) Find the closestANSI color
to the given AWTColor
.
-
Constructor Details
-
AnsiColors
Create a newAnsiColors
instance with the specified bit depth.- Parameters:
bitDepth
- the required bit depth
-
-
Method Details
-
findClosest
Find the closestANSI color
to the given AWTColor
.- Parameters:
color
- the AWT color- Returns:
- the closest ANSI color
-