cz.cuni.pogamut.shed.widget
Class SlotEnvelope

Package class diagram package SlotEnvelope
java.lang.Object
  extended by org.netbeans.api.visual.widget.Widget
      extended by cz.cuni.pogamut.shed.widget.SlotEnvelope
All Implemented Interfaces:
IShedEnvelope<ShedSenseWidget>, Accessible

public class SlotEnvelope
extends org.netbeans.api.visual.widget.Widget
implements IShedEnvelope<ShedSenseWidget>

Envelope for visual representation element (e.g. drive/choice) with trigger and reference to some other element. The element itself is in the left top corner, the trigger is shown on the right of element and attachment is under the representation of trigger.

Author:
HonzaH
See Also:
ShedDriveEnvelope, ShedChoiceEnvelope

Nested Class Summary
 
Nested classes/interfaces inherited from class org.netbeans.api.visual.widget.Widget
org.netbeans.api.visual.widget.Widget.Dependency
 
Field Summary
protected  ShedWidget slotWidget
          Widget representing the slot element, e.g.
 
Constructor Summary
SlotEnvelope(ShedScene scene, ShedWidget slotWidget, ShedTriggerEnvelope triggerEnvelope, ExpandedActionEnvelope expandedActionEnvelope)
          Create slot envelope for some element (e.g.
 
Method Summary
 void add(ShedSenseWidget widget, int position)
          Add widget to the envelope at the specified position.
 ExpandedActionEnvelope getExpandedActionEnvelope()
          Get envelope that contains expanded action of element.
 ShedWidget getSlotWidget()
          Get widget representing the element.
 ShedTriggerEnvelope getTriggerEnvelope()
          Get envelope representing the trigger of element.
 void move(int absolutePosition, ShedSenseWidget widget)
          Move the widget relative to the other widgets.
 void remove(ShedSenseWidget widget)
          Remove widget from the envelope.
 
Methods inherited from class org.netbeans.api.visual.widget.Widget
addChild, addChild, addChild, addChild, addChildren, addDependency, bringToBack, bringToFront, calculateClientArea, convertLocalToScene, convertLocalToScene, convertSceneToLocal, convertSceneToLocal, createActions, equals, getAccessibleContext, getActions, getActions, getBackground, getBorder, getBounds, getChildConstraint, getChildren, getClientArea, getCursor, getCursorAt, getDependencies, getFont, getForeground, getGraphics, getLayout, getLocation, getLookup, getMaximumSize, getMinimumSize, getParentWidget, getPreferredBounds, getPreferredLocation, getPreferredSize, getResourceTable, getScene, getState, getToolTipText, hashCode, isCheckClipping, isEnabled, isHitAt, isOpaque, isPreferredBoundsSet, isRepaintRequiredForRevalidating, isValidated, isVisible, notifyAdded, notifyBackgroundChanged, notifyFontChanged, notifyForegroundChanged, notifyRemoved, notifyStateChanged, paint, paintBackground, paintBorder, paintChildren, paintWidget, removeChild, removeChildren, removeChildren, removeDependency, removeFromParent, repaint, resolveBounds, revalidate, revalidate, setAccessibleContext, setBackground, setBackgroundFromResource, setBorder, setBorder, setCheckClipping, setChildConstraint, setCursor, setEnabled, setFont, setFontFromResource, setForeground, setForegroundFromResource, setLayout, setMaximumSize, setMinimumSize, setOpaque, setPreferredBounds, setPreferredLocation, setPreferredSize, setResourceTable, setState, setToolTipText, setVisible, updateResources
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

slotWidget

protected final ShedWidget slotWidget
Widget representing the slot element, e.g. competence element. It displayes the name ect.

Constructor Detail

SlotEnvelope

public SlotEnvelope(ShedScene scene,
                    ShedWidget slotWidget,
                    ShedTriggerEnvelope triggerEnvelope,
                    ExpandedActionEnvelope expandedActionEnvelope)
Create slot envelope for some element (e.g. choice or drive).

Parameters:
scene - Scene the envelope belongs to.
slotWidget - The widget representing the element (e.g. drive or choice)
triggerEnvelope - Trigger of element.
expandedActionEnvelope - Expanded action of element.
Method Detail

getSlotWidget

public ShedWidget getSlotWidget()
Get widget representing the element. In most cases, it is simply widget with name fo element on it.


getTriggerEnvelope

public ShedTriggerEnvelope getTriggerEnvelope()
Get envelope representing the trigger of element.


getExpandedActionEnvelope

public ExpandedActionEnvelope getExpandedActionEnvelope()
Get envelope that contains expanded action of element.


add

public final void add(ShedSenseWidget widget,
                      int position)
Description copied from interface: IShedEnvelope
Add widget to the envelope at the specified position.

Specified by:
add in interface IShedEnvelope<ShedSenseWidget>
Parameters:
widget - widget to add
position - where to put widget

move

public final void move(int absolutePosition,
                       ShedSenseWidget widget)
Description copied from interface: IShedEnvelope
Move the widget relative to the other widgets.

Specified by:
move in interface IShedEnvelope<ShedSenseWidget>
widget - widget to move

remove

public final void remove(ShedSenseWidget widget)
Description copied from interface: IShedEnvelope
Remove widget from the envelope.

Specified by:
remove in interface IShedEnvelope<ShedSenseWidget>
Parameters:
widget - widget to remove from the envelope.


Copyright © 2013 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.