|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.util.AbstractCollection | +--java.util.AbstractList | +--java.util.ArrayList | +--MACS.PerceptionList
This class represents a list of Perceptions.
Field Summary |
---|
Fields inherited from class java.util.ArrayList |
---|
|
Fields inherited from class java.util.AbstractList |
---|
modCount |
Constructor Summary | |
---|---|
protected |
PerceptionList()
|
protected |
PerceptionList(MACS.PerceptionList source)
|
protected |
PerceptionList(java.util.Set p)
Creates a PerceptionList from a PerceptionSet |
protected |
PerceptionList(java.lang.String form,
java.lang.String value)
|
Method Summary | |
---|---|
protected MACS.PerceptionList |
buildMoreGeneralPerceptionList()
From one list of condition parts, this method produces a list of more general condition parts, each member in the list generalizing over one specific attribute of one of the initial condition part. |
protected static MACS.PerceptionList |
buildMoreGeneralPerceptionList(Classifier.Perception condition)
From one condition part, this method produces a list of more general condition parts, each member in the list generalizing over one specific attribute of the initial condition part. |
protected boolean |
containsMatching(Classifier.Perception perc)
|
protected boolean |
coversAtLeastOnePerceptionCoveredBy(MACS.AnticipatoryClassifierList incompatibleClassifierList,
Classifier.AnticipatoryClassifier classifier)
This method checks whether a classifier covers at least one Perception covered by the incompatibleClassifierList. |
protected boolean |
differsFrom(MACS.PerceptionList ps)
Necessary because contains does not seem to work for something else than addresses protected final boolean contains(Perception perc) { Iterator it = iterator(); while (it.hasNext()) { if (((Perception)it.next()).equals(perc))return true; } return false; } |
private int |
getIndexOfPerception(java.lang.String strPerc)
|
protected int |
getNbPerceptions()
|
protected Classifier.Perception |
getPerception(int index)
|
protected Classifier.Perception |
getRandomPerception()
|
protected boolean |
matchOneIdenticalPerception(Classifier.BasicClassifier c1,
Classifier.BasicClassifier c2)
|
protected void |
mergeWith(MACS.PerceptionList perceptionList)
This method merges two lists, making sure that identical elements are discarded. |
MACS.PerceptionList |
sort(java.lang.String orderSort)
This method is used by the TraceManager to organize the display. |
java.lang.String |
toString()
|
java.lang.String |
toString(java.lang.String orderSort)
|
java.lang.String |
toString(java.lang.String orderSort,
java.lang.String coords)
|
Methods inherited from class java.util.ArrayList |
---|
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, remove, removeRange, set, size, toArray, toArray, trimToSize |
Methods inherited from class java.util.AbstractList |
---|
equals, hashCode, iterator, listIterator, listIterator, subList |
Methods inherited from class java.util.AbstractCollection |
---|
containsAll, remove, removeAll, retainAll |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.List |
---|
containsAll, equals, hashCode, iterator, listIterator, listIterator, remove, removeAll, retainAll, subList |
Constructor Detail |
protected PerceptionList(java.util.Set p)
p
- the original PerceptionSetprotected PerceptionList(java.lang.String form, java.lang.String value)
form
- value
- protected PerceptionList(MACS.PerceptionList source)
source
- protected PerceptionList()
Method Detail |
protected final boolean differsFrom(MACS.PerceptionList ps)
ps
-
protected final Classifier.Perception getRandomPerception()
protected final int getNbPerceptions()
protected final Classifier.Perception getPerception(int index)
index
-
protected final boolean containsMatching(Classifier.Perception perc)
perc
-
protected final boolean matchOneIdenticalPerception(Classifier.BasicClassifier c1, Classifier.BasicClassifier c2)
c1
- c2
-
protected final void mergeWith(MACS.PerceptionList perceptionList)
perceptionList
- the list to be merged with the originalprotected static final MACS.PerceptionList buildMoreGeneralPerceptionList(Classifier.Perception condition)
condition
- a tentative condition part that should be generalized further
protected final MACS.PerceptionList buildMoreGeneralPerceptionList()
protected boolean coversAtLeastOnePerceptionCoveredBy(MACS.AnticipatoryClassifierList incompatibleClassifierList, Classifier.AnticipatoryClassifier classifier)
incompatibleClassifierList
- classifier
-
GeneralizationManager
private final int getIndexOfPerception(java.lang.String strPerc)
strPerc
-
public final MACS.PerceptionList sort(java.lang.String orderSort)
orderSort
-
public final java.lang.String toString(java.lang.String orderSort, java.lang.String coords)
orderSort
- coords
-
public final java.lang.String toString(java.lang.String orderSort)
orderSort
-
public java.lang.String toString()
toString
in class java.util.AbstractCollection
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |