Class WizardExportPage

  • All Implemented Interfaces:
    IDialogPage, IMessageProvider, IWizardPage, Listener, IOverwriteQuery

    @Deprecated
    public abstract class WizardExportPage
    extends WizardDataTransferPage
    Deprecated.
    use WizardExportResourcePage
    Abstract superclass for a typical export wizard's main page.

    Clients may subclass this page to inherit its common destination resource selection facilities.

    Subclasses must implement

    • createDestinationGroup

    Subclasses may override

    • allowNewContainerName

    Subclasses may extend

    • handleEvent
    • internalSaveWidgetValues
    • updateWidgetEnablements
    Restriction:
    This class is not intended to be subclassed by clients. Planned to be removed, see https://bugs.eclipse.org/bugs/show_bug.cgi?id=448275
    Restriction:
    This class is not intended to be referenced by clients.
    • Constructor Detail

      • WizardExportPage

        protected WizardExportPage​(String pageName,
                                   IStructuredSelection selection)
        Deprecated.
        Creates an export wizard page. If the current resource selection is not empty then it will be used as the initial collection of resources selected for export.
        Parameters:
        pageName - the name of the page
        selection - the current resource selection
    • Method Detail

      • allowNewContainerName

        protected boolean allowNewContainerName()
        Deprecated.
        The WizardExportPage implementation of this WizardDataTransferPage method returns false. Subclasses may override this method.
        Specified by:
        allowNewContainerName in class WizardDataTransferPage
        Returns:
        true if new ones are okay, and false if only existing ones are allowed
      • createControl

        public void createControl​(Composite parent)
        Deprecated.
        Description copied from interface: IDialogPage
        Creates the top level control for this dialog page under the given parent composite.

        Implementors are responsible for ensuring that the created control can be accessed via getControl

        Parameters:
        parent - the parent composite
      • createDestinationGroup

        protected abstract void createDestinationGroup​(Composite parent)
        Deprecated.
        Creates the export destination specification visual components.

        Subclasses must implement this method.

        Parameters:
        parent - the parent control
      • createSourceGroup

        protected final void createSourceGroup​(Composite parent)
        Deprecated.
        Creates the export source resource specification controls.
        Parameters:
        parent - the parent control
      • displayErrorDialog

        protected void displayErrorDialog​(String message)
        Deprecated.
        Display an error dialog with the specified message.
        Overrides:
        displayErrorDialog in class WizardDataTransferPage
        Parameters:
        message - the error message
      • displayResourcesSelectedCount

        protected void displayResourcesSelectedCount​(int selectedResourceCount)
        Deprecated.
        Displays a description message that indicates a selection of resources of the specified size.
        Parameters:
        selectedResourceCount - the resource selection size to display
      • ensureResourcesLocal

        @Deprecated
        protected boolean ensureResourcesLocal​(List resources)
        Deprecated.
        Only retained for backwards compatibility.
        Obsolete method. This was implemented to handle the case where ensureLocal() needed to be called but it doesn't use it any longer.
        Parameters:
        resources - the list of resources to ensure locality for
        Returns:
        true for successful completion
      • extractNonLocalResources

        protected List extractNonLocalResources​(List originalList)
        Deprecated.
        Returns a new subcollection containing only those resources which are not local.
        Parameters:
        originalList - the original list of resources (element type: IResource)
        Returns:
        the new list of non-local resources (element type: IResource)
      • getExportAllTypesValue

        public boolean getExportAllTypesValue()
        Deprecated.
        Returns the current selection value of the "Export all types" radio, or its set initial value if it does not exist yet.
        Returns:
        the "Export All Types" radio's current value or anticipated initial value
      • getResourceFieldValue

        public String getResourceFieldValue()
        Deprecated.
        Returns the current contents of the resource name entry field, or its set initial value if it does not exist yet (which could be null).
        Returns:
        the resource name field's current value or anticipated initial value, or null
      • getResourcePath

        protected IPath getResourcePath()
        Deprecated.
        Return the path for the resource field.
        Returns:
        org.eclipse.core.runtime.IPath
      • getSelectedResources

        protected List getSelectedResources()
        Deprecated.
        Returns this page's collection of currently-specified resources to be exported. This is the primary resource selection facility accessor for subclasses.
        Returns:
        the collection of resources currently selected for export (element type: IResource)
      • getSourceResource

        protected IResource getSourceResource()
        Deprecated.
        Returns the resource object specified in the resource name entry field, or null if such a resource does not exist in the workbench.
        Returns:
        the resource specified in the resource name entry field, or null
      • getTypesFieldValue

        public String getTypesFieldValue()
        Deprecated.
        Returns the current contents of the types entry field, or its set initial value if it does not exist yet (which could be null).
        Returns:
        the types entry field's current value or anticipated initial value, or null
      • getTypesToExport

        protected List getTypesToExport()
        Deprecated.
        Returns the resource extensions currently specified to be exported.
        Returns:
        the resource extensions currently specified to be exported (element type: String)
      • handleEvent

        public void handleEvent​(Event event)
        Deprecated.
        The WizardExportPage implementation of this Listener method handles all events and enablements for controls on this page. Subclasses may extend.
        Parameters:
        event - the event which occurred
      • handleResourceBrowseButtonPressed

        protected void handleResourceBrowseButtonPressed()
        Deprecated.
        Opens a container selection dialog and displays the user's subsequent container selection in this page's resource name field.
      • handleResourceDetailsButtonPressed

        protected void handleResourceDetailsButtonPressed()
        Deprecated.
        Opens a resource selection dialog and records the user's subsequent resource selections.
      • handleTypesEditButtonPressed

        protected void handleTypesEditButtonPressed()
        Deprecated.
        Queries the user for the types of resources to be exported and displays these types in this page's "Types to export" field.
      • hasExportableExtension

        protected boolean hasExportableExtension​(String resourceName)
        Deprecated.
        Returns whether the extension of the given resource name is an extension that has been specified for export by the user.
        Parameters:
        resourceName - the resource name
        Returns:
        true if the resource name is suitable for export based upon its extension
      • internalSaveWidgetValues

        protected void internalSaveWidgetValues()
        Deprecated.
        Persists additional setting that are to be restored in the next instance of this page.

        The WizardImportPage implementation of this method does nothing. Subclasses may extend to persist additional settings.

      • queryIndividualResourcesToExport

        protected Object[] queryIndividualResourcesToExport​(IAdaptable rootResource)
        Deprecated.
        Queries the user for the individual resources that are to be exported and returns these resources as a collection.
        Parameters:
        rootResource - the resource to use as the root of the selection query
        Returns:
        the resources selected for export (element type: IResource), or null if the user canceled the selection
      • queryResourceTypesToExport

        protected Object[] queryResourceTypesToExport()
        Deprecated.
        Queries the user for the resource types that are to be exported and returns these types as a collection.
        Returns:
        the resource types selected for export (element type: String), or null if the user canceled the selection
      • resetSelectedResources

        protected void resetSelectedResources()
        Deprecated.
        Resets this page's selected resources collection and updates its controls accordingly.
      • restoreResourceSpecificationWidgetValues

        protected void restoreResourceSpecificationWidgetValues()
        Deprecated.
        Restores resource specification control settings that were persisted in the previous instance of this page. Subclasses wishing to restore persisted values for their controls may extend.
      • saveWidgetValues

        protected void saveWidgetValues()
        Deprecated.
        Persists resource specification control setting that are to be restored in the next instance of this page. Subclasses wishing to persist additional setting for their controls should extend hook method internalSaveWidgetValues.
        Overrides:
        saveWidgetValues in class WizardDataTransferPage
      • selectAppropriateFolderContents

        protected void selectAppropriateFolderContents​(IContainer resource)
        Deprecated.
        Records a container's recursive file descendents which have an extension that has been specified for export by the user.
        Parameters:
        resource - the parent container
      • selectAppropriateResources

        protected void selectAppropriateResources​(Object resource)
        Deprecated.
        Records a resource's recursive descendents which are appropriate for export based upon this page's current controls contents.
        Parameters:
        resource - the parent resource
      • setExportAllTypesValue

        public void setExportAllTypesValue​(boolean value)
        Deprecated.
        Sets the selection value of this page's "Export all types" radio, or stores it for future use if this visual component does not exist yet.
        Parameters:
        value - new selection value
      • setResourceFieldValue

        public void setResourceFieldValue​(String value)
        Deprecated.
        Sets the value of this page's source resource field, or stores it for future use if this visual component does not exist yet.
        Parameters:
        value - new value
      • setResourceToDisplay

        protected void setResourceToDisplay​(IResource resource)
        Deprecated.
        Set the resource whos name we will display.
        Parameters:
        resource - the resource to display
      • setTypesFieldValue

        public void setTypesFieldValue​(String value)
        Deprecated.
        Sets the value of this page's "Types to export" field, or stores it for future use if this visual component does not exist yet.
        Parameters:
        value - new value
      • setTypesToExport

        protected void setTypesToExport​(List typeStrings)
        Deprecated.
        Sets the value of this page's "Types to export" field based upon the collection of extensions.
        Parameters:
        typeStrings - the collection of extensions to populate the "Types to export" field with (element type: String)
      • setupBasedOnInitialSelections

        protected void setupBasedOnInitialSelections()
        Deprecated.
        Populates the resource name field based upon the currently selected resources.
      • validateSourceGroup

        protected final boolean validateSourceGroup()
        Deprecated.
        Description copied from class: WizardDataTransferPage
        Returns whether this page's source specification controls currently all contain valid values.

        The WizardDataTransferPage implementation of this method returns true. Subclasses may reimplement this hook method.

        Overrides:
        validateSourceGroup in class WizardDataTransferPage
        Returns:
        true indicating validity of all controls in the source specification group