public static boolean check(final String color) { if (ColorValidator.isShortModeWithoutAlpha(color) || ColorValidator.isLongModeWithoutAlpha(color) || ColorValidator.isValid(color)) { return true; } return false; }
"value of [#f]"); } else if (ColorValidator.isLongModeWithoutAlpha(color)) { red = getRFromString(color); green = getGFromString(color);
public void fromStringWithoutAlpha(@Nonnull final String color) { colorString = color + toHex(alpha); if (ColorValidator.isShortModeWithoutAlpha(color)) { red = getRFromString(color); green = getGFromString(color); blue = getBFromString(color); } else if (ColorValidator.isLongModeWithoutAlpha(color)) { red = getRFromString(color); green = getGFromString(color); blue = getBFromString(color); } else if (ColorValidator.isValid(color)) { red = getRFromString(color); green = getGFromString(color); blue = getBFromString(color); } else { red = green = blue = 1.0f; } }