Interface Features
-
Method Summary
Modifier and TypeMethodDescriptiondefault void
addTo
(Collection<Feature> collection) Adds all features in this collection to the given collection.default Features
Returns all features that have at least one common node with the givenFeature
.default Features
connectedTo
(Geometry geom) Returns all features that have at least one common vertex with the givenGeometry
.default Features
containing
(Feature feature) Returns all features that contain the given feature.default Features
containing
(Geometry geom) Returns all features that contain the givenGeometry
.default Features
containing
(PreparedGeometry prepared) Returns all features that contain the givenPreparedGeometry
.default Features
containingLonLat
(double lon, double lat) Returns all features that contain the given coordinate expressed at longitude and latitudedefault Features
containingXY
(int x, int y) Returns all features that contain the given Mercator-projected coordinatedefault boolean
Checks whether this collection contains the given object.default long
count()
Returns the number of features in this collection.default Features
default Features
default Features
coveredBy
(PreparedGeometry prepared) default Features
default Features
default Features
crossing
(PreparedGeometry prepared) default Features
default Features
default Features
disjoint
(PreparedGeometry prepared) default Feature
first()
Returns the first feature in the collection.Returns a view of this collection that contains only features whose bounding box intersects the givenBounds
.default Features
intersecting
(Feature feature) default Features
intersecting
(Geometry geom) default Features
intersecting
(PreparedGeometry prepared) default boolean
isEmpty()
Returnstrue
if this collection contains no features.default Features
maxMetersFrom
(double distance, Feature feature) Returns all features that lie within a given distance from anotherFeature
.default Features
maxMetersFrom
(double distance, Geometry geom) Returns all features that lie within a given distance from aGeometry
.default Features
maxMetersFromLonLat
(double distance, double lon, double lat) Returns all features whose closest point lies within a given radius.default Features
maxMetersFromXY
(double distance, int x, int y) Returns all features whose closest point lies within a given radius.default Features
Returns the features that are nodes of the given way, or members of the given relation.nodes()
Returns a view of this collection that contains only nodes.Returns a view of this collection that contains only nodes matching the given query.default Features
Returns a sub-view that contains only the features that are nodes of the given way.default Features
overlapping
(Feature feature) default Features
overlapping
(Geometry geom) default Features
overlapping
(PreparedGeometry prepared) default Features
Returns the features that are parent elements of the given feature (ways and/or relations).Returns a view of this collection that contains only relations.Returns a view of this collection that contains only relations matching the given query.Returns the features present in both this collection andother
.Returns a view of this collection that only contains features matching the given query.default Object[]
toArray()
Creates an array containing all features in this collection.default Feature[]
toList()
Creates aList
containing all features in this collection.default Features
default Features
default Features
touching
(PreparedGeometry prepared) ways()
Returns a view of this collection that contains only ways.Returns a view of this collection that contains only ways matching the given query.default Features
default Features
default Features
within
(PreparedGeometry prepared) Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
-
Method Details
-
select
-
nodes
-
nodes
-
ways
-
ways
-
relations
-
relations
-
nodesOf
-
membersOf
-
parentsOf
-
in
-
first
Returns the first feature in the collection. If the collection is unordered, this method selects one of multiple features in a non-deterministic way.- Returns:
- the first feature, or
null
if the collection is empty
-
count
default long count()Returns the number of features in this collection.- Returns:
- the number of features
-
isEmpty
default boolean isEmpty()Returnstrue
if this collection contains no features.- Returns:
true
if this collection contains no features
-
toList
-
toArray
Creates an array containing all features in this collection.- Returns:
- an array containing all features
-
toArray
-
contains
Checks whether this collection contains the given object.- Parameters:
f
- the object whose presence in this collection is to be tested- Returns:
true
if this collection contains the specified object
-
select
-
connectedTo
-
connectedTo
-
containingXY
Returns all features that contain the given Mercator-projected coordinate- Parameters:
x
-y
-- Returns:
-
containingLonLat
Returns all features that contain the given coordinate expressed at longitude and latitude- Parameters:
lon
-lat
-- Returns:
-
containing
-
containing
-
containing
Returns all features that contain the givenPreparedGeometry
.- Parameters:
prepared
-- Returns:
-
coveredBy
-
coveredBy
-
coveredBy
-
crossing
-
crossing
-
crossing
-
disjoint
-
disjoint
-
disjoint
-
intersecting
-
intersecting
-
intersecting
-
maxMetersFromXY
Returns all features whose closest point lies within a given radius.- Parameters:
distance
- the maximum distance (in meters)x
- the X coordinate of the center pointy
- the Y coordinate of the center point- Returns:
-
maxMetersFromLonLat
Returns all features whose closest point lies within a given radius.- Parameters:
distance
- the maximum distance (in meters)lon
- the longitude of the center pointlat
- the latitude of the center point- Returns:
-
maxMetersFrom
Returns all features that lie within a given distance from aGeometry
. The Filter measures the distance between the closest points of the Geometry and the candidate Feature.- Parameters:
distance
- the maximum distance (in meters)geom
- the Geometry from which to measure- Returns:
-
maxMetersFrom
Returns all features that lie within a given distance from anotherFeature
. The Filter measures the distance between the closest points of the features.- Parameters:
distance
- the maximum distance (in meters)feature
- the Feature from which to measure- Returns:
-
overlapping
-
overlapping
-
overlapping
-
touching
-
touching
-
touching
-
within
-
within
-
within
-
select
-
addTo
Adds all features in this collection to the given collection.- Parameters:
collection
- a general-purpose collection (such asList
,Set
, o another type derived fromjava.util.Collection
)
-