package prolog.treeview;

import java.awt.*;

public interface INodeRenderer
{
	/**
	 * renders the given object into the given graphic context
	 * @param g - the graphic context to render into
	 * @param rect - the rect where to render into
	 * @param obj - the node content that should be rendered
	 */
	public void renderNode( Graphics2D g, Rectangle rect, Object obj );

	/**
	 * calculates the require size this renderer require to render
	 * the given object
	 * @return the size of the rendered object
	 */
	public Dimension calculateDimension( Object obj );
}
