package org.pvs.superpalitos.sp_lite.util;
import java.awt.Color;
import java.util.Arrays;
public class ColorUtil {
/** Colores */
private static final Color[] COLORS = {new Color(723857), new Color(197379), new Color(15073280), new Color(1951517)};
/** Constante para identificar el color azul */
public static final int AZUL = 0;
/** Constante para identificar el color negro */
public static final int NEGRO = 1;
/** Constante para identificar el color rojo */
public static final int ROJO = 2;
/** Constante para identificar el color verde */
public static final int VERDE = 3;
public static int COLOR_DEFECTO = AZUL;
public static Color getColor(int id) {
return COLORS[id];
}
public static Color getAzul() {
return COLORS[AZUL];
}
public static Color getNegro() {
return COLORS[NEGRO];
}
public static Color getRojo() {
return COLORS[ROJO];
}
public static Color getVerde() {
return COLORS[VERDE];
}
public static Color[] getColors() {
// return COLORS;
return Arrays.copyOf(COLORS, COLORS.length);
}
}
|