com.tensegrity.gui.component
Interface AttributeEditorStateManager

All Known Implementing Classes:
DefaultSwingAttributeTreeStateManager, SwtAttributeTreeStateManager

public interface AttributeEditorStateManager

This interface describes the methods that have to be implemented to provide a manager for restoring the state of an AttributeEditor after an AttributableOnSet has changed.

The implementation is responsible for mapping a specific AttributableOnSet (which might be a AttributableOnSetCollection) to a stored state that usually includes properties like selection, expansion and scroll position.

Implementations of this interface are used in AttributeTrees and can be assigned by using AttributeTree.setAttributeEditorStateManager(AttributeEditorStateManager).

The callback method storeEditorState(AttributableOnSet) is called before the AttributableOnSet instance assigned to the editor is replaced by a different one and restoreEditorState(AttributableOnSet) is called after it has been replaced.

Author:
BurkhardWick

Method Summary
 void restoreEditorState(AttributableOnSet attributable)
          Restores the state for the given AttributableOnSet when it is assigned to the AttributeEditor.
 void storeEditorState(AttributableOnSet attributable)
          Stores the state for the given AttributableOnSet when it is removed from the AttributeEditor.
 

Method Detail

storeEditorState

public void storeEditorState(AttributableOnSet attributable)
Stores the state for the given AttributableOnSet when it is removed from the AttributeEditor.

Parameters:
attributable - The item to store the state for, might be null

restoreEditorState

public void restoreEditorState(AttributableOnSet attributable)
Restores the state for the given AttributableOnSet when it is assigned to the AttributeEditor.

Parameters:
attributable - The item to restore the state for, might be null


Copyright © 2005 Tensegrity Software GmbH. All Rights Reserved. Date of creation: 09.06.2006.