import java.awt.Color;

/**
 * A simple example that uses an Object
 *
 * @author  Prof. David Bernstein, James Madison University
 * @version 1.0
 */
public class ObjectExample2
{
    public static void main(String[] args)
    {
        //[0
        Color        lightRed, darkRed;
	int          blue, green, red, shades;

	// Initialize the attributes
	darkRed = new Color(102, 0, 0);

        // Use a getter/accessor
        blue = darkRed.getBlue();
	
        // Use another method
	lightRed = darkRed.brighter();
	
	// Use equals() and a static attribute of the Color class
        shades = 1;        
	if (!lightRed.equals(Color.RED))
        {
	    shades++;
	}
        //]0
    }
}
