|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.ivmaidns.util.ObservedCore net.sf.ivmaidns.storage.Storage net.sf.ivmaidns.storage.ObjectStorage net.sf.ivmaidns.storage.ListStorage
public class ListStorage
Class for list storage.
Field Summary | |
---|---|
protected int[] |
links
NOTE: links must be ! |
Fields inherited from class net.sf.ivmaidns.storage.ObjectStorage |
---|
elements |
Constructor Summary | |
---|---|
ListStorage()
|
Method Summary | |
---|---|
int |
childLocation(int parentLocation,
boolean forward)
NOTE: Must be synchronized outside. |
java.lang.Object |
clone()
NOTE: Must be synchronized outside. |
int |
emptyLocation()
NOTE: Result is an empty location (result > 0). |
int |
insertAt(int prevLoc,
int emptyLocation,
java.lang.Object value)
NOTE: prevLoc must be >= 0 (according to the semantics of list), otherwise ArrayStoreException is thrown. |
void |
integrityCheck()
NOTE: Shallow check for integrity of this object. |
protected void |
minimizeCapacity()
NOTE: Must be synchronized outside. |
java.lang.Object |
setAt(int location,
java.lang.Object value)
NOTE: If value is added then it is placed to the end of list. |
int |
siblingLocation(int location,
boolean forward)
NOTE: Must be synchronized outside. |
Methods inherited from class net.sf.ivmaidns.storage.ObjectStorage |
---|
findLessGreater, getAt, isValidAt, locationOf, parentLocation |
Methods inherited from class net.sf.ivmaidns.storage.Storage |
---|
add, addAll, addAll, clear, contains, containsAll, containsAll, containsCount, equals, greaterThan, hasChildren, hashCode, insertAtAll, insertAtAll, nextLocation, notifyObservers, notifyObservers, remove, removeAll, removeAll, removeAt, toArray, toInlineString, toOutlineString, toString, trimToSize |
Methods inherited from class net.sf.ivmaidns.util.ObservedCore |
---|
addObserver, hasObservers, removeObserver |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected transient int[] links
Constructor Detail |
---|
public ListStorage()
Method Detail |
---|
protected void minimizeCapacity()
minimizeCapacity
in class ObjectStorage
public final int emptyLocation()
Storage
emptyLocation
in class ObjectStorage
public int insertAt(int prevLoc, int emptyLocation, java.lang.Object value) throws java.lang.IllegalArgumentException, java.lang.ArrayStoreException
insertAt
in class ObjectStorage
java.lang.IllegalArgumentException
java.lang.ArrayStoreException
public java.lang.Object setAt(int location, java.lang.Object value) throws java.lang.IllegalArgumentException
setAt
in class ObjectStorage
java.lang.IllegalArgumentException
public int childLocation(int parentLocation, boolean forward) throws java.lang.IllegalArgumentException
childLocation
in class ObjectStorage
java.lang.IllegalArgumentException
public int siblingLocation(int location, boolean forward) throws java.lang.IllegalArgumentException
siblingLocation
in class ObjectStorage
java.lang.IllegalArgumentException
public java.lang.Object clone()
clone
in interface ReallyCloneable
clone
in class ObjectStorage
null
) of this
instance.public void integrityCheck()
integrityCheck
in interface Verifiable
integrityCheck
in class ObjectStorage
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |