| Package | Description |
|---|---|
| cz.cuni.amis.pogamut.base.utils.math |
| Modifier and Type | Class and Description |
|---|---|
static class |
DistanceUtils.AcceptAllDistanceFilter<T>
Filter that accepts all "objects" (does not filter anything out).
|
static class |
DistanceUtils.FilterAdapter<T>
Adapter that wraps
IFilter making it into DistanceUtils.IDistanceFilter. |
static class |
DistanceUtils.RangeDistanceFilter<T>
Filter that accepts all "objects" that are within range of min/max distance (inclusive).
|
static class |
DistanceUtils.VisibleFilter<T extends IViewable>
Accepts only VISIBLE (
IViewable.isVisible() == TRUE) objects. |
| Modifier and Type | Field and Description |
|---|---|
static DistanceUtils.IDistanceFilter[] |
DistanceUtils.NO_FILTER
Contains single filter,
DistanceUtils.acceptAllDistanceFilter, i.e., this will ACCEPTS-ALL-ITEMS. |
| Modifier and Type | Method and Description |
|---|---|
static <T extends ILocated> |
DistanceUtils.getDistanceSorted(Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Returns "locations" accepted by all "filters" sorted according to the distance to "target".
|
static <T> List<T> |
DistanceUtils.getDistanceSorted(Collection<T> locations,
ILocated target,
DistanceUtils.IGetDistance getDistance,
DistanceUtils.IDistanceFilter... filters)
Returns "locations" accepted by all "filters" sorted according to the distance to "target".
|
static <T extends ILocated> |
DistanceUtils.getFarthest(Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Returns the farthest object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T> T |
DistanceUtils.getFarthest(Collection<T> locations,
ILocated target,
DistanceUtils.IGetDistance getDistance,
DistanceUtils.IDistanceFilter... filters)
Returns the farthest object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T extends ILocated> |
DistanceUtils.getFarthest2D(Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Returns the farthest (in 2D ~ [x,y]) object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T> T |
DistanceUtils.getInBestRelation(Collection<T> locations,
ILocated target,
DistanceUtils.IGetDistance getDistance,
DistanceUtils.IBetterRelation betterRelation,
DistanceUtils.IDistanceFilter... filters)
Returns "in-best-distance-relation-to-'target'" object.
|
static <T> T |
DistanceUtils.getInNthBestRelation(int nthBest,
Collection<T> locations,
ILocated target,
DistanceUtils.IGetDistance getDistance,
DistanceUtils.IBetterRelation betterRelation,
DistanceUtils.IDistanceFilter... filters)
Returns "in-nth-best-distance-relation-to-'target'" object from 'location'.
|
static <T extends ILocated> |
DistanceUtils.getNearest(Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Returns the nearest object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T> T |
DistanceUtils.getNearest(Collection<T> locations,
ILocated target,
DistanceUtils.IGetDistance getDistance,
DistanceUtils.IDistanceFilter... filters)
Returns the nearest object from 'location' to 'target' that is accepted by all 'filters'.
|
static <T extends ILocated> |
DistanceUtils.getNearest2D(Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Returns the nearest (in 2D ~ [x,y]) object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T extends ILocated> |
DistanceUtils.getNthFarthest(int nthFarthest,
Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Returns the nth-farthest object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T> T |
DistanceUtils.getNthFarthest(int nthFarthest,
Collection<T> locations,
ILocated target,
DistanceUtils.IGetDistance getDistance,
DistanceUtils.IDistanceFilter... filters)
Returns the n-th farthest object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T extends ILocated> |
DistanceUtils.getNthFarthest2D(int nthFarthest,
Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Returns the nth-farthest (in 2D ~ [x,y]) object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T extends ILocated> |
DistanceUtils.getNthNearest(int nthNearest,
Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Returns the nearest object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T> T |
DistanceUtils.getNthNearest(int nthNearest,
Collection<T> locations,
ILocated target,
DistanceUtils.IGetDistance getDistance,
DistanceUtils.IDistanceFilter... filters)
Returns the n-th nearest object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T extends ILocated> |
DistanceUtils.getNthNearest2D(int nthNearest,
Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Returns the nearest (in 2D ~ [x,y]) object from 'locations' to 'target' that is accepted by all 'filters'.
|
static <T extends ILocated> |
DistanceUtils.getSecondNearest(Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Deprecated.
|
static <T> T |
DistanceUtils.getSecondNearest(Collection<T> locations,
ILocated target,
DistanceUtils.IGetDistance getDistance,
DistanceUtils.IDistanceFilter... filters)
Deprecated.
|
static <T extends ILocated> |
DistanceUtils.getSecondNearest2D(Collection<T> locations,
ILocated target,
DistanceUtils.IDistanceFilter... filters)
Deprecated.
|
Copyright © 2019 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All rights reserved.