edu.wpi.ebob.wizards
Class AddToObjectBenchWizardPageExtension

java.lang.Object
  extended by org.eclipse.jface.dialogs.DialogPage
      extended by org.eclipse.jface.wizard.WizardPage
          extended by edu.wpi.ebob.wizards.AddToObjectBenchWizardPageExtension
All Implemented Interfaces:
org.eclipse.jface.dialogs.IDialogPage, org.eclipse.jface.dialogs.IMessageProvider, org.eclipse.jface.wizard.IWizardPage

public class AddToObjectBenchWizardPageExtension
extends org.eclipse.jface.wizard.WizardPage

Takes care of setting the constructor and the constructor arguments.


Field Summary
private  org.eclipse.jface.viewers.ComboViewer constructorViewer
           
private  org.eclipse.swt.widgets.Table table
           
private  org.eclipse.jface.viewers.TableViewer tableViewer
           
 
Fields inherited from interface org.eclipse.jface.dialogs.IMessageProvider
ERROR, INFORMATION, NONE, WARNING
 
Constructor Summary
AddToObjectBenchWizardPageExtension()
          Constructor for SampleNewWizardPage.
 
Method Summary
private  void createConstructorCombo(org.eclipse.swt.widgets.Composite parent)
           
 void createControl(org.eclipse.swt.widgets.Composite parent)
           
private  void createTable(org.eclipse.swt.widgets.Composite parent)
          Create the Table
private  void createTableViewer()
          Create the TableViewer
private  void dialogChanged()
          Ensures that both text fields are set.
private  Parameter[] getArgs(IClass[] classes)
          turns an array of classes into an array of argument pairs
 IObject[] getArguments()
           
 IConstructor getConstructor()
           
(package private)  void setInstanceClass(IClass c)
          sets the instance class (which in turn determines which constructors will be visible).
private  void updateStatus(java.lang.String message)
           
 
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, setVisible
 
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, setVisible
 

Field Detail

constructorViewer

private org.eclipse.jface.viewers.ComboViewer constructorViewer

table

private org.eclipse.swt.widgets.Table table

tableViewer

private org.eclipse.jface.viewers.TableViewer tableViewer
Constructor Detail

AddToObjectBenchWizardPageExtension

public AddToObjectBenchWizardPageExtension()
Constructor for SampleNewWizardPage.

Method Detail

createConstructorCombo

private void createConstructorCombo(org.eclipse.swt.widgets.Composite parent)
Parameters:
parent -

createControl

public void createControl(org.eclipse.swt.widgets.Composite parent)
See Also:
IDialogPage.createControl(Composite)

createTable

private void createTable(org.eclipse.swt.widgets.Composite parent)
Create the Table


createTableViewer

private void createTableViewer()
Create the TableViewer


dialogChanged

private void dialogChanged()
Ensures that both text fields are set.


getArgs

private Parameter[] getArgs(IClass[] classes)
turns an array of classes into an array of argument pairs

Parameters:
classes - the parameter types of a constructor
Returns:
the given argument pairs for these classes
See Also:
Parameter

getArguments

public IObject[] getArguments()
                       throws ParserException,
                              java.lang.ClassCastException
Throws:
ParserException
java.lang.ClassCastException

getConstructor

public IConstructor getConstructor()

setInstanceClass

void setInstanceClass(IClass c)
sets the instance class (which in turn determines which constructors will be visible). Called by the wizard when this page becomes visible.

Parameters:
c -

updateStatus

private void updateStatus(java.lang.String message)