Class ImageCounterList<T extends org.anchoranalysis.annotation.io.assignment.Assignment<org.anchoranalysis.image.voxel.object.ObjectMask>>
Object
org.anchoranalysis.plugin.annotation.counter.ImageCounterList<T>
- Type Parameters:
T- the payload-type of eachImageCounter.
- All Implemented Interfaces:
Iterable<ImageCounter<T>>,ImageCounter<T>
public class ImageCounterList<T extends org.anchoranalysis.annotation.io.assignment.Assignment<org.anchoranalysis.image.voxel.object.ObjectMask>> extends Object implements Iterable<ImageCounter<T>>, ImageCounter<T>
Allows operations to be applied to several
ImageCounters collectively.- Author:
- Owen Feehan
-
Constructor Summary
Constructors Constructor Description ImageCounterList() -
Method Summary
Modifier and Type Method Description booleanadd(ImageCounter<T> e)Adds anImageCounterto the list.<S extends ImageCounter<T>>
booleanaddAll(Collection<S> e)Adds a collection ofImageCounters to the list.voidaddAnnotatedImage(T payload)Add an image that had an associated annotation.voidaddUnannotatedImage()Add an image that did not have an associated annotation.Iterator<ImageCounter<T>>iterator()Stream<ImageCounter<T>>stream()Returns a sequentialStreamwith this list as its source.
-
Constructor Details
-
ImageCounterList
public ImageCounterList()
-
-
Method Details
-
add
Adds anImageCounterto the list.- Parameters:
e- theImageCounterto add.- Returns:
- true if the counter was added successfully, false otherwise.
-
addAll
Adds a collection ofImageCounters to the list.- Type Parameters:
S- the type ofImageCounters in the collection.- Parameters:
e- the collection ofImageCounters to add.- Returns:
- true if the collection was added successfully, false otherwise.
-
addUnannotatedImage
public void addUnannotatedImage()Description copied from interface:ImageCounterAdd an image that did not have an associated annotation.- Specified by:
addUnannotatedImagein interfaceImageCounter<T extends org.anchoranalysis.annotation.io.assignment.Assignment<org.anchoranalysis.image.voxel.object.ObjectMask>>
-
addAnnotatedImage
Description copied from interface:ImageCounterAdd an image that had an associated annotation.- Specified by:
addAnnotatedImagein interfaceImageCounter<T extends org.anchoranalysis.annotation.io.assignment.Assignment<org.anchoranalysis.image.voxel.object.ObjectMask>>- Parameters:
payload- the payload associated with the annotated image.
-
iterator
-
stream
Returns a sequentialStreamwith this list as its source.- Returns:
- a sequential
Streamover the elements in this list.
-