Class ExpressionsViewer

  • All Implemented Interfaces:

    public class ExpressionsViewer
    extends org.eclipse.swt.widgets.Composite
    implements org.eclipse.core.runtime.IAdaptable
    DCS expressions viewer
    • Field Summary

      • Fields inherited from class org.eclipse.swt.widgets.Control

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      Object getAdapter​(Class adapter)  
      List<TypeItem> getExpressionTypes()
      Gets returning expression TypeItems getSize()  
      String getValue()
      Get changed text
      void insertText​(String text, boolean replaceStart)
      Insert text (template)
      void setCursorPosition​(int offset)
      Set cursor position
      void setValue​(String value)
      Set text
      List<org.eclipse.xtext.validation.Issue> validate()
      Validate text
      • Methods inherited from class org.eclipse.swt.widgets.Composite

        changed, checkSubclass, drawBackground, getBackgroundMode, getChildren, getLayout, getLayoutDeferred, getTabList, isLayoutDeferred, layout, layout, layout, layout, layout, setBackgroundMode, setFocus, setLayout, setLayoutDeferred, setTabList
      • Methods inherited from class org.eclipse.swt.widgets.Scrollable

        computeTrim, getClientArea, getHorizontalBar, getScrollbarsMode, getVerticalBar
      • Methods inherited from class org.eclipse.swt.widgets.Control

        addControlListener, addDragDetectListener, addFocusListener, addGestureListener, addHelpListener, addKeyListener, addMenuDetectListener, addMouseListener, addMouseMoveListener, addMouseTrackListener, addMouseWheelListener, addPaintListener, addTouchListener, addTraverseListener, computeSize, computeSize, dragDetect, dragDetect, forceFocus, getAccessible, getBackground, getBackgroundImage, getBorderWidth, getBounds, getCursor, getDragDetect, getEnabled, getFont, getForeground, getLayoutData, getLocation, getMenu, getMonitor, getOrientation, getParent, getRegion, getShell, getTextDirection, getToolTipText, getTouchEnabled, getVisible, internal_dispose_GC, internal_new_GC, isEnabled, isFocusControl, isReparentable, isVisible, moveAbove, moveBelow, pack, pack, print, redraw, redraw, removeControlListener, removeDragDetectListener, removeFocusListener, removeGestureListener, removeHelpListener, removeKeyListener, removeMenuDetectListener, removeMouseListener, removeMouseMoveListener, removeMouseTrackListener, removeMouseWheelListener, removePaintListener, removeTouchListener, removeTraverseListener, requestLayout, setBackground, setBackgroundImage, setBounds, setBounds, setCapture, setCursor, setDragDetect, setEnabled, setFont, setForeground, setLayoutData, setLocation, setLocation, setMenu, setOrientation, setParent, setRedraw, setRegion, setSize, setSize, setTextDirection, setToolTipText, setTouchEnabled, setVisible, toControl, toControl, toDisplay, toDisplay, traverse, traverse, traverse, update
      • Methods inherited from class org.eclipse.swt.widgets.Widget

        addDisposeListener, addListener, checkWidget, dispose, getData, getData, getDisplay, getListeners, getStyle, isAutoDirection, isDisposed, isListening, notifyListeners, removeDisposeListener, removeListener, removeListener, reskin, setData, setData, toString
      • Methods inherited from interface

    • Constructor Detail

      • ExpressionsViewer

        public ExpressionsViewer​(org.eclipse.swt.widgets.Composite parent,
                                 int style,
                                 org.eclipse.core.resources.IProject project,
                                 DataCompositionSchema schema,
                                 DcsAvailableSettingsSourceForSchema fieldsSource,
                                 DcsAvailableSettingsSourceForSchema.FieldUse fieldUse,
                                 String nestedSchemaName,
                                 String value,
                                 boolean select,
                                 boolean initFunctionsProvider)
        parent - parent composite, can't be null
        style - swt style
        project - project, can't be null
        schema - dcs schema, can't be null
        fieldsSource - available fields source, can't be null
        fieldUse - fields kind
        nestedSchemaName - nested schema name, can't be null
        value - initial text, can't be null
        select - select content
        initFunctionsProvider - initialize functions provider
    • Method Detail

      • insertText

        public void insertText​(String text,
                               boolean replaceStart)
        Insert text (template)
        text - text, can't be null
        replaceStart - find and remove ''
      • validate

        public List<org.eclipse.xtext.validation.Issue> validate()
        Validate text
        list of errors, never null
      • getExpressionTypes

        public List<TypeItem> getExpressionTypes()
        Gets returning expression TypeItems
        list of TypeItems corresponding to the viewer expression, never null
      • getValue

        public String getValue()
        Get changed text
        text from editor, never null
      • setValue

        public void setValue​(String value)
        Set text
        value - text, can be null
      • setCursorPosition

        public void setCursorPosition​(int offset)
        Set cursor position
        offset - offset
      • getAdapter

        public Object getAdapter​(Class adapter)
        Specified by:
        getAdapter in interface org.eclipse.core.runtime.IAdaptable
      • getSize

        public getSize()
        getSize in class org.eclipse.swt.widgets.Control