public class Setting
extends java.lang.Object
DockFrontend
.Constructor and Description |
---|
Setting() |
Modifier and Type | Method and Description |
---|---|
void |
addInvisible(java.lang.String key,
java.lang.String root,
DockLayoutComposition layout,
DockableProperty location)
Stores the location of an invisible element.
|
void |
fillMissing(DockSituation situation)
Using the factories given by
situation , this method tries
to fill any gaps in the layout. |
int |
getInvisibleCount()
Gets the number of stored invisible elements.
|
java.lang.String |
getInvisibleKey(int index)
Gets the key of the index'th invisible element.
|
DockLayoutComposition |
getInvisibleLayout(int index)
Gets the layout of the index'th invisible element.
|
DockableProperty |
getInvisibleLocation(int index)
Gets the location of the index'th invisible element.
|
java.lang.String |
getInvisibleRoot(int index)
Gets the preferred root of the index'th invisible element.
|
DockLayoutComposition |
getRoot(java.lang.String root)
Gets the layout of a root.
|
java.lang.String[] |
getRootKeys()
Gets the keys of all known roots.
|
void |
putRoot(java.lang.String root,
DockLayoutComposition layout)
Stores the layout of a root.
|
void |
read(DockSituation situation,
PropertyTransformer transformer,
boolean entry,
java.io.DataInputStream in)
Reads the properties of this setting.
|
void |
readXML(DockSituation situation,
PropertyTransformer transformer,
boolean entry,
XElement element)
Reads the properties of this setting.
|
void |
write(DockSituation situation,
PropertyTransformer transformer,
boolean entry,
java.io.DataOutputStream out)
Writes the properties of this setting into
out . |
void |
writeXML(DockSituation situation,
PropertyTransformer transformer,
boolean entry,
XElement element)
Writes the properties of this setting in xml format.
|
public void putRoot(java.lang.String root, DockLayoutComposition layout)
root
- the name of the rootlayout
- the layoutpublic DockLayoutComposition getRoot(java.lang.String root)
root
- the rootnull
public java.lang.String[] getRootKeys()
public void addInvisible(java.lang.String key, java.lang.String root, DockLayoutComposition layout, DockableProperty location)
key
- the key of the elementroot
- the preferred root of the elementlayout
- the layout of the element, may be null
location
- the location of the element on root
public int getInvisibleCount()
public java.lang.String getInvisibleKey(int index)
index
- the index of the elementpublic java.lang.String getInvisibleRoot(int index)
index
- the index of the elementpublic DockableProperty getInvisibleLocation(int index)
index
- the index of the elementpublic DockLayoutComposition getInvisibleLayout(int index)
index
- the index of the layoutnull
public void fillMissing(DockSituation situation)
situation
, this method tries
to fill any gaps in the layout.situation
- a set of factories to usejava.lang.IllegalArgumentException
- if situation
cannot handle
the content of this settingpublic void write(DockSituation situation, PropertyTransformer transformer, boolean entry, java.io.DataOutputStream out) throws java.io.IOException
out
.situation
- can be used to write DockLayout
stransformer
- can be used to write DockableProperty
sentry
- if true
, then this setting is used as one of
the settings a user can choose. If false
then this setting
is used as the final setting that is written when the application
shuts down.out
- a stream to write intojava.io.IOException
- if an I/O-error occurspublic void writeXML(DockSituation situation, PropertyTransformer transformer, boolean entry, XElement element)
situation
- can be used to write DockLayout
stransformer
- can be used to write DockableProperty
sentry
- if true
, then this setting is used as one of
the settings a user can choose. If false
then this setting
is used as the final setting that is written when the application
shuts down.element
- the element into which this setting writes, the attributes
of element
are not changed.public void read(DockSituation situation, PropertyTransformer transformer, boolean entry, java.io.DataInputStream in) throws java.io.IOException
situation
- can be used to read DockLayout
stransformer
- can be used to read DockableProperty
sentry
- if true
, then this setting is used as one of
the settings a user can choose. If false
then this setting
is used as the first setting that is read when the application
starts up.in
- the stream to read fromjava.io.IOException
- if an I/O-error occurspublic void readXML(DockSituation situation, PropertyTransformer transformer, boolean entry, XElement element)
situation
- can be used to read DockLayout
stransformer
- can be used to read DockableProperty
sentry
- if true
, then this setting is used as one of
the settings a user can choose. If false
then this setting
is used as the first setting that is read when the application
starts up.element
- the element which should be read