org.colos.ejs.library.control.drawing3d.utils
Class ControlTransformation3D

java.lang.Object
  extended by org.colos.ejs.library.control.ControlElement
      extended by org.colos.ejs.library.control.drawing3d.utils.ControlTransformation3D
All Implemented Interfaces:
java.lang.Cloneable, TransformationWrapper
Direct Known Subclasses:
ControlAlignment3DTransformation, ControlMatrix3DTransformation, ControlQuaternionTransformation, ControlRotation3DTransformation

public abstract class ControlTransformation3D
extends ControlElement
implements TransformationWrapper

Superclass for 3D transformations of elements (children of ControlElements3D)


Field Summary
static int TR3D_ENABLED
           
static int TR3D_NAME
           
static int TR3D_PARENT
           
 
Fields inherited from class org.colos.ejs.library.control.ControlElement
ACTION, ACTION_ERROR, ACTION_SUCCESS, METHOD_FOR_VARIABLE, METHOD_TRIGGER, NAME, VARIABLE_CHANGED
 
Method Summary
abstract  java.lang.Object clone()
          Provides a copy of this optional transformation.
 java.lang.String getDefaultValueString(int _index)
           
 java.lang.Object getObject()
          Returns the basic object that the ControlElement wrapps.
 java.lang.String getObjectClassname()
          Returns the expected class of the object that the ControlElement wrapps.
 ControlElement3D getParent()
           
 java.lang.String getPropertyInfo(java.lang.String _property)
          Returns information about a given property.
 java.util.List<java.lang.String> getPropertyList()
          Returns the list of all properties that can be set for this ControlElement.
 Transformation getTransformation()
          An optional transformation may actually be the wrap of a Transformation object.
 Value getValue(int _index)
          Gets the value of any internal variable.
 boolean isEnabled()
          Whether the transformation is enabled
 void setDefaultValue(int _index)
           
 void setEnabled(boolean _enabled)
          Enables/Disables the transformation
 void setParent(ControlElement3D _dp)
           
 void setValue(int _index, Value _value)
          Sets the value of the registered variables.
 
Methods inherited from class org.colos.ejs.library.control.ControlElement
acceptsChild, addAction, addAction, addAction, addMenuEntries, destroy, editorIsReading, flush, getComponent, getGroup, getObject, getProperty, getPropertyCommonName, getSimulation, getValue, getVisual, implementsProperty, indexOf, initialize, invokeActions, invokeActions, isActive, onExit, parseConstant, propertyIndex, propertyIsTypeOf, propertyType, removeAction, removeAction, replaceVisual, reset, setActive, setFieldListValue, setFieldListValues, setGroup, setProperties, setProperty, 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
 

Field Detail

TR3D_NAME

public static final int TR3D_NAME
See Also:
Constant Field Values

TR3D_PARENT

public static final int TR3D_PARENT
See Also:
Constant Field Values

TR3D_ENABLED

public static final int TR3D_ENABLED
See Also:
Constant Field Values
Method Detail

getObject

public java.lang.Object getObject()
Description copied from class: ControlElement
Returns the basic object that the ControlElement wrapps. Usually a graphic component

Overrides:
getObject in class ControlElement
Returns:
Object

getObjectClassname

public java.lang.String getObjectClassname()
Description copied from class: ControlElement
Returns the expected class of the object that the ControlElement wrapps. Not final because of special needs (see display3d.DrawingPanel3D, f.i.)

Overrides:
getObjectClassname in class ControlElement
Returns:
Object

setParent

public final void setParent(ControlElement3D _dp)

getParent

public final ControlElement3D getParent()

getPropertyList

public java.util.List<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.

Specified by:
getPropertyList in class ControlElement

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

    Specified by:
    getPropertyInfo in class ControlElement

  • 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 ControlElement

    setDefaultValue

    public void setDefaultValue(int _index)
    Overrides:
    setDefaultValue in class ControlElement

    getDefaultValueString

    public java.lang.String getDefaultValueString(int _index)
    Overrides:
    getDefaultValueString in class ControlElement

    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 ControlElement
    Returns:
    Value _value The object holding the value for the variable.

    isEnabled

    public final boolean isEnabled()
    Description copied from interface: TransformationWrapper
    Whether the transformation is enabled

    Specified by:
    isEnabled in interface TransformationWrapper
    Returns:
    boolean

    setEnabled

    public final void setEnabled(boolean _enabled)
    Description copied from interface: TransformationWrapper
    Enables/Disables the transformation

    Specified by:
    setEnabled in interface TransformationWrapper

    getTransformation

    public final Transformation getTransformation()
    Description copied from interface: TransformationWrapper
    An optional transformation may actually be the wrap of a Transformation object. Some users may ask for this wrapped transformation

    Specified by:
    getTransformation in interface TransformationWrapper
    Returns:
    the wrapped transformation or 'this' if it is not a wrap

    clone

    public abstract java.lang.Object clone()
    Description copied from interface: TransformationWrapper
    Provides a copy of this optional transformation. This is used by an OSP 3D Element that will explicitely get a clone of it.

    Specified by:
    clone in interface TransformationWrapper
    Overrides:
    clone in class java.lang.Object