Class ParetoSelection<T,A,V extends java.lang.Comparable<V>>
- java.lang.Object
-
- ai.libs.jaicore.search.algorithms.standard.uncertainty.paretosearch.ParetoSelection<T,A,V>
-
- Type Parameters:
T- internal label of nodeV- external label of node
- All Implemented Interfaces:
java.lang.Iterable<BackPointerPath<T,A,V>>,java.util.Collection<BackPointerPath<T,A,V>>,java.util.Queue<BackPointerPath<T,A,V>>
public class ParetoSelection<T,A,V extends java.lang.Comparable<V>> extends java.lang.Object implements java.util.Queue<BackPointerPath<T,A,V>>
Open collection pareto front implementation.
-
-
Constructor Summary
Constructors Constructor Description ParetoSelection(java.util.Queue<BackPointerPath<T,A,V>> pareto)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanadd(BackPointerPath<T,A,V> n)Adds a node to the open list and, if its not dominated by any other point also to the pareto front.booleanaddAll(java.util.Collection<? extends BackPointerPath<T,A,V>> c)voidclear()booleancontains(java.lang.Object o)booleancontainsAll(java.util.Collection<?> c)BackPointerPath<T,A,V>element()booleanisEmpty()java.util.Iterator<BackPointerPath<T,A,V>>iterator()booleanoffer(BackPointerPath<T,A,V> arg0)BackPointerPath<T,A,V>peek()Return a node from pareto front.BackPointerPath<T,A,V>poll()BackPointerPath<T,A,V>remove()booleanremove(java.lang.Object o)Removes an Node frombooleanremoveAll(java.util.Collection<?> c)booleanretainAll(java.util.Collection<?> c)intsize()java.lang.Object[]toArray()<X> X[]toArray(X[] a)java.lang.StringtoString()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
-
-
-
Constructor Detail
-
ParetoSelection
public ParetoSelection(java.util.Queue<BackPointerPath<T,A,V>> pareto)
Constructor.- Parameters:
pareto- Pareto set implementation.
-
-
Method Detail
-
add
public boolean add(BackPointerPath<T,A,V> n)
Adds a node to the open list and, if its not dominated by any other point also to the pareto front.
-
addAll
public boolean addAll(java.util.Collection<? extends BackPointerPath<T,A,V>> c)
- Specified by:
addAllin interfacejava.util.Collection<T>
-
clear
public void clear()
- Specified by:
clearin interfacejava.util.Collection<T>
-
contains
public boolean contains(java.lang.Object o)
- Specified by:
containsin interfacejava.util.Collection<T>
-
containsAll
public boolean containsAll(java.util.Collection<?> c)
- Specified by:
containsAllin interfacejava.util.Collection<T>
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmptyin interfacejava.util.Collection<T>
-
iterator
public java.util.Iterator<BackPointerPath<T,A,V>> iterator()
-
removeAll
public boolean removeAll(java.util.Collection<?> c)
- Specified by:
removeAllin interfacejava.util.Collection<T>
-
retainAll
public boolean retainAll(java.util.Collection<?> c)
- Specified by:
retainAllin interfacejava.util.Collection<T>
-
size
public int size()
- Specified by:
sizein interfacejava.util.Collection<T>
-
toArray
public java.lang.Object[] toArray()
- Specified by:
toArrayin interfacejava.util.Collection<T>
-
toArray
public <X> X[] toArray(X[] a)
- Specified by:
toArrayin interfacejava.util.Collection<T>
-
peek
public BackPointerPath<T,A,V> peek()
Return a node from pareto front.- Specified by:
peekin interfacejava.util.Queue<T>
-
remove
public boolean remove(java.lang.Object o)
Removes an Node from- Specified by:
removein interfacejava.util.Collection<T>- Parameters:
o-- Returns:
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
element
public BackPointerPath<T,A,V> element()
- Specified by:
elementin interfacejava.util.Queue<T>
-
offer
public boolean offer(BackPointerPath<T,A,V> arg0)
- Specified by:
offerin interfacejava.util.Queue<T>
-
poll
public BackPointerPath<T,A,V> poll()
- Specified by:
pollin interfacejava.util.Queue<T>
-
remove
public BackPointerPath<T,A,V> remove()
- Specified by:
removein interfacejava.util.Queue<T>
-
-