
package jp.riken.brain.ni.samuraigraph.figure.java2d;

import java.util.*;
import java.awt.*;
import java.awt.geom.*;
import jp.riken.brain.ni.samuraigraph.base.*;
import jp.riken.brain.ni.samuraigraph.data.*;
import jp.riken.brain.ni.samuraigraph.figure.*;


/**
 * 
 */
public class SGDrawingElementBar2D extends SGDrawingElementBar
	implements SGIDrawingElementJava2D
{

	/**
	 * 
	 */
	public SGDrawingElementBar2D()
	{
		super();
	}



	/**
	 * 
	 */
	public SGDrawingElementBar2D(
		final float x,
		final float y,
		final float w,
		final float h )
	{
		super();
		this.setBounds( x, y, w, h );
	}



	/**
	 * 
	 */
	public Rectangle2D getElementBounds()
	{
		Rectangle2D rect = new Rectangle2D.Float(
			this.getX(), this.getY(), this.getWidth(), this.getHeight() );
		return rect;
	}


	/**
	 * 
	 */
	public boolean contains(final int x, final int y)
	{
		return this.getElementBounds().contains(x,y);
	}


	/**
	 * 
	 */
	public Shape getShape()
	{
		return this.getElementBounds();
	}



}
