public final class StackArrangement extends Object implements Iterable<BoundingBoxEnclosed>
BoundingBox
es that indicate where to locate corresponding Stack
s on a
unified larger image.Constructor and Description |
---|
StackArrangement(Extent extent)
Create with the overall
Extent and no boxes. |
StackArrangement(Extent extent,
BoundingBox box)
Create with a single
BoundingBox . |
StackArrangement(Extent extent,
List<BoundingBoxEnclosed> boxes) |
Modifier and Type | Method and Description |
---|---|
void |
add(BoundingBox box)
Adds a new
BoundingBox to the arrangement, with no padding. |
void |
add(BoundingBoxEnclosed box)
Adds a new
BoundingBoxEnclosed to the arrangement. |
List<BoundingBoxEnclosed> |
boxes()
Where to locate a respective image on a larger image.
|
boolean |
equals(Object o) |
Extent |
extent()
The size of the larger image in which all the
BoundingBox es in list must
fully reside. |
BoundingBoxEnclosed |
get(int index)
Gets the
BoundingBox corresponding to a particular index. |
int |
hashCode() |
Iterator<BoundingBoxEnclosed> |
iterator() |
String |
toString() |
forEach, spliterator
public StackArrangement(Extent extent)
Extent
and no boxes.extent
- the size of the larger image in which all the BoundingBox
es in list
must fully reside.public StackArrangement(Extent extent, BoundingBox box)
BoundingBox
.extent
- the size of the larger image in which all the BoundingBox
es in list
must fully reside.box
- the BoundingBox
.public StackArrangement(Extent extent, List<BoundingBoxEnclosed> boxes)
public void add(BoundingBox box)
BoundingBox
to the arrangement, with no padding.box
- the BoundingBox
in which the image should be placed.public void add(BoundingBoxEnclosed box)
BoundingBoxEnclosed
to the arrangement.box
- the BoundingBox
in which the image should be placed, together with any
enclosing box (e.g. with padding).public BoundingBoxEnclosed get(int index)
BoundingBox
corresponding to a particular index.index
- the index.BoundingBox
in the arrangement, and any enclosing
bounding-box.IndexOutOfBoundsException
- if the index is out of range.public Iterator<BoundingBoxEnclosed> iterator()
iterator
in interface Iterable<BoundingBoxEnclosed>
public Extent extent()
BoundingBox
es in list
must
fully reside.public List<BoundingBoxEnclosed> boxes()
Copyright © 2010–2023 Owen Feehan, ETH Zurich, University of Zurich, Hoffmann-La Roche. All rights reserved.