public static interface

MapUiApi.Itinerary

com.mapsted.ui.MapUiApi.Itinerary

Summary

Nested Classes
interface MapUiApi.Itinerary.ErrorMessageListener Listener for error messages to show UI  
interface MapUiApi.Itinerary.ItemChangeListener Listener for itinerary item changes  
Public Methods
abstract boolean add(ItineraryItem item)
Add item to itinerary
abstract boolean addAll(List<ItineraryItem> stops)
Add multiple items to itinerary
abstract boolean addErrorMessageListener(MapUiApi.Itinerary.ErrorMessageListener listener)
Add a listener for when error message should be shown to UI
abstract boolean addItemChangeListener(MapUiApi.Itinerary.ItemChangeListener listener)
Add a listener for when itinerary items changed
abstract boolean areAllDestinationsValid()
Whether or not all destinations are valid
abstract ItineraryItem get(int position)
Retrieve the itinerary item in the given position
abstract List<ItineraryItem> getItinerary()
Fetch the current itinerary
abstract boolean isStartCurrentLocation()
Whether or not the start is set to the user's current location
abstract boolean isStartValid()
Whether or not the start position is valid
abstract void processRoutingRequest(RoutingRequestCallback routingRequestCallback)
Process navigation request based on the current itinerary
abstract boolean removeByIndex(int idx)
Remove item from itinerary by index
abstract boolean removeByItineraryItem(ItineraryItem item)
Remove item from itinerary (by look-up)
abstract boolean removeByWaypoint(Waypoint waypoint)
Remove waypoint from itinerary (by look-up)
abstract boolean removeErrorMessageListener(MapUiApi.Itinerary.ErrorMessageListener listener)
remove a listener for when error message should be shown to UI
abstract boolean removeItemChangeListener(MapUiApi.Itinerary.ItemChangeListener listener)
remove a listener for when itinerary items changed
abstract void reset()
Reset the itinerary (to shared prefs or default)
abstract boolean set(int position, ItineraryItem item)
Replace the specific position with the supplied item
abstract boolean setAll(List<ItineraryItem> items)
Replace existing itinerary with the supplied items
abstract boolean swapItems(int idx1, int idx2)
Swap itinerary item positions
abstract boolean updateTag(Tag tag)
If a tag with a matching tagId is present in itinerary, update its tag information

Public Methods

public abstract boolean add (ItineraryItem item)

Add item to itinerary

Parameters
item item to add
Returns
  • whether or not adding the item as successful

public abstract boolean addAll (List<ItineraryItem> stops)

Add multiple items to itinerary

Parameters
stops items to add
Returns
  • whether or not adding the items were successful

public abstract boolean addErrorMessageListener (MapUiApi.Itinerary.ErrorMessageListener listener)

Add a listener for when error message should be shown to UI

Parameters
listener the listener
Returns
  • whether or not successfully added

public abstract boolean addItemChangeListener (MapUiApi.Itinerary.ItemChangeListener listener)

Add a listener for when itinerary items changed

Parameters
listener the listener
Returns
  • whether or not successfully added

public abstract boolean areAllDestinationsValid ()

Whether or not all destinations are valid

Returns
  • if all destinations are valid

public abstract ItineraryItem get (int position)

Retrieve the itinerary item in the given position

Parameters
position the position
Returns
  • the itinerary item or null if not found

public abstract List<ItineraryItem> getItinerary ()

Fetch the current itinerary

Returns
  • the current itinerary

public abstract boolean isStartCurrentLocation ()

Whether or not the start is set to the user's current location

Returns
  • if the start is set to the user's current location

public abstract boolean isStartValid ()

Whether or not the start position is valid

Returns
  • if it is valid

public abstract void processRoutingRequest (RoutingRequestCallback routingRequestCallback)

Process navigation request based on the current itinerary

Parameters
routingRequestCallback routing request callback

public abstract boolean removeByIndex (int idx)

Remove item from itinerary by index

Parameters
idx index to remove
Returns
  • whether successful

public abstract boolean removeByItineraryItem (ItineraryItem item)

Remove item from itinerary (by look-up)

Parameters
item item to remove
Returns
  • whether successful

public abstract boolean removeByWaypoint (Waypoint waypoint)

Remove waypoint from itinerary (by look-up)

Parameters
waypoint waypoint to remove
Returns
  • whether successful

public abstract boolean removeErrorMessageListener (MapUiApi.Itinerary.ErrorMessageListener listener)

remove a listener for when error message should be shown to UI

Parameters
listener the listener
Returns
  • whether or not successfully removed

public abstract boolean removeItemChangeListener (MapUiApi.Itinerary.ItemChangeListener listener)

remove a listener for when itinerary items changed

Parameters
listener the listener
Returns
  • whether or not successfully removed

public abstract void reset ()

Reset the itinerary (to shared prefs or default)

public abstract boolean set (int position, ItineraryItem item)

Replace the specific position with the supplied item

Parameters
position position to replace
item item to use
Returns
  • whether successful

public abstract boolean setAll (List<ItineraryItem> items)

Replace existing itinerary with the supplied items

Parameters
items items to set in the itinerary
Returns
  • whether successful

public abstract boolean swapItems (int idx1, int idx2)

Swap itinerary item positions

Parameters
idx1 first index position to swap
idx2 second index position to swap
Returns
  • whether or not successful

public abstract boolean updateTag (Tag tag)

If a tag with a matching tagId is present in itinerary, update its tag information

Parameters
tag the tag information to update
Returns
  • whether or not it was updated