### Question:
ColorFunctions { @ScalarFunction @LiteralParameters({"x", "y"}) @Constraint(variable = "y", expression = "min(2147483647, x + 15)") @SqlType("varchar(y)") public static Slice render(@SqlType("varchar(x)") Slice value, @SqlType(ColorType.NAME) long color) { StringBuilder builder = new StringBuilder(value.length()); builder.append(ansiColorEscape(color)) .append(value.toStringUtf8()) .append(ANSI_RESET); return utf8Slice(builder.toString()); } private  ColorFunctions(); @ScalarFunction @LiteralParameters("x") @SqlType(ColorType.NAME) static long color(@SqlType("varchar(x)") Slice color); @ScalarFunction @SqlType(ColorType.NAME) static long rgb(@SqlType(StandardTypes.BIGINT) long red, @SqlType(StandardTypes.BIGINT) long green, @SqlType(StandardTypes.BIGINT) long blue); @ScalarFunction @SqlType(ColorType.NAME) static long color(
            @SqlType(StandardTypes.DOUBLE) double value,
            @SqlType(StandardTypes.DOUBLE) double low,
            @SqlType(StandardTypes.DOUBLE) double high,
            @SqlType(ColorType.NAME) long lowColor,
            @SqlType(ColorType.NAME) long highColor); @ScalarFunction @SqlType(ColorType.NAME) static long color(@SqlType(StandardTypes.DOUBLE) double fraction, @SqlType(ColorType.NAME) long lowColor, @SqlType(ColorType.NAME) long highColor); @ScalarFunction @LiteralParameters({"x", "y"}) @Constraint(variable = "y", expression = "min(2147483647, x + 15)") // Color formatting uses 15 characters. Note that if the ansiColorEscape function implementation // changes, this value may be invalidated. @SqlType("varchar(y)") static Slice render(@SqlType("varchar(x)") Slice value, @SqlType(ColorType.NAME) long color); @ScalarFunction @SqlType("varchar(35)") static Slice render(@SqlType(StandardTypes.BIGINT) long value, @SqlType(ColorType.NAME) long color); @ScalarFunction @SqlType("varchar(41)") static Slice render(@SqlType(StandardTypes.DOUBLE) double value, @SqlType(ColorType.NAME) long color); @ScalarFunction @SqlType("varchar(16)") static Slice render(@SqlType(StandardTypes.BOOLEAN) boolean value); @ScalarFunction @SqlType(StandardTypes.VARCHAR) static Slice bar(@SqlType(StandardTypes.DOUBLE) double percent, @SqlType(StandardTypes.BIGINT) long width); @ScalarFunction @SqlType(StandardTypes.VARCHAR) static Slice bar(
            @SqlType(StandardTypes.DOUBLE) double percent,
            @SqlType(StandardTypes.BIGINT) long width,
            @SqlType(ColorType.NAME) long lowColor,
            @SqlType(ColorType.NAME) long highColor);  }### Answer:
@Test public void testRenderBoolean() { assertEquals(render(true), toSlice("\u001b[38;5;2m✓\u001b[0m")); assertEquals(render(false), toSlice("\u001b[38;5;1m✗\u001b[0m")); }