org.colos.ejs.library.control.drawing2d
Class ControlPolygonSet2D
java.lang.Object
org.colos.ejs.library.control.ControlElement
org.colos.ejs.library.control.swing.ControlDrawable
org.colos.ejs.library.control.drawing2d.ControlElement2D
org.colos.ejs.library.control.drawing2d.ControlSet2D
org.colos.ejs.library.control.drawing2d.ControlPolygonSet2D
- All Implemented Interfaces:
- NeedsPreUpdate, InteractionListener
public class ControlPolygonSet2D
- extends ControlSet2D
- implements NeedsPreUpdate
A set of arrows
Methods inherited from class org.colos.ejs.library.control.ControlElement |
acceptsChild, addAction, addAction, addAction, editorIsReading, flush, getComponent, getGroup, getObject, getProperty, getSimulation, getValue, getVisual, implementsProperty, indexOf, invokeActions, invokeActions, isActive, onExit, propertyIndex, propertyIsTypeOf, propertyType, removeAction, removeAction, replaceVisual, setActive, setFieldListValue, setFieldListValues, setGroup, setProperties, setProperty, setPropertyEditor, setVariableEditor, toString, toStringValue, variableChanged, variableChangedDoNotUpdate, variableExtraChanged, variablePropertiesClear, variablesChanged |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
ControlPolygonSet2D
public ControlPolygonSet2D()
addMenuEntries
public void addMenuEntries()
- Description copied from class:
ControlElement
- This is a place holder for elements to add menu entries to a simulation
- Overrides:
addMenuEntries
in class ControlSet2D
preupdate
public void preupdate()
- Specified by:
preupdate
in interface NeedsPreUpdate
getPropertyList
public java.util.ArrayList<java.lang.String> getPropertyList()
- Description copied from class:
ControlElement
- Returns the list of all properties that can be set for this
ControlElement.
Subclasses that add properties should implement this.
Order is crucial here: Both for the presentation in an editor
(f.i. ViewElement) and for the setValue() method.
- Overrides:
getPropertyList
in class ControlSet2D
getPropertyInfo
public java.lang.String getPropertyInfo(java.lang.String _property)
- Description copied from class:
ControlElement
- Returns information about a given property.
Subclasses that add properties should implement this.
Order in the implementation is irrelevant.
- The first keyword is ALWAYS the type. If more than one type is
accepted, they are separated by | (do NOT use spaces!)
- The keyword CONSTANT applies to properties that can not be
changed using the setValue() methods
- The keyword VARIABLE_EXPECTED is used when a String could be
accepted, but a variable has priority. In this case, a String requires
using inverted commas or quotes
- The keyword NotTrimmed specifies that leading or trailing
spaces must be respected when present. This is useful for labels or
titles, for instance
- The keywords PREVIOUS and POSTPROCESS indicate that,
when setting several properties at once (using setProperties()) the
property must be process before, resp. after, the others
- Overrides:
getPropertyInfo
in class ControlSet2D
setValue
public void setValue(int _index,
Value _value)
- Description copied from class:
ControlElement
- Sets the value of the registered variables.
Subclasses with internal values should extend this
Order is crucial here: it must match exactly that of the getPropertyList()
method.
- Overrides:
setValue
in class ControlSet2D
setDefaultValue
public void setDefaultValue(int _index)
- Overrides:
setDefaultValue
in class ControlSet2D
getDefaultValueString
public java.lang.String getDefaultValueString(int _index)
- Overrides:
getDefaultValueString
in class ControlSet2D
getValue
public Value getValue(int _index)
- Description copied from class:
ControlElement
- Gets the value of any internal variable.
Subclasses with internal values should extend this
- Overrides:
getValue
in class ControlSet2D
- Returns:
- Value _value The object holding the value for the variable.
interactionPerformed
public void interactionPerformed(InteractionEvent _event)
- Description copied from interface:
InteractionListener
- The method of a registered listener that will be called when an
interaction takes place. Classes implementing this interface
need to register to the interaction source using the
addInteractionListener
method.
- Specified by:
interactionPerformed
in interface InteractionListener
- Overrides:
interactionPerformed
in class ControlSet2D
- Parameters:
_event
- InteractionEvent