Package com.indooratlas.android.sdk
Class IAPOI
- java.lang.Object
-
- com.indooratlas.android.sdk.IAPOI
-
- All Implemented Interfaces:
Parcelable
,IALatLngFloorCompatible
public class IAPOI extends Object implements IALatLngFloorCompatible, Parcelable
A data object representing a Point of Interest (POI)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
IAPOI.Builder
Builder to configureIAPOI
.-
Nested classes/interfaces inherited from interface android.os.Parcelable
Parcelable.ClassLoaderCreator<T extends Object>, Parcelable.Creator<T extends Object>
-
-
Field Summary
Fields Modifier and Type Field Description static Parcelable.Creator<IAPOI>
CREATOR
-
Fields inherited from interface android.os.Parcelable
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
describeContents()
boolean
equals(Object o)
int
getFloor()
Return theint
floor number for this POIString
getId()
Return the identifier for this POIIALatLngFloor
getLatLngFloor()
IALatLng
getLocation()
Return the WGS84 (latitude, longitude) coordinate of this POIString
getName()
Return name of this POI.JSONObject
getPayload()
Return theJSONObject
payload for this POI.int
hashCode()
boolean
hasPayload()
Check whether this POI has a non-empty payloadString
toString()
void
writeToParcel(Parcel parcel, int flags)
-
-
-
Field Detail
-
CREATOR
public static final Parcelable.Creator<IAPOI> CREATOR
-
-
Constructor Detail
-
IAPOI
public IAPOI(@NonNull String id, int floor, @NonNull IALatLng location, @Nullable String name, @Nullable JSONObject payload)
Construct a Point of Interest (POI)- Parameters:
id
- unique IDfloor
- floor numberlocation
- coordinatesname
- name of POI (optional)payload
- JSON payload (optional)
-
IAPOI
protected IAPOI(Parcel in)
Do not use this constructor directly.
-
-
Method Detail
-
writeToParcel
public void writeToParcel(Parcel parcel, int flags)
- Specified by:
writeToParcel
in interfaceParcelable
-
getId
public String getId()
Return the identifier for this POI
-
getFloor
public int getFloor()
Return theint
floor number for this POI
-
getLocation
public IALatLng getLocation()
Return the WGS84 (latitude, longitude) coordinate of this POI
-
getName
public String getName()
Return name of this POI. Empty string if not specified
-
getPayload
public JSONObject getPayload()
Return theJSONObject
payload for this POI. Empty object if not available.
-
hasPayload
public boolean hasPayload()
Check whether this POI has a non-empty payload- See Also:
getPayload()
-
describeContents
public int describeContents()
- Specified by:
describeContents
in interfaceParcelable
-
getLatLngFloor
public IALatLngFloor getLatLngFloor()
- Specified by:
getLatLngFloor
in interfaceIALatLngFloorCompatible
-
-