de.cau.cs.kieler.kiml
Interface ILayoutConfig

All Superinterfaces:
IPropertyHolder
All Known Implementing Classes:
DefaultLayoutConfig, EclipseLayoutConfig, GmfLayoutConfig, VolatileLayoutConfig

public interface ILayoutConfig
extends IPropertyHolder

Layout option configuration interface for default values and configuration of specific diagram elements. getProperty() is used to get the stored or default value for a layout option, while setProperty() is used to change the stored option value.

Rating red

Method Summary
 void clearProperties()
          Remove all stored layout options.
 LayoutProviderData getContainerLayouterData()
          Returns the layout provider descriptor for the container of the associated element.
 LayoutProviderData getContentLayouterData()
          Returns the layout provider descriptor for the content of the associated element.
 LayoutProviderData getLayouterData(String layoutHint, String diagramType)
          Returns the most appropriate layout provider for the given layout hint and diagram type.
 List<LayoutOptionData<?>> getOptionData()
          Returns a list of available layout option descriptors.
 boolean isDefault(LayoutOptionData<?> optionData)
          Returns true if the given option has its default value.
 void setDiagramDefault(LayoutOptionData<?> optionData, Object value)
          Sets the given option as default value for all elements of the associated diagram.
 void setFocus(Object element)
          Set the focus of this layout configuration on the given element.
 
Methods inherited from interface de.cau.cs.kieler.core.properties.IPropertyHolder
copyProperties, getAllProperties, getProperty, setProperty
 

Method Detail

setFocus

void setFocus(Object element)
Set the focus of this layout configuration on the given element.

Parameters:
element - a diagram element for which layout options shall be analyzed

isDefault

boolean isDefault(LayoutOptionData<?> optionData)
Returns true if the given option has its default value.

Parameters:
optionData - a layout option data
Returns:
whether the option has a default value

getOptionData

List<LayoutOptionData<?>> getOptionData()
Returns a list of available layout option descriptors.

Returns:
list of available layout options

getContentLayouterData

LayoutProviderData getContentLayouterData()
Returns the layout provider descriptor for the content of the associated element.

Returns:
the layout provider data for the element's content

getContainerLayouterData

LayoutProviderData getContainerLayouterData()
Returns the layout provider descriptor for the container of the associated element.

Returns:
the layout provider data for the element's container

clearProperties

void clearProperties()
Remove all stored layout options.


setDiagramDefault

void setDiagramDefault(LayoutOptionData<?> optionData,
                       Object value)
Sets the given option as default value for all elements of the associated diagram.

Parameters:
optionData - layout option data
value - new default value

getLayouterData

LayoutProviderData getLayouterData(String layoutHint,
                                   String diagramType)
Returns the most appropriate layout provider for the given layout hint and diagram type.

Parameters:
layoutHint - identifier of either a layout provider or a layout type
diagramType - identifier of a diagram type
Returns:
the most appropriate layout provider, or null