MapViewRoutesCollection class Routes & Navigation

Mapview Routes collection class

This class should not be instantiated directly. Instead, use the MapViewPreferences.routes getter to obtain an instance.

Implemented types

Constructors

MapViewRoutesCollection(dynamic id, int mapId)
MapViewRoutesCollection.init(int id, int mapId)

Properties

first Route
The first element.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
hasInit bool
getter/setter pair
isEmpty bool
Whether this collection has no elements.
no setterinherited
isNotEmpty bool
Whether this collection has at least one element.
no setterinherited
iterator Iterator<Route>
A new Iterator that allows iterating the elements of this Iterable.
no setterinherited
last Route
The last element.
no setterinherited
length int
The number of elements in this Iterable.
no setterinherited
mainRoute Route?
Get the current main route.
getter/setter pair
mapId int
no setterinherited
pointerId → dynamic
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
single Route
Checks that this iterable has only one element, and returns that element.
no setterinherited

Methods

add(Route route, bool bMainRoute, {String? label, RouteRenderSettings? routeRenderSettings, bool autoGenerateLabel = false}) → void
Add or update a route in the collection with the given render settings.
addMapViewRoute(MapViewRoute route) → void
Add or update a route in the collection.
any(bool test(Route element)) bool
Checks whether any element of this iterable satisfies test.
inherited
at(int position) Route
inherited
cast<R>() Iterable<R>
A view of this iterable as an iterable of R instances.
inherited
clear() → void
Remove all routes.
clearAllButMainRoute() → void
Remove all routes, except the main route.
contains(Object? element) bool
Whether the collection contains an element equal to element.
inherited
dispose() → void
elementAt(int index) Route
Returns the indexth element.
inherited
every(bool test(Route element)) bool
Checks whether every element of this iterable satisfies test.
inherited
expand<R>(Iterable<R> toElements(Route element)) Iterable<R>
Expands each element of this Iterable into zero or more elements.
inherited
firstWhere(bool test(Route element), {Route orElse()?}) Route
The first element that satisfies the given predicate test.
inherited
fold<R>(R initialValue, R combine(R previousValue, Route element)) → R
Reduces a collection to a single value by iteratively combining each element of the collection with an existing value
inherited
followedBy(Iterable<Route> other) Iterable<Route>
Creates the lazy concatenation of this iterable and other.
inherited
forEach(void action(Route element)) → void
Invokes action on each element of this iterable in iteration order.
inherited
getLabel(Route route) String
Get route label text.
getMapViewRoute(int index) MapViewRoute?
Get map view route in collection by route.
getRenderSettings(Route route) RouteRenderSettings?
Get the route custom render settings(read-only)
getRoute(int index) Route?
Get route specified by index.
hideLabel(Route route) → void
Hide route label.
indexOf(Route route) int
Get the index of the specified route
isMainRoute(Route route) bool
Check if the route is the main route in the collection.
join([String separator = '']) String
Converts each element to a String and concatenates the strings.
inherited
lastWhere(bool test(Route element), {Route orElse()?}) Route
The last element that satisfies the given predicate test.
inherited
map<R>(R toElement(Route e)) Iterable<R>
The current elements of this iterable modified by toElement.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
reduce(Route combine(Route value, Route element)) Route
Reduces a collection to a single value by iteratively combining elements of the collection using the provided function.
inherited
registerAutoReleaseObject(int pointerId) → void
Registers an object for auto release.
inherited
remove(Route route) → void
Remove the route from the collection.
setLabel(Route route, String text) → void
Set route bubble text.
setRenderSettings(Route route, RouteRenderSettings settings) → void
Set route render settings.
singleWhere(bool test(Route element), {Route orElse()?}) Route
The single element that satisfies test.
inherited
size() int
inherited
skip(int count) Iterable<Route>
Creates an Iterable that provides all but the first count elements.
inherited
skipWhile(bool test(Route value)) Iterable<Route>
Creates an Iterable that skips leading elements while test is satisfied.
inherited
take(int count) Iterable<Route>
Creates a lazy iterable of the count first elements of this iterable.
inherited
takeWhile(bool test(Route value)) Iterable<Route>
Creates a lazy iterable of the leading elements satisfying test.
inherited
toList({bool growable = true}) List<Route>
Creates a List containing the elements of this Iterable.
inherited
toSet() Set<Route>
Creates a Set containing the same elements as this iterable.
inherited
toString() String
A string representation of this object.
inherited
where(bool test(Route element)) Iterable<Route>
Creates a new lazy Iterable with all elements that satisfy the predicate test.
inherited
whereType<U>() Iterable<U>
Creates a new lazy Iterable with all elements that have type T.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited
operator [](int index) Route
inherited