public final class ColorUtils extends Object
For all assertEquals/equals methods, the "expected" parameter can be either:
Color
object specifying the exact colorString
object containing the hexadecimal description of the exact colorString
object containing the name of a color for an approximate comparison.
The authorized names are those of the predefined Color objects defined in the Java
Color class.Modifier and Type | Method and Description |
---|---|
static void |
assertEquals(Object expected,
Color actual) |
static void |
assertEquals(String message,
Object expected,
Color actual) |
static void |
assertSimilar(Object expected,
Color actual) |
static void |
assertSimilar(String message,
Object expected,
Color actual) |
static boolean |
equals(Object expectedColor,
Color actual) |
static boolean |
equals(String expectedColor,
Color actual) |
static Color |
getColor(String hexaString) |
static String |
getColorDescription(Color color)
Returns a description string for a given Color object
|
static String |
getColorDescription(Object color)
Returns a normalized string description given a Color or another String description
|
static String |
getColorDescription(String color)
Normalizes a given color description string
|
public static String getColorDescription(Object color)
public static String getColorDescription(Color color)
Copyright © 2004–2016. All rights reserved.