Class LocationReferenceResolvers
LocationReferenceResolvers
to resolve different location reference types into Location Library data model specific
representations.-
Constructor Summary
ConstructorsConstructorDescriptionLocationReferenceResolvers(OptimizedMapLayers optimizedMapLayers) LocationReferenceResolvers(OptimizedMapLayers optimizedMapLayers, TmcAdjacencyProvider adjacencyProvider) -
Method Summary
Modifier and TypeMethodDescriptionCreates a resolver forExtendedTMCLocationReferences.extendedTmcV2(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.extendedTmcV2(Catalog optimizedMap, DataLoaderProvider cacheManager, TmcAdjacencyProvider adjacencyProvider) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers, adjacencyProvider).extendedTmc().olr()Creates a resolver that resolvesOpenLRLocationReferences toReferencingLocations.olr(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olr().Creates a resolver forCircleLocationReferences.Creates a resolver forClosedLinearLocationReferences.olrClosedLinear(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olrClosedLinear().Creates a resolver forGeoCoordinateLocationReference.olrGrid()Creates a resolver forGridLocationReferences.Creates a resolver forLinearLocationReferences.olrLinear(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olrLinear().Creates a resolver forPointAlongLineLocationReferences.olrPointAlongLine(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olrPointAlongLine().Creates a resolver forPOIWithAccessPointLocationReferences.olrPoiWithAccessPoint(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olrPoiWithAccessPoint().Creates a resolver forPolygonLocationReferences.Creates a resolver forRectangleLocationReferences.tmc()Creates a resolver for simpleTMCLocationReferences.tmc(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).tmc().tmc(Catalog optimizedMap, DataLoaderProvider cacheManager, TmcAdjacencyProvider adjacencyProvider) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers, adjacencyProvider).tmc().
-
Constructor Details
-
LocationReferenceResolvers
-
LocationReferenceResolvers
public LocationReferenceResolvers(OptimizedMapLayers optimizedMapLayers, TmcAdjacencyProvider adjacencyProvider) - Parameters:
adjacencyProvider- Provides information about TMC location adjacency to support creation of references withextent> 1.
-
-
Method Details
-
tmc
Creates a resolver for simpleTMCLocationReferences.TMC resolvers return a
BidirectionalLinearLocationbecause TMC location references can, at the same time, refer to the positive and negative parts of the location.For details on how TMC works, see the Developer Guide.
Note that without passing in a valid
adjacencyProviderthis API only supports resolving references withextent<= 1. To get support for a longerextentanadjacencyProviderneeds to be passed in.Note that this API only supports decoding of references with a valid extendedCountryCode.
-
extendedTmc
public LocationReferenceResolver<ExtendedTMCLocationReference,BidirectionalLinearLocation> extendedTmc()Creates a resolver forExtendedTMCLocationReferences.ExtendedTMCLocationReferencehave two fields with location reference:tmcLocationortmcExitEntryLocation.tmcLocation. Per the standard, only one of these two should be defined. This resolver uses thetmcLocationfield by default, and falls back to the other in case the former is not present.TMC resolvers return a
BidirectionalLinearLocationbecause TMC location references can, at the same time, refer to the positive and negative parts of the location.For details on how TMC works, see the Developer Guide.
Note that without passing in a valid
adjacencyProviderthis API only supports resolving references withextent<= 1. To get support for a longerextentanadjacencyProviderneeds to be passed in.Note that this API only supports decoding of references with a valid extendedCountryCode.
Note This method has the same behavior as the V2 method of the companion object.
-
tmc
@Deprecated public static LocationReferenceResolver<TMCLocationReference,BidirectionalLinearLocation> tmc(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).tmc().Creates a resolver for simpleTMCLocationReferences.TMC resolvers return a
BidirectionalLinearLocationbecause TMC location references can, at the same time, refer to the positive and negative parts of the location.For details on how TMC works, see the Developer Guide.
Note that this resolver only supports decoding of references with
extent<= 1 and a validextendedCountryCode. To get support for a longerextentanadjacencyProviderneeds to be passed in.- Parameters:
optimizedMap- An Optimized Map for Location Library instance
-
tmc
@Deprecated public static LocationReferenceResolver<TMCLocationReference,BidirectionalLinearLocation> tmc(Catalog optimizedMap, DataLoaderProvider cacheManager, TmcAdjacencyProvider adjacencyProvider) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers, adjacencyProvider).tmc().Creates a resolver for simpleTMCLocationReferences.TMC resolvers return a
BidirectionalLinearLocationbecause TMC location references can, at the same time, refer to the positive and negative parts of the location.For details on how TMC works, see the Developer Guide.
Note that this API only supports decoding of references with a valid
extendedCountryCode.- Parameters:
optimizedMap- An Optimized Map for Location Library instanceadjacencyProvider- TheadjacencyProvideris needed to decode references withextent> 1.
-
extendedTmcV2
@Deprecated public static LocationReferenceResolver<ExtendedTMCLocationReference,BidirectionalLinearLocation> extendedTmcV2(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).extendedTmc().Creates a resolver forExtendedTMCLocationReferences.ExtendedTMCLocationReferencehave two fields with location reference:tmcLocationortmcExitEntryLocation.tmcLocation. Per the standard, only one of these two should be defined. This resolver uses thetmcLocationfield by default, and falls back to the other in case the former is not present.TMC resolvers return a
BidirectionalLinearLocationbecause TMC location references can, at the same time, refer to the positive and negative parts of the location.For details on how TMC works, see the Developer Guide.
Note that this resolver only supports decoding of references with
extent<= 1 and a validextendedCountry Code. To get support for a longerextentanadjacencyProviderneeds to be passed in. *- Parameters:
optimizedMap- An Optimized Map for Location Library instance
-
extendedTmcV2
@Deprecated public static LocationReferenceResolver<ExtendedTMCLocationReference,BidirectionalLinearLocation> extendedTmcV2(Catalog optimizedMap, DataLoaderProvider cacheManager, TmcAdjacencyProvider adjacencyProvider) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers, adjacencyProvider).extendedTmc().Creates a resolver forExtendedTMCLocationReferences.ExtendedTMCLocationReferencehave two fields with location reference:tmcLocationortmcExitEntryLocation.tmcLocation. Per the standard, only one of these two should be defined. This resolver uses thetmcLocationfield by default, and falls back to the other in case the former is not present.TMC resolvers return a
BidirectionalLinearLocationbecause TMC location references can, at the same time, refer to the positive and negative parts of the location.For details on how TMC works, see the Developer Guide.
- Parameters:
optimizedMap- An Optimized Map for Location Library instance.adjacencyProvider- TheadjacencyProvideris needed to decode references withextent> 1.
-
olrLinear
Creates a resolver forLinearLocationReferences.A
LinearLocationReferencerefers to a path in the road network and thus needs to be resolved against a map. If the reference cannot be resolved anOlrResolverExceptionis thrown. Specific cases where this can happen are described in the documentation of the exception class. -
olrLinear
@Deprecated public static LocationReferenceResolver<LinearLocationReference,LinearLocation> olrLinear(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olrLinear().Creates a resolver forLinearLocationReferences.A
LinearLocationReferencerefers to a path in the road network and thus needs to be resolved against a map. If the reference cannot be resolved anOlrResolverExceptionis thrown.- Parameters:
optimizedMap- An Optimized Map for Location Library instance.
-
olrClosedLinear
@Deprecated public static LocationReferenceResolver<ClosedLinearLocationReference,ClosedLinearLocation> olrClosedLinear(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olrClosedLinear().Creates a resolver forClosedLinearLocationReferences.A
ClosedLinearLocationReferencerefers to a closed path in the road network and thus needs to be resolved against a map. If the reference cannot be resolved anOlrResolverExceptionis thrown.- Parameters:
optimizedMap- An Optimized Map for Location Library instance
-
olrPointAlongLine
Creates a resolver forPointAlongLineLocationReferences.A
PointAlongLineLocationReferencerefers to a point on a road section and thus needs to be resolved against a map. If the reference cannot be resolved anOlrResolverExceptionis thrown. Specific cases where this can happen are described in the documentation of the exception class. -
olrClosedLinear
public LocationReferenceResolver<ClosedLinearLocationReference,ClosedLinearLocation> olrClosedLinear()Creates a resolver forClosedLinearLocationReferences.A
ClosedLinearLocationReferencerefers to a closed path in the road network and thus needs to be resolved against a map. If the reference cannot be resolved anOlrResolverExceptionis thrown. Specific cases where this can happen are described in the documentation of the exception class. -
olrPointAlongLine
@Deprecated public static LocationReferenceResolver<PointAlongLineLocationReference,AccessPoint> olrPointAlongLine(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olrPointAlongLine().Creates a resolver forPointAlongLineLocationReferences.A
PointAlongLineLocationReferencerefers to a point on a road section and thus needs to be resolved against a map. If the reference cannot be resolved anOlrResolverExceptionis thrown.- Parameters:
optimizedMap- An Optimized Map for Location Library instance.
-
olrPoiWithAccessPoint
public LocationReferenceResolver<POIWithAccessPointLocationReference,PointOfInterest> olrPoiWithAccessPoint()Creates a resolver forPOIWithAccessPointLocationReferences.A
POIWithAccessPointLocationReferencerefers to an access point on a road section and thus needs to be resolved against a map. If the reference cannot be resolved anOlrResolverExceptionis thrown. Specific cases where this can happen are described in the documentation of the exception class. -
olrPoiWithAccessPoint
@Deprecated public static LocationReferenceResolver<POIWithAccessPointLocationReference,PointOfInterest> olrPoiWithAccessPoint(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olrPoiWithAccessPoint().Creates a resolver forPOIWithAccessPointLocationReferences.A
POIWithAccessPointLocationReferencerefers to an access point on a road section and thus needs to be resolved against a map. If the reference cannot be resolved anOlrResolverExceptionis thrown.- Parameters:
optimizedMap- An Optimized Map for Location Library instance.
-
olrRectangle
public static LocationReferenceResolver<RectangleLocationReference,RectangleLocation> olrRectangle()Creates a resolver forRectangleLocationReferences.A rectangle location reference is based on rectangular shapes and is defined in terms of a pair of geopoints, defining north/south latitude limits, and east/west longitude limits.
This reference type is disconnected from the road network, and does not require a catalog to be resolved.
-
olrGeoCoordinate
public static LocationReferenceResolver<GeoCoordinateLocationReference,GeoCoordinateLocation> olrGeoCoordinate()Creates a resolver forGeoCoordinateLocationReference.OLR's geocoordinates are represented by integer values. This resolver converts them back to WGS84 coordinates.
This reference type is disconnected from the road network, and does not require a catalog to be resolved.
-
olrPolygon
Creates a resolver forPolygonLocationReferences.A polygon location is a non-intersecting shape defined by a sequence of geocoordinate pairs. It can be used to represent any complex area in the map, like a low emission zone, or an area where traffic is overloaded.
This reference type is disconnected from the road network, and does not require a catalog to be resolved.
-
olrCircle
Creates a resolver forCircleLocationReferences.A circle location is given by a geo-location of the center of the circle and its radius.
Real-world examples include a Wi-Fi hotspot with its signal range, or the center and radius used with a proximity search.
This reference type is disconnected from the road network, and does not require a catalog to be resolved.
-
olrGrid
Creates a resolver forGridLocationReferences.Grid locations are defined in terms of a base rectangle location and a number of rows and columns. The base rectangle is multiplied to the north by the the number of rows and to the east by the number of columns.
Weather reports are a real-world example for this reference type. For instance, average rainfall could be defined for every cell of the grid.
This reference type is disconnected from the road network, and does not require a catalog to be resolved.
GridLocationprovides methods to retrieve all the bounding boxes that compose the grid. -
olr
Creates a resolver that resolvesOpenLRLocationReferences toReferencingLocations.This resolver chooses the correct type of
ReferencingLocationbased on the type the OpenLR reference that is being passed in. For the following reference types anOlrResolverExceptioncan be thrown if the reference cannot be resolved:LinearLocationReferencePointAlongLineLocationReferenceClosedLinearLocationReferencePOIWithAccessPointLocationReference
Specific cases where this can happen are described in the documentation of the exception class.
-
olr
@Deprecated public static LocationReferenceResolver<OpenLRLocationReference,ReferencingLocation> olr(Catalog optimizedMap, DataLoaderProvider cacheManager) Deprecated.Prefernew LocationReferenceResolvers(optimizedMapLayers).olr().Creates a resolver that resolvesOpenLRLocationReferences toReferencingLocations.This resolver chooses the correct type of
ReferencingLocationbased on the type the OpenLR reference that is being passed in.- Parameters:
optimizedMap- An Optimized Map for Location Library instance
-
new LocationReferenceResolvers(optimizedMapLayers).extendedTmc().