Class CommonDockStationLayout
java.lang.Object
bibliothek.gui.dock.common.intern.station.CommonDockStationLayout
Information about the layout of a
CommonDockStation, used by the CommonDockStationFactory
to store and load the layout.- Author:
- Benjamin Sigg
-
Constructor Summary
ConstructorsConstructorDescriptionCommonDockStationLayout(String id, boolean root, String factoryId, byte[] layout) Creates a new layout.CommonDockStationLayout(String id, boolean root, String factoryId, DockLayout<?> layout) Creates a new layout.CommonDockStationLayout(String id, boolean root, String factoryId, XElement layout) Creates a new layout. -
Method Summary
Modifier and TypeMethodDescriptionGets the unique id of theDockFactorythat is used to read and store the actual layout.getId()Gets the unique id of theCommonDockStationwhich is described by this layout.DockLayout<?>Gets the layout information that was produced theDockFactorywith idgetFactoryId().byte[]Gets the layout information as byte array, assuming that the layout information is stored as byte array.Gets the layout information as xml element, assuming that the layout information is stored in xml.booleanisRoot()voidupdateLayout(DockFactory<?, ?, Object> factory, PlaceholderStrategy placeholders) Updates the contents of the internalDockLayoutInfousingfactoryto read a byte array or anXElement.
-
Constructor Details
-
CommonDockStationLayout
Creates a new layout.- Parameters:
id- the unique identifier of the describedCommonDockStation, might benullroot- whether theCStationis a root stationfactoryId- the unique identifier of theDockFactorythat is used to read or write the actual layoutlayout- the layout that was loaded by the factoryfactoryId
-
CommonDockStationLayout
Creates a new layout.- Parameters:
id- the unique identifier of the describedCommonDockStation, might benullroot- whether theCStationis a root stationfactoryId- the unique identifier of theDockFactorythat is used to read or write the actual layoutlayout- the layout that might be loaded by the factoryfactoryId
-
CommonDockStationLayout
Creates a new layout.- Parameters:
id- the unique identifier of the describedCommonDockStation, might benullroot- whether theCStationis a root stationfactoryId- the unique identifier of theDockFactorythat is used to read or write the actual layoutlayout- the layout that might be loaded by the factoryfactoryId
-
-
Method Details
-
updateLayout
Updates the contents of the internalDockLayoutInfousingfactoryto read a byte array or anXElement.- Parameters:
factory- the factory used to read the layoutplaceholders- the placeholders that may be used
-
getId
Gets the unique id of theCommonDockStationwhich is described by this layout.- Returns:
- the unique id, might be
null
-
isRoot
public boolean isRoot()- Returns:
- the root flag
-
getFactoryId
Gets the unique id of theDockFactorythat is used to read and store the actual layout.- Returns:
- the factory to be used, not
null
-
getLayoutBytes
public byte[] getLayoutBytes()Gets the layout information as byte array, assuming that the layout information is stored as byte array.- Returns:
- the layout information or
nullif not stored in byte array format
-
getLayoutXML
Gets the layout information as xml element, assuming that the layout information is stored in xml.- Returns:
- the layout information or
nullif not stored in xml format
-
getLayout
Gets the layout information that was produced theDockFactorywith idgetFactoryId().- Returns:
- the layout information or
nullif not present in object format
-