Class AbstractQueryWizardEditProvider

    • Constructor Detail

      • AbstractQueryWizardEditProvider

        public AbstractQueryWizardEditProvider​(QueryWizardSource source)
        Parameters:
        source - - query wizard source
    • Method Detail

      • isIndexValid

        public static boolean isIndexValid​(int index,
                                           int count)
        Check index (index >=0 and index < count)
        Parameters:
        index - - index
        count - - count of elements
        Returns:
        true if index >=0 and < count
      • getSource

        public QueryWizardSource getSource()
        Get query wizard source
        Returns:
        query wizard source
      • remove

        public boolean remove​(int index)
        Remove item at index
        Parameters:
        index - - index of item
        Returns:
        true if successfully else false
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • remove

        public boolean remove​(Object value)
        Remove item
        Parameters:
        value - - value which need to be removed
        Returns:
        true if successfully else false
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • set

        public boolean set​(int index,
                           Object value)
        Set value at index
        Parameters:
        index - - index of item
        value - - new value
        Returns:
        true if successfully else false
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • replace

        public boolean replace​(Object oldValue,
                               Object newValue)
        Replace value
        Parameters:
        oldValue -
        newValue -
        Returns:
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • move

        public boolean move​(Object value,
                            Object targetValue)
        Move item
        Parameters:
        value - - value need to be moved
        targetValue - - target value
        Returns:
        true if successfully else false
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • moveUp

        public boolean moveUp​(Object value)
        Move item up
        Parameters:
        value - - value need to be moved
        Returns:
        true if successfully else false
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • moveDown

        public boolean moveDown​(Object value)
        Move item down
        Parameters:
        value - - value need to be moved
        Returns:
        true if successfully else false
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • indexOf

        public int indexOf​(Object value)
        Looking index of value
        Parameters:
        value - - value
        Returns:
        index of value. Return -1 if value not found
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • copy

        public Object copy​(int index)
        Copy value at index
        Parameters:
        index - - index of value
        Returns:
        new copied value
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • setItemData

        public boolean setItemData​(int itemFuture,
                                   Object item,
                                   Object newValue)
        Parameters:
        itemFuture - which item future change
        item - item at which data need to changed
        newValue - new future value
        Returns:
        true if future was changed
        Throws:
        UnsupportedOperationException - if not supported by implementation
      • move

        protected boolean move​(org.eclipse.emf.common.util.EList<? extends org.eclipse.emf.ecore.EObject> collection,
                               Object value,
                               int inc)
        Move item
        Parameters:
        collection - - values collection
        value - - value need to be moved
        inc - - how many positions to shift element
        Returns:
        true if value successfully moved else false
      • clearRemoveNodesAdapter

        protected void clearRemoveNodesAdapter​(org.eclipse.emf.ecore.EObject eObject)
        Remove INode adapter for eObject and all it parent eObjects
        Parameters:
        eObject - EObject for deleting INode adapters, cannit be null