Package org.eclipse.team.ui

# Class PageSaveablePart

java.lang.Object
org.eclipse.team.ui.SaveablePartAdapter
org.eclipse.team.ui.PageSaveablePart

All Implemented Interfaces:
  `IContentChangeListener`, `IAdaptable`, `ISaveableWorkbenchPart`, `ISaveablePart`, `IWorkbenchPart`

Direct Known Subclasses:
  `HistoryPageSaveablePart`, `ParticipantPageSaveablePart`

@Deprecated public abstract class PageSaveablePart extends SaveablePartAdapter implements IContentChangeListener
Deprecated.
Clients should use a subclass of `CompareEditorInput` and `CompareUI.openCompareDialog(org.eclipse.compare.CompareEditorInput)`
Abstract class for hosting a page based structure input view for the purposes of feeding compare viewers.

Since:
  3.2
Restriction:
  This class is not intended to be subclassed by clients outside of the Team framework.

## Field Summary

### Fields inherited from interface org.eclipse.team.ui.ISaveableWorkbenchPart

`PROP_DIRTY`

### Fields inherited from interface org.eclipse.ui.IWorkbenchPart

`PROP_TITLE`

## Constructor Summary

Constructors
Modifier
Constructor
Description
`protected`
`PageSaveablePart(Shell shell, CompareConfiguration compareConfiguration)`
Deprecated.

## Method Summary

Modifier and Type
Method
Description
`protected abstract Control`
`createPage(Composite parent, ToolBarManager toolBarManager)`
Deprecated.
`void`
`createPartControl(Composite parent)`
Deprecated.
`void`
`doSave(IProgressMonitor monitor)`
Deprecated.
`protected ICompareInput`
`getCompareInput(ISelection selection)`
Deprecated.
`Control`
`getControl()`
Deprecated.
`protected abstract ISelectionProvider`
`getSelectionProvider()`
Deprecated.
`protected Shell`
`getShell()`
Deprecated.
`boolean`
`isDirty()`
Deprecated.
`protected void`
`prepareCompareInput(ICompareInput input)`
Deprecated.
`protected abstract void`
`prepareInput(ICompareInput input, CompareConfiguration configuration, IProgressMonitor monitor)`
Deprecated.
`protected void`
`setDirty(boolean dirty)`
Deprecated.
`protected void`
`setNavigator(ISynchronizePageConfiguration configuration)`
Deprecated.
`protected void`
`setPageDescription(String title)`
Deprecated.
`void`
`setShowContentPanes(boolean showContentPanes)`
Deprecated.

### Methods inherited from class org.eclipse.team.ui.SaveablePartAdapter

`addPropertyListener, dispose, doSaveAs, getAdapter, getSite, getTitleToolTip, isSaveAsAllowed, isSaveOnCloseNeeded, removePropertyListener, setFocus`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.eclipse.compare.IContentChangeListener

`contentChanged`

### Methods inherited from interface org.eclipse.ui.IWorkbenchPart

`getTitle, getTitleImage`

## Constructor Details

### PageSaveablePart

@Deprecated protected PageSaveablePart(Shell shell, CompareConfiguration compareConfiguration)
Deprecated.
Create a saveable part.

Parameters:
  `shell` - the shell for the part
  `compareConfiguration` - the compare configuration

## Method Details

### isDirty

@Deprecated public boolean isDirty()
Deprecated.
Description copied from interface: `ISaveablePart`
Returns whether the contents of this part have changed since the last save operation. If this value changes the part must fire a property listener event with `PROP_DIRTY`.

Note: this method is called often on a part open or part activation switch, for example by actions to determine their enabled status.

Specified by:
  `isDirty` in interface `ISaveablePart`
Returns:
  `true` if the contents have been modified and need saving, and `false` if they have not changed since the last save

### createPartControl

@Deprecated public void createPartControl(Composite parent)
Deprecated.
Description copied from interface: `IWorkbenchPart`
Creates the SWT controls for this workbench part.

Clients should not call this method (the workbench calls this method when it needs to, which may be never).

For implementors this is a multi-step process:

1. Create one or more controls within the parent.
2. Set the parent layout as needed.
3. Register any global actions with the site's `IActionBars`.
4. Register any context menus with the site.
5. Register a selection provider with the site, to make it available to the workbench's `ISelectionService` (optional).

Specified by:
  `createPartControl` in interface `IWorkbenchPart`
Parameters:
  `parent` - the parent control

### getSelectionProvider

@Deprecated protected abstract ISelectionProvider getSelectionProvider()
Deprecated.
Return the selection provider for the page. This method is called after the page is created in order to register a selection listener on the page.

Returns:
  the selection provider for the page

### createPage

@Deprecated protected abstract Control createPage(Composite parent, ToolBarManager toolBarManager)
Deprecated.
Create the page for this part and return the top level control for the page.

Parameters:
  `parent` - the parent composite
  `toolBarManager` - the toolbar manager for the page
Returns:
  the top-level control for the page

### setPageDescription

@Deprecated protected void setPageDescription(String title)
Deprecated.
Set the title of the page's page to the given text. The title will appear in the header of the pane containing the page.

Parameters:
  `title` - the page's title

### setDirty

@Deprecated protected void setDirty(boolean dirty)
Deprecated.
Set the saveable part's dirty state to the given state.

Parameters:
  `dirty` - the dirty state

### prepareCompareInput

@Deprecated protected void prepareCompareInput(ICompareInput input)
Deprecated.
Convenience method that calls `prepareInput(ICompareInput, CompareConfiguration, IProgressMonitor)` with a progress monitor.

Parameters:
  `input` - the compare input to be prepared

### prepareInput

@Deprecated protected abstract void prepareInput(ICompareInput input, CompareConfiguration configuration, IProgressMonitor monitor) throws InvocationTargetException
Deprecated.
Prepare the compare input for display in a content viewer. This method is called from `prepareCompareInput(ICompareInput)` and may be called from a non-UI thread. This method should not be called by others.

Parameters:
  `input` - the input
  `configuration` - the compare configuration
  `monitor` - a progress monitor
Throws:
  `InvocationTargetException` - if an error occurs

### getShell

@Deprecated protected Shell getShell()
Deprecated.
Return the parent shell of this part.

Returns:
  the parent shell of this part

### setNavigator

@Deprecated protected void setNavigator(ISynchronizePageConfiguration configuration)
Deprecated.
This method is internal to the framework and should not be called by clients outside of the framework.

### getCompareInput

@Deprecated protected ICompareInput getCompareInput(ISelection selection)
Deprecated.
Return a compare input that represents the selection. This input is used to feed the structure and content viewers. By default, a compare input is returned if the selection is of size 1 and the selected element implements `ICompareInput`. Subclasses may override.

Parameters:
  `selection` - the selection
Returns:
  a compare input representing the selection

### setShowContentPanes

@Deprecated public void setShowContentPanes(boolean showContentPanes)
Deprecated.
Set whether the file contents panes should be shown. If they are not, only the page will be shown.

Parameters:
  `showContentPanes` - whether to show contents pane

### getControl

@Deprecated public Control getControl()
Deprecated.
Returns the primary control for this part.

Returns:
  the primary control for this part.

### doSave

@Deprecated public void doSave(IProgressMonitor monitor)
Deprecated.
This method flushes the content in any viewers. Subclasses should override if they need to perform additional processing when a save is performed.

Specified by:
  `doSave` in interface `ISaveablePart`
Parameters:
  `monitor` - a progress monitor