org.objectweb.fractal.gui.graph.model
Class BasicDisplay

java.lang.Object
  extended byorg.objectweb.fractal.gui.graph.model.BasicDisplay
All Implemented Interfaces:
org.objectweb.fractal.api.control.BindingController, Display

public class BasicDisplay
extends java.lang.Object
implements Display, org.objectweb.fractal.api.control.BindingController

Basic implementation of the Display interface.


Field Summary
static java.lang.String DISPLAY_LISTENERS_BINDING
          A collection client interface bound to the listeners of this model.
static java.lang.String USER_DATA_BINDING
          An optional client interface TODO javadoc.
 
Constructor Summary
BasicDisplay()
          Constructs a new BasicDisplay component.
 
Method Summary
 void bindFc(java.lang.String clientItfName, java.lang.Object serverItf)
           
 Rect getDisplayedArea()
          Returns the area of the component graph shown by this display.
 int getItfNameDisplayMode()
          Returns the displaying mode for the interfaces name of this display.
 int getMaxDepth()
          Returns the max depth at which the component graph is shown by this display.
 java.awt.Rectangle getScreenSize()
          Returns the size of this display.
 boolean isAntialiasing()
          Returns true if this display is anti aliased.
 java.lang.String[] listFc()
           
 java.lang.Object lookupFc(java.lang.String clientItfName)
           
 void setDisplayedArea(Rect displayedArea)
          Sets the area of the component graph shown by this display.
 void setIsAntialiasing(boolean isAntialiasing)
          Sets the anti aliasing option of this display.
 void setItfNameDisplayMode()
          Sets the displaying mode for the interfaces name of this display.
 void setMaxDepth(int maxDepth)
          Sets the max depth at which the component graph is shown by this display.
 void setScreenSize(java.awt.Rectangle screenSize)
          Sets the size of this display.
 void unbindFc(java.lang.String clientItfName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DISPLAY_LISTENERS_BINDING

public static final java.lang.String DISPLAY_LISTENERS_BINDING
A collection client interface bound to the listeners of this model.

See Also:
Constant Field Values

USER_DATA_BINDING

public static final java.lang.String USER_DATA_BINDING
An optional client interface TODO javadoc.

See Also:
Constant Field Values
Constructor Detail

BasicDisplay

public BasicDisplay()
Constructs a new BasicDisplay component.

Method Detail

listFc

public java.lang.String[] listFc()
Specified by:
listFc in interface org.objectweb.fractal.api.control.BindingController

lookupFc

public java.lang.Object lookupFc(java.lang.String clientItfName)
Specified by:
lookupFc in interface org.objectweb.fractal.api.control.BindingController

bindFc

public void bindFc(java.lang.String clientItfName,
                   java.lang.Object serverItf)
Specified by:
bindFc in interface org.objectweb.fractal.api.control.BindingController

unbindFc

public void unbindFc(java.lang.String clientItfName)
Specified by:
unbindFc in interface org.objectweb.fractal.api.control.BindingController

getScreenSize

public java.awt.Rectangle getScreenSize()
Description copied from interface: Display
Returns the size of this display.

Specified by:
getScreenSize in interface Display
Returns:
the size of this display, in pixels.
See Also:
Display.setScreenSize(java.awt.Rectangle)

setScreenSize

public void setScreenSize(java.awt.Rectangle screenSize)
Description copied from interface: Display
Sets the size of this display.

Specified by:
setScreenSize in interface Display
Parameters:
screenSize - the new size of this display, in pixels.
See Also:
Display.getScreenSize()

getDisplayedArea

public Rect getDisplayedArea()
Description copied from interface: Display
Returns the area of the component graph shown by this display. Indeed a display may show only a portion of a component graph, which may be changed by zooming or scrolling.

Specified by:
getDisplayedArea in interface Display
Returns:
the area of the component graph shown by this display. This area is specified in the following way: if sr is the screen size, and dr is the displayed area, then the configuration in drawn in the rectangle (sr.x+sr.w*dr.x0, sr.y+sr.h*dr.y0, sr.x+sr.w*dr.x1, sr.y+sr.h*dr.y1). So, if sr is equal to (0,0,1,1), the configuration is drawn in the full screen rectangle, if it is equal to (0.5,0,1,1) the configuration is drawn in the half right part of the screen rectangle, and so on.
See Also:
Display.setDisplayedArea(org.objectweb.fractal.gui.graph.model.Rect)

setDisplayedArea

public void setDisplayedArea(Rect displayedArea)
Description copied from interface: Display
Sets the area of the component graph shown by this display.

Specified by:
setDisplayedArea in interface Display
Parameters:
displayedArea - the new area of the component graph shown by this display.
See Also:
Display.getDisplayedArea()

isAntialiasing

public boolean isAntialiasing()
Description copied from interface: Display
Returns true if this display is anti aliased.

Specified by:
isAntialiasing in interface Display
Returns:
true if this display is anti aliased.
See Also:
Display.setIsAntialiasing(boolean)

setIsAntialiasing

public void setIsAntialiasing(boolean isAntialiasing)
Description copied from interface: Display
Sets the anti aliasing option of this display.

Specified by:
setIsAntialiasing in interface Display
Parameters:
isAntialiasing - the new anti aliasing option of this display.

getMaxDepth

public int getMaxDepth()
Description copied from interface: Display
Returns the max depth at which the component graph is shown by this display.

Specified by:
getMaxDepth in interface Display
Returns:
the max depth at which the component graph is shown by this display.
See Also:
Display.setMaxDepth(int)

setMaxDepth

public void setMaxDepth(int maxDepth)
Description copied from interface: Display
Sets the max depth at which the component graph is shown by this display.

Specified by:
setMaxDepth in interface Display
Parameters:
maxDepth - the new max depth at which the component graph is shown by this display.
See Also:
Display.getMaxDepth()

getItfNameDisplayMode

public int getItfNameDisplayMode()
Description copied from interface: Display
Returns the displaying mode for the interfaces name of this display.

Specified by:
getItfNameDisplayMode in interface Display

setItfNameDisplayMode

public void setItfNameDisplayMode()
Description copied from interface: Display
Sets the displaying mode for the interfaces name of this display.

Specified by:
setItfNameDisplayMode in interface Display