Package org.arakhne.afc.math.geometry.d2
Class MultiShape2D.BackendList<CT extends Shape2D<?,?,?,?,?,?>>
- java.lang.Object
-
- org.arakhne.afc.math.geometry.d2.MultiShape2D.BackendList<CT>
-
- Type Parameters:
CT- the type of the shapes in the list view.
- All Implemented Interfaces:
Iterable<CT>,Collection<CT>,List<CT>
- Enclosing interface:
- MultiShape2D<ST extends Shape2D<?,?,I,P,V,B>,IT extends MultiShape2D<?,?,CT,I,P,V,B>,CT extends Shape2D<?,?,I,P,V,B>,I extends PathIterator2D<?>,P extends Point2D<? super P,? super V>,V extends Vector2D<? super V,? super P>,B extends Shape2D<?,?,I,P,V,B>>
public static class MultiShape2D.BackendList<CT extends Shape2D<?,?,?,?,?,?>> extends Object implements List<CT>
View on a list that is able to notify the backend when the view has change the backend data.- Version:
- 17.0 2020-01-04 14:41:43
- Author:
- Stéphane GALLAND
- Maven Group Id:
- org.arakhne.afc.core
- Maven Artifact Id:
- mathgeom
-
-
Constructor Summary
Constructors Constructor Description BackendList(MultiShape2D<?,?,CT,?,?,?,?> backend, List<CT> list)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(int index, CT element)booleanadd(CT element)booleanaddAll(int index, Collection<? extends CT> collection)booleanaddAll(Collection<? extends CT> collection)voidclear()booleancontains(Object obj)booleancontainsAll(Collection<?> collection)CTget(int index)intindexOf(Object obj)booleanisEmpty()Iterator<CT>iterator()intlastIndexOf(Object obj)ListIterator<CT>listIterator()ListIterator<CT>listIterator(int index)CTremove(int index)booleanremove(Object obj)booleanremoveAll(Collection<?> collection)booleanretainAll(Collection<?> collection)CTset(int index, CT element)intsize()List<CT>subList(int fromIndex, int toIndex)Object[]toArray()<T> T[]toArray(T[] array)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
-
Methods inherited from interface java.util.List
equals, hashCode, replaceAll, sort, spliterator
-
-
-
-
Constructor Detail
-
BackendList
public BackendList(MultiShape2D<?,?,CT,?,?,?,?> backend, List<CT> list)
Constructor.- Parameters:
backend- the associated backend.list- the original list.
-
-
Method Detail
-
size
@Pure public int size()
-
isEmpty
@Pure public boolean isEmpty()
-
contains
@Pure public boolean contains(Object obj)
-
toArray
@Pure public Object[] toArray()
-
toArray
public <T> T[] toArray(T[] array)
-
add
public boolean add(CT element)
-
add
public void add(int index, CT element)
-
remove
public boolean remove(Object obj)
-
remove
public CT remove(int index)
-
containsAll
@Pure public boolean containsAll(Collection<?> collection)
- Specified by:
containsAllin interfaceCollection<CT extends Shape2D<?,?,?,?,?,?>>- Specified by:
containsAllin interfaceList<CT extends Shape2D<?,?,?,?,?,?>>
-
addAll
public boolean addAll(Collection<? extends CT> collection)
-
addAll
public boolean addAll(int index, Collection<? extends CT> collection)
-
removeAll
public boolean removeAll(Collection<?> collection)
-
retainAll
public boolean retainAll(Collection<?> collection)
-
clear
public void clear()
-
get
@Pure public CT get(int index)
-
indexOf
@Pure public int indexOf(Object obj)
-
lastIndexOf
@Pure public int lastIndexOf(Object obj)
- Specified by:
lastIndexOfin interfaceList<CT extends Shape2D<?,?,?,?,?,?>>
-
listIterator
@Pure public ListIterator<CT> listIterator()
- Specified by:
listIteratorin interfaceList<CT extends Shape2D<?,?,?,?,?,?>>
-
listIterator
public ListIterator<CT> listIterator(int index)
- Specified by:
listIteratorin interfaceList<CT extends Shape2D<?,?,?,?,?,?>>
-
-