org.mockcentral.editor.new_wizard
Class NewMockCentralFileWizardPage
java.lang.Object
org.eclipse.jface.dialogs.DialogPage
org.eclipse.jface.wizard.WizardPage
org.eclipse.ui.dialogs.WizardNewFileCreationPage
org.mockcentral.editor.new_wizard.NewMockCentralFileWizardPage
- All Implemented Interfaces:
- org.eclipse.jface.dialogs.IDialogPage, org.eclipse.jface.dialogs.IMessageProvider, org.eclipse.jface.wizard.IWizardPage, org.eclipse.swt.widgets.Listener
public class NewMockCentralFileWizardPage
- extends org.eclipse.ui.dialogs.WizardNewFileCreationPage
A WizardNewFileCreationPage for entering the parent directory
and file name for a new MockCentral configuration file.
- Author:
- David Hutchinson
| Fields inherited from interface org.eclipse.jface.dialogs.IMessageProvider |
ERROR, INFORMATION, NONE, WARNING |
| Methods inherited from class org.eclipse.ui.dialogs.WizardNewFileCreationPage |
createAdvancedControls, createFile, createFileHandle, createLinkTarget, createNewFile, createRule, getContainerFullPath, getFileName, handleAdvancedButtonSelect, handleEvent, initialPopulateContainerNameField, setContainerFullPath, setFileName, validateLinkedResource |
| Methods inherited from class org.eclipse.jface.wizard.WizardPage |
canFlipToNextPage, getContainer, getDialogSettings, getImage, getName, getNextPage, getPreviousPage, getShell, getWizard, isCurrentPage, isPageComplete, setDescription, setErrorMessage, setImageDescriptor, setMessage, setPageComplete, setPreviousPage, setTitle, setWizard, toString |
| Methods inherited from class org.eclipse.jface.dialogs.DialogPage |
convertHeightInCharsToPixels, convertHorizontalDLUsToPixels, convertVerticalDLUsToPixels, convertWidthInCharsToPixels, dispose, getControl, getDescription, getDialogFontName, getErrorMessage, getFont, getMessage, getMessageType, getTitle, getToolTipText, initializeDialogUnits, isControlCreated, performHelp, setButtonLayoutData, setControl, setMessage |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.eclipse.jface.dialogs.IDialogPage |
dispose, getControl, getDescription, getErrorMessage, getMessage, getTitle, performHelp |
NewMockCentralFileWizardPage
public NewMockCentralFileWizardPage(org.eclipse.ui.IWorkbench workbench,
org.eclipse.jface.viewers.IStructuredSelection selection,
NewMockCentralFileWizard wizard,
boolean isEnclosingJavaProject)
- Creates a new instance.
- Parameters:
workbench - the IWorkbench.selection - the IStructuredSelection containing the
initially selected IResource designating the parent folder
for the new file.wizard - the NewMockCentralFileWizard.isEnclosingJavaProject - flag for whether the enclosing
IProject is an IJavaProject.
setVisible
public void setVisible(boolean visible)
- Specified by:
setVisible in interface org.eclipse.jface.dialogs.IDialogPage- Overrides:
setVisible in class org.eclipse.ui.dialogs.WizardNewFileCreationPage
createControl
public void createControl(org.eclipse.swt.widgets.Composite parent)
- Specified by:
createControl in interface org.eclipse.jface.dialogs.IDialogPage- Overrides:
createControl in class org.eclipse.ui.dialogs.WizardNewFileCreationPage
finish
public boolean finish()
- Creates a new file resource as requested by the user. If the checkbox
indicating whether to open the new file was checked, opens the file in an
editor.
- Returns:
- whether creation was successful. The wizard will remain open
until cancelled if there was a problem (bad file name or no enclosing
IJavaProject).
getInitialContents
protected java.io.InputStream getInitialContents()
- Overrides:
getInitialContents in class org.eclipse.ui.dialogs.WizardNewFileCreationPage
validatePage
protected boolean validatePage()
- Overrides:
validatePage in class org.eclipse.ui.dialogs.WizardNewFileCreationPage
getNewFileLabel
protected java.lang.String getNewFileLabel()
- Overrides:
getNewFileLabel in class org.eclipse.ui.dialogs.WizardNewFileCreationPage