All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class att.grappa.DrawSubgraph

java.lang.Object
   |
   +----att.grappa.DrawObject
           |
           +----att.grappa.DrawSubgraph

public class DrawSubgraph
extends DrawObject
The base class for subgraph drawing.

Version:
1.1, 30 Sep 1999; Copyright 1996 - 1999 by AT&T Corp.
Author:
John Mocenigo, Research @ AT&T Labs

Variable Index

 o defaultGraphShape
Default shape to use when representing a subgraph.

Constructor Index

 o DrawSubgraph()
This constructor creates an uninitialized DrawSubgraph object.

Method Index

 o createPeer(DrawPane)
Creates the drawing peer specific for this object and the specified pane.
 o isLR()
Check if the layout of this subgraph is left-to-right in nature.
 o setBounds()
This method to be called when the bounding box needs to be calculated.
 o setLR(boolean)
Set the layout orientation indicator.
 o update(Observable, Object)
This method is called whenever an observed Attribute is changed.

Variables

 o defaultGraphShape
 public static final String defaultGraphShape
Default shape to use when representing a subgraph.

Constructors

 o DrawSubgraph
 public DrawSubgraph()
This constructor creates an uninitialized DrawSubgraph object. Upon creation, a default set of attributes for observing are specified (in addition to those specified when its super() constructor is called.

See Also:
Observer

Methods

 o isLR
 public boolean isLR()
Check if the layout of this subgraph is left-to-right in nature.

Returns:
true if the layout is left-to-right, false if it is top-to-bottom
 o setLR
 protected void setLR(boolean newLR)
Set the layout orientation indicator. Changing this value does not actually change the layout orientation. This value is only set to reflect the layout orientation as indicated by the element rankdir attribute, which is used by the layout engine to actually accomplish the manner of the layout.

Parameters:
newLR - pass true to indicate that the layout is left-to-right or pass false to indicate a top-to-bottom layout orientation
 o setBounds
 public Rectangle setBounds()
This method to be called when the bounding box needs to be calculated.

Returns:
the bounding box of this object in graph co-ordinates
Overrides:
setBounds in class DrawObject
 o update
 public void update(Observable obs,
                    Object arg)
This method is called whenever an observed Attribute is changed. It is required by the Observer interface.

Parameters:
obs - the observable object that has been updated
arg - when not null, it indicates that obs need no longer be observed and in its place arg should be observed.
Overrides:
update in class DrawObject
 o createPeer
 public void createPeer(DrawPane pane)
Creates the drawing peer specific for this object and the specified pane.

Parameters:
pane - the DrawPane upon which the object will be drawn.
Overrides:
createPeer in class DrawObject

All Packages  Class Hierarchy  This Package  Previous  Next  Index