import java.awt.Color;
import java.awt.Graphics;

public class ContainerSquare{
	private final static Color BORDER_COLOR = Color.RED;
	private final static Color FILL_COLOR   = Color.BLACK;

	int x, y;
	int height, width;
	private Color fillColor;
	private Color borderColor; 


	
	ContainerSquare(){
		x           = 0;
		y           = 0;
		height      = 0;
		width       = 0;
		fillColor   = null; 
		borderColor = null;
	}



	ContainerSquare(int x, int y, int width, int height){
		this(x, y, width, height, FILL_COLOR, BORDER_COLOR);
	}



	ContainerSquare(int x, int y, int width, int height, Color fillColor, Color borderColor){
		this.x           = x;
		this.y           = y;
		this.width       = width;
		this.height      = height;
		this.fillColor   = fillColor;
		this.borderColor = borderColor;
	}



	public void setDimensions(int x, int y, int width, int height){
		this.x      = x;
		this.y      = y;
		this.width  = width;
		this.height = height;
	}



	public void draw(Graphics g){
		g.setColor(fillColor);
		g.fillRect(x, y, width-1, height-1);
		g.setColor(borderColor);
		g.drawRect(x, y, width-1, height-1);
	}
}
