Eclipse Platform
2.0

org.eclipse.ui.dialogs
Class WizardNewProjectCreationPage

java.lang.Object
  |
  +--org.eclipse.jface.dialogs.DialogPage
        |
        +--org.eclipse.jface.wizard.WizardPage
              |
              +--org.eclipse.ui.dialogs.WizardNewProjectCreationPage
All Implemented Interfaces:
IDialogPage, IMessageProvider, IWizardPage

public class WizardNewProjectCreationPage
extends WizardPage

Standard main page for a wizard that is creates a project resource.

This page may be used by clients as-is; it may be also be subclassed to suit.

Example useage:

 mainPage = new WizardNewProjectCreationPage("basicNewProjectPage");
 mainPage.setTitle("Project");
 mainPage.setDescription("Create a new project resource.");
 


Field Summary
 
Fields inherited from interface org.eclipse.jface.dialogs.IMessageProvider
ERROR, INFORMATION, NONE, WARNING
 
Constructor Summary
WizardNewProjectCreationPage(String pageName)
          Creates a new project creation wizard page.
 
Method Summary
 void createControl(Composite parent)
          (non-Javadoc) Method declared on IDialogPage.
 IPath getLocationPath()
          Returns the current project location path as entered by the user, or its anticipated initial value.
 IProject getProjectHandle()
          Creates a project resource handle for the current project name field value.
 String getProjectName()
          Returns the current project name as entered by the user, or its anticipated initial value.
 void setInitialProjectName(String name)
          Sets the initial project name that this page will use when created.
 void setVisible(boolean visible)
          Sets the visibility of this dialog page.
 
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, 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
 

Constructor Detail

WizardNewProjectCreationPage

public WizardNewProjectCreationPage(String pageName)
Creates a new project creation wizard page.

Parameters:
pageName - the name of this page
Method Detail

createControl

public void createControl(Composite parent)
(non-Javadoc) Method declared on IDialogPage.

Parameters:
parent - the parent composite

getLocationPath

public IPath getLocationPath()
Returns the current project location path as entered by the user, or its anticipated initial value. Note that if the default has been returned the path in a project description used to create a project should not be set.

Returns:
the project location path, its anticipated initial value, or null if no project location path is known

getProjectHandle

public IProject getProjectHandle()
Creates a project resource handle for the current project name field value.

This method does not create the project resource; this is the responsibility of IProject::create invoked by the new project resource wizard.

Returns:
the new project resource handle

getProjectName

public String getProjectName()
Returns the current project name as entered by the user, or its anticipated initial value.

Returns:
the project name, its anticipated initial value, or null if no project name is known

setInitialProjectName

public void setInitialProjectName(String name)
Sets the initial project name that this page will use when created. The name is ignored if the createControl(Composite) method has already been called. Leading and trailing spaces in the name are ignored.

Parameters:
name - initial project name for this page

setVisible

public void setVisible(boolean visible)
Description copied from interface: IDialogPage
Sets the visibility of this dialog page.

Specified by:
setVisible in interface IDialogPage
Overrides:
setVisible in class DialogPage
Parameters:
visible - true to make this page visible, and false to hide it

Eclipse Platform
2.0

Copyright (c) IBM Corp. and others 2000, 2002. All Rights Reserved.