Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse Platform
Release 3.5

org.eclipse.ui.forms
Interface IManagedForm

All Known Implementing Classes:
ManagedForm

public interface IManagedForm

Managed form wraps a form widget and adds life cycle methods for form parts. A form part is a portion of the form that participates in form life cycle events.

There is no 1/1 mapping between widgets and form parts. A widget like Section can be a part by itself, but a number of widgets can gather around one form part.

This interface should not be extended or implemented. New form instances should be created using ManagedForm.

Since:
3.0
See Also:
ManagedForm
Restriction:
This interface is not intended to be implemented by clients.
Restriction:
This interface is not intended to be extended by clients.

Method Summary
 void addPart ( IFormPart part)
          Adds the new part to the form.
 void commit (boolean onSave)
          Commits the dirty form.
 void dirtyStateChanged ()
          Notifies the form that the dirty state of one of its parts has changed.
 void fireSelectionChanged ( IFormPart part, ISelection selection)
          A part can use this method to notify other parts that implement IPartSelectionListener about selection changes.
  Object getContainer ()
          Returns the container of this form.
  ScrolledForm getForm ()
          Returns the form widget managed by this form.
  Object getInput ()
          Returns the current page input.
  IMessageManager getMessageManager ()
          Returns the message manager that will keep track of messages in this form.
  IFormPart[] getParts ()
          Returns all the parts currently managed by this form.
  FormToolkit getToolkit ()
          Returns the toolkit used by this form.
 void initialize ()
          Initializes the form by looping through the managed parts and initializing them.
 boolean isDirty ()
          Tests if form is dirty.
 boolean isStale ()
          Tests if form is stale.
 void reflow (boolean changed)
          Reflows the form as a result of the layout change.
 void refresh ()
          Refreshes the form by refreshing every part that is stale.
 void removePart ( IFormPart part)
          Removes the part from the form.
 void setContainer ( Object container)
          Sets the container that owns this form.
 boolean setInput ( Object input)
          Sets the input of this page to the provided object.
 void staleStateChanged ()
          Notifies the form that the stale state of one of its parts has changed.
 

Method Detail

initialize

void initialize()
Initializes the form by looping through the managed parts and initializing them. Has no effect if already called once.

Since:
3.1

getToolkit


FormToolkit getToolkit()
Returns the toolkit used by this form.

Returns:
the toolkit

getForm


ScrolledForm getForm()
Returns the form widget managed by this form.

Returns:
the form widget

reflow

void reflow(boolean changed)
Reflows the form as a result of the layout change.

Parameters:
changed - if true, discard cached layout information

fireSelectionChanged

void fireSelectionChanged(
IFormPart part,
                          
ISelection selection)
A part can use this method to notify other parts that implement IPartSelectionListener about selection changes.

Parameters:
part - the part that broadcasts the selection
selection - the selection in the part

getParts


IFormPart[] getParts()
Returns all the parts currently managed by this form.

Returns:
the managed parts

addPart

void addPart(
IFormPart part)
Adds the new part to the form.

Parameters:
part - the part to add

removePart

void removePart(
IFormPart part)
Removes the part from the form.

Parameters:
part - the part to remove

setInput

boolean setInput(
Object input)
Sets the input of this page to the provided object.

Parameters:
input - the new page input
Returns:
true if the form contains this object, false otherwise.

getInput


Object getInput()
Returns the current page input.

Returns:
page input object or null if not applicable.

isDirty

boolean isDirty()
Tests if form is dirty. A managed form is dirty if at least one managed part is dirty.

Returns:
true if at least one managed part is dirty, false otherwise.

dirtyStateChanged

void dirtyStateChanged()
Notifies the form that the dirty state of one of its parts has changed. The global dirty state of the form can be obtained by calling 'isDirty'.

See Also:
isDirty()

commit

void commit(boolean onSave)
Commits the dirty form. All pending changes in the widgets are flushed into the model.

Parameters:
onSave -

isStale

boolean isStale()
Tests if form is stale. A managed form is stale if at least one managed part is stale. This can happen when the underlying model changes, resulting in the presentation of the part being out of sync with the model and needing refreshing.

Returns:
true if the form is stale, false otherwise.

staleStateChanged

void staleStateChanged()
Notifies the form that the stale state of one of its parts has changed. The global stale state of the form can be obtained by calling 'isStale'.


refresh

void refresh()
Refreshes the form by refreshing every part that is stale.


setContainer

void setContainer(
Object container)
Sets the container that owns this form. Depending on the context, the container may be wizard, editor page, editor etc.

Parameters:
container - the container of this form

getContainer


Object getContainer()
Returns the container of this form.

Returns:
the form container

getMessageManager


IMessageManager getMessageManager()
Returns the message manager that will keep track of messages in this form.

Returns:
the message manager instance
Since:
3.3

Eclipse Platform
Release 3.5

Guidelines for using Eclipse APIs.

Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire