org.mockcentral.editor.nodes.expectation.part.wizard
Class InstanceFieldEditor

java.lang.Object
  extended by org.eclipse.swt.widgets.Widget
      extended by org.eclipse.swt.widgets.Control
          extended by org.eclipse.swt.widgets.Scrollable
              extended by org.eclipse.swt.widgets.Composite
                  extended by org.mockcentral.editor.nodes.expectation.part.wizard.AbstractFieldEditor
                      extended by org.mockcentral.editor.nodes.expectation.part.wizard.InstanceFieldEditor
All Implemented Interfaces:
org.eclipse.swt.graphics.Drawable

public class InstanceFieldEditor
extends AbstractFieldEditor

Factory class for editors used to set values for SignaturepartBean instances modeling a new Class, Throwable or Array instance.

Author:
David Hutchinson

Field Summary
protected  ChildrenListEditor childrenListEditor
          The ChildrenListEditor used to edit nested SignaturePartBean instances.
protected  org.eclipse.swt.widgets.Text classNameText
          The Text for displaying/editing the class name.
protected  org.mockcentral.editor.nodes.fixture.FixtureNode fixtureNode
          The current enclosing FixtureNode.
 
Fields inherited from class org.mockcentral.editor.nodes.expectation.part.wizard.AbstractFieldEditor
bean, page, valueClassNameEditor, valueClassNameOptions, valueClassNamePromptLabel, valueEditor, valueOptions, valuePromptLabel
 
Fields inherited from class org.eclipse.swt.widgets.Composite
embeddedHandle
 
Fields inherited from class org.eclipse.swt.widgets.Widget
handle
 
Constructor Summary
InstanceFieldEditor(SelectSignaturePartTypePage page, org.mockcentral.server.SignaturePartBean bean, org.eclipse.swt.widgets.Composite parent, org.mockcentral.editor.nodes.fixture.FixtureNode fixtureNode)
          Creates a new instance.
 
Method Summary
protected  void createChildrenListEditor()
          Creates the editor for the list of nested SignaturepartBean instances.
protected  void createValueClassNameEditor(java.lang.Integer... args)
          Creates the Composite used to edit the value class name of the SignaturePartBean.
protected  void createValueEditor(java.lang.Integer... args)
          Creates the Composite used to edit the value of the SignaturePartBean.
 InstanceFieldEditor getFieldEditor(org.mockcentral.server.ValueType valueType, org.mockcentral.editor.nodes.fixture.FixtureNode fixtureNode)
          Returns an editor used to set values for SignaturepartBean instances modeling a new Class, Throwable or Array object.
protected  void openFilteredTypesSelectionDialog()
          opens a SelectTypeDialog to choose the class name
 
Methods inherited from class org.mockcentral.editor.nodes.expectation.part.wizard.AbstractFieldEditor
createEditorContent, getDialog, setBean, setDefaultValue, setFocusOn, setModelFieldValue, setModelFieldValue, setNoMatchingElementErrorMessage, updateControls
 
Methods inherited from class org.eclipse.swt.widgets.Composite
changed, checkSubclass, computeSize, getChildren, getClientArea, getLayout, getLayoutDeferred, getTabList, isLayoutDeferred, layout, layout, layout, layout, setFocus, setLayout, setLayoutDeferred, setTabList
 
Methods inherited from class org.eclipse.swt.widgets.Scrollable
computeTrim, getBorderWidth, getHorizontalBar, getVerticalBar
 
Methods inherited from class org.eclipse.swt.widgets.Control
addControlListener, addFocusListener, addHelpListener, addKeyListener, addMouseListener, addMouseMoveListener, addMouseTrackListener, addPaintListener, addTraverseListener, computeSize, forceFocus, getAccessible, getBackground, getBounds, getEnabled, getFont, getForeground, getLayoutData, getLocation, getMenu, getMonitor, getParent, getShell, getSize, getToolTipText, getVisible, internal_dispose_GC, internal_new_GC, isEnabled, isFocusControl, isReparentable, isVisible, moveAbove, moveBelow, pack, pack, redraw, redraw, removeControlListener, removeFocusListener, removeHelpListener, removeKeyListener, removeMouseListener, removeMouseMoveListener, removeMouseTrackListener, removePaintListener, removeTraverseListener, setBackground, setBounds, setBounds, setCapture, setCursor, setEnabled, setFont, setForeground, setLayoutData, setLocation, setLocation, setMenu, setParent, setRedraw, setSize, setSize, setToolTipText, setVisible, toControl, toControl, toDisplay, toDisplay, traverse, update
 
Methods inherited from class org.eclipse.swt.widgets.Widget
addDisposeListener, addListener, checkWidget, dispose, getData, getData, getDisplay, getStyle, isDisposed, isListening, notifyListeners, removeDisposeListener, removeListener, removeListener, setData, setData, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

childrenListEditor

protected ChildrenListEditor childrenListEditor
The ChildrenListEditor used to edit nested SignaturePartBean instances.


fixtureNode

protected org.mockcentral.editor.nodes.fixture.FixtureNode fixtureNode
The current enclosing FixtureNode.


classNameText

protected org.eclipse.swt.widgets.Text classNameText
The Text for displaying/editing the class name.

Constructor Detail

InstanceFieldEditor

public InstanceFieldEditor(SelectSignaturePartTypePage page,
                           org.mockcentral.server.SignaturePartBean bean,
                           org.eclipse.swt.widgets.Composite parent,
                           org.mockcentral.editor.nodes.fixture.FixtureNode fixtureNode)
Creates a new instance.

Parameters:
page - the enclosing SelectSignaturePartTypePage.
bean - the SignaturePartBean being edited.
parent - the parent Composite.
Method Detail

getFieldEditor

public InstanceFieldEditor getFieldEditor(org.mockcentral.server.ValueType valueType,
                                          org.mockcentral.editor.nodes.fixture.FixtureNode fixtureNode)
Returns an editor used to set values for SignaturepartBean instances modeling a new Class, Throwable or Array object.

Parameters:
valueType - the ValueType used to select the appropriate
Returns:
an editor used to set values for SignaturepartBean instances modeling a new Class, Throwable or Array object.

createValueClassNameEditor

protected void createValueClassNameEditor(java.lang.Integer... args)
Description copied from class: AbstractFieldEditor
Creates the Composite used to edit the value class name of the SignaturePartBean. Not all subclasses will require this method.

Overrides:
createValueClassNameEditor in class AbstractFieldEditor
Parameters:
args - the number of columns for the layout for the Composite. If not supplied the value will be 1.

createValueEditor

protected void createValueEditor(java.lang.Integer... args)
Description copied from class: AbstractFieldEditor
Creates the Composite used to edit the value of the SignaturePartBean. Not all subclasses will require this method.

Overrides:
createValueEditor in class AbstractFieldEditor
Parameters:
args - the number of columns for the layout for the Composite. If not supplied the value will be 1.

createChildrenListEditor

protected void createChildrenListEditor()
Creates the editor for the list of nested SignaturepartBean instances.


openFilteredTypesSelectionDialog

protected void openFilteredTypesSelectionDialog()
opens a SelectTypeDialog to choose the class name