|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.infonode.docking.util.AbstractViewMap
public abstract class AbstractViewMap
Base class for view maps.
Field Summary | |
---|---|
private java.util.HashMap |
viewMap
|
private java.util.ArrayList |
views
|
Constructor Summary | |
---|---|
AbstractViewMap()
|
Method Summary | |
---|---|
protected void |
addView(java.lang.Object id,
View view)
|
boolean |
contains(View view)
Returns true if this view map contains the view. |
protected View |
getView(java.lang.Object id)
|
View |
getViewAtIndex(int index)
Returns the view at a specific index. |
int |
getViewCount()
Returns the number of views in this map. |
ViewFactory[] |
getViewFactories()
Returns the view factories. |
View |
readView(java.io.ObjectInputStream in)
Reads and returns a view. |
protected abstract java.lang.Object |
readViewId(java.io.ObjectInputStream in)
|
protected void |
removeView(java.lang.Object id)
|
void |
writeView(View view,
java.io.ObjectOutputStream out)
Writes a view to a stream. |
protected abstract void |
writeViewId(java.lang.Object id,
java.io.ObjectOutputStream out)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private java.util.HashMap viewMap
private java.util.ArrayList views
Constructor Detail |
---|
public AbstractViewMap()
Method Detail |
---|
protected abstract void writeViewId(java.lang.Object id, java.io.ObjectOutputStream out) throws java.io.IOException
java.io.IOException
protected abstract java.lang.Object readViewId(java.io.ObjectInputStream in) throws java.io.IOException
java.io.IOException
public int getViewCount()
public View getViewAtIndex(int index)
index
- the view index
public ViewFactory[] getViewFactories()
ViewFactoryManager
getViewFactories
in interface ViewFactoryManager
public boolean contains(View view)
view
- the view
public void writeView(View view, java.io.ObjectOutputStream out) throws java.io.IOException
ViewSerializer
writeView
in interface ViewSerializer
view
- the view to writeout
- the stream on which to write the view
java.io.IOException
- if there is a stream errorpublic View readView(java.io.ObjectInputStream in) throws java.io.IOException
ViewSerializer
ViewSerializer.writeView(net.infonode.docking.View, java.io.ObjectOutputStream)
method.
Note that the view property values are read automatically, so this method should not read them.
This method should return null if the serialized view can't be resolved.
readView
in interface ViewSerializer
in
- the stream from which to read the view state
java.io.IOException
- if there is a stream errorprotected void addView(java.lang.Object id, View view)
protected void removeView(java.lang.Object id)
protected View getView(java.lang.Object id)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |