|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectbibliothek.gui.dock.layout.AbstractDockableProperty
bibliothek.gui.dock.station.split.SplitDockPathProperty
public class SplitDockPathProperty
A DockableProperty used by the SplitDockStation to describe
the location of a Dockable in the tree of all children of the station.
| Nested Class Summary | |
|---|---|
static class |
SplitDockPathProperty.Location
The direction which the path takes |
static class |
SplitDockPathProperty.Node
Describes one turn of the path. |
| Constructor Summary | |
|---|---|
SplitDockPathProperty()
Creates a new, empty path |
|
| Method Summary | |
|---|---|
void |
add(SplitDockPathProperty.Location location,
double size,
long id)
Adds a new element to the end of the path. |
DockableProperty |
copy()
Gets a copy of this property, the DockableProperty.getSuccessor() must be
copied as well. |
boolean |
equals(Object obj)
|
String |
getFactoryID()
Gets the unique name of the DockablePropertyFactory which
can create this type of DockableProperty. |
SplitDockPathProperty.Node |
getLastNode()
Gets the last node of this path. |
long |
getLeafId()
Gets the unique identifier of the leaf that was stored in this path. |
SplitDockPathProperty.Node |
getNode(int index)
Gets the index'th node, where the node 0 is the node nearest to the root. |
int |
hashCode()
|
void |
insert(SplitDockPathProperty.Location location,
double size,
int index,
long id)
Adds a new element to the path. |
Iterator<SplitDockPathProperty.Node> |
iterator()
|
void |
load(DataInputStream in)
Reads the contents of this DockableProperty from a stream. |
void |
load(XElement element)
Reads the contents of this DockableProperty from an
xml element. |
void |
setLeafId(long leafId)
Sets the unique identifier of the leaf that was stored in this path. |
int |
size()
Gets the number of nodes stores in this property. |
void |
store(DataOutputStream out)
Stores the contents of this DockableProperty in a stream. |
void |
store(XElement element)
Stores the contents of this property as xml element. |
SplitDockProperty |
toLocation()
Calculates which bounds the element accessed through the given path would have. |
SplitDockProperty |
toLocation(SplitNode onPath)
Calculates which bounds the element accessed through this path would have. |
String |
toString()
|
| Methods inherited from class bibliothek.gui.dock.layout.AbstractDockableProperty |
|---|
copy, equalsNoSuccessor, getSuccessor, setSuccessor |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public SplitDockPathProperty()
| Method Detail |
|---|
public DockableProperty copy()
DockablePropertyDockableProperty.getSuccessor() must be
copied as well.
copy in interface DockablePropertythispublic Iterator<SplitDockPathProperty.Node> iterator()
iterator in interface Iterable<SplitDockPathProperty.Node>public int size()
public SplitDockPathProperty.Node getNode(int index)
index - the index of the node
public void setLeafId(long leafId)
leafId - the id or -1public long getLeafId()
public SplitDockPathProperty.Node getLastNode()
null if this path is emptypublic SplitDockProperty toLocation()
public SplitDockProperty toLocation(SplitNode onPath)
onPath is a node that is on this path and
first searches for an item with the same unique identifier like onPath. If
such an item is found, then the current boundaries of onPath are taken
as start parameters.
onPath - some node which might be on this path
public void add(SplitDockPathProperty.Location location,
double size,
long id)
location - the direction into which the path goessize - the relative size of the path, a value in the range 0.0
to 1.0id - the unique identifier of the node or -1
public void insert(SplitDockPathProperty.Location location,
double size,
int index,
long id)
location - the direction into which the path goessize - the relative size of the path, a value in the range 0.0
to 1.0index - where to add the new elementid - the unique identifier of the new node or -1public String getFactoryID()
DockablePropertyDockablePropertyFactory which
can create this type of DockableProperty.
getFactoryID in interface DockablePropertyDockablePropertyFactory
public void store(DataOutputStream out)
throws IOException
DockablePropertysuccessor (if there is one) must
not be saved.
store in interface DockablePropertyout - the stream to write in
IOException - if anything unexpected happenspublic void store(XElement element)
DockableProperty
store in interface DockablePropertyelement - the element into which to write, the attributes of
this element should not be changed
public void load(DataInputStream in)
throws IOException
DockableProperty
load in interface DockablePropertyin - the stream to read
IOException - if anything unexpected happenspublic void load(XElement element)
DockablePropertyDockableProperty from an
xml element.
load in interface DockablePropertyelement - the element that was written earlier by this propertypublic String toString()
toString in class Objectpublic int hashCode()
hashCode in class AbstractDockablePropertypublic boolean equals(Object obj)
equals in class AbstractDockableProperty
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||