Class ContainerTextGUIEditor

  • All Implemented Interfaces:
    GUIEditor

    public class ContainerTextGUIEditor
    extends java.lang.Object
    implements GUIEditor
    Class that implements the GUIEditor. Container for handling a text and its GUI.
    Author:
    Dennis Konoppa
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private IGUITextHandler handler  
      private org.eclipse.swt.widgets.Text text  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      org.eclipse.swt.widgets.Control getControl()
      Returns the actual SWT control of the editor.
      java.lang.Object getValue()
      Returns the value of the editor.
      boolean isPseudoEditor()
      Returns whether this representation actually holds an editable SWT element or whether it is a pseudo editor such as a Label.
      void refreshContents()
      Refreshes the contents of this editor.
      void setValue​(java.lang.Object object)
      Changes the value of the editor.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • text

        private org.eclipse.swt.widgets.Text text
    • Constructor Detail

      • ContainerTextGUIEditor

        ContainerTextGUIEditor​(org.eclipse.swt.widgets.Text text)
        Creates an editor representation.
        Parameters:
        text - the text
      • ContainerTextGUIEditor

        public ContainerTextGUIEditor​(org.eclipse.swt.widgets.Text text,
                                      IGUITextHandler handler)
        Constructor for ContainerTextGUIEditor. Sets Text and IGUITextHandler.
        Parameters:
        text - the text
        handler - handler for the text
    • Method Detail

      • getControl

        public org.eclipse.swt.widgets.Control getControl()
        Description copied from interface: GUIEditor
        Returns the actual SWT control of the editor.
        Specified by:
        getControl in interface GUIEditor
        Returns:
        the control
      • getValue

        public java.lang.Object getValue()
        Description copied from interface: GUIEditor
        Returns the value of the editor.
        Specified by:
        getValue in interface GUIEditor
        Returns:
        the value
      • setValue

        public void setValue​(java.lang.Object object)
        Description copied from interface: GUIEditor
        Changes the value of the editor.
        Specified by:
        setValue in interface GUIEditor
        Parameters:
        object - the new value
      • isPseudoEditor

        public boolean isPseudoEditor()
        Description copied from interface: GUIEditor
        Returns whether this representation actually holds an editable SWT element or whether it is a pseudo editor such as a Label.
        Specified by:
        isPseudoEditor in interface GUIEditor
        Returns:
        true if it is a pseudo editor, false else
      • refreshContents

        public void refreshContents()
        Description copied from interface: GUIEditor
        Refreshes the contents of this editor.
        Specified by:
        refreshContents in interface GUIEditor