Package org.opennms.features.geocoder
Class GeocoderResult
- java.lang.Object
-
- org.opennms.features.geocoder.GeocoderResult
-
public class GeocoderResult extends Object
The resolution result of theGeocoderService
. This allows to distinguish between no and unsuccessful result.- Author:
- mvrueden
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GeocoderResult.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static GeocoderResult.Builder
builder()
static GeocoderResult.Builder
error(Exception exception)
static GeocoderResult.Builder
error(String errorMessage)
String
getAddress()
Coordinates
getCoordinates()
Throwable
getThrowable()
boolean
hasError()
boolean
isEmpty()
static GeocoderResult.Builder
noResult(String address)
static GeocoderResult.Builder
success(String address, double lng, double lat)
-
-
-
Method Detail
-
hasError
public boolean hasError()
-
isEmpty
public boolean isEmpty()
-
getThrowable
public Throwable getThrowable()
-
getCoordinates
public Coordinates getCoordinates()
-
getAddress
public String getAddress()
-
builder
public static GeocoderResult.Builder builder()
-
success
public static GeocoderResult.Builder success(String address, double lng, double lat)
-
noResult
public static GeocoderResult.Builder noResult(String address)
-
error
public static GeocoderResult.Builder error(String errorMessage)
-
error
public static GeocoderResult.Builder error(Exception exception)
-
-