MapDataStoreRenderer class
This renderer renders the bitmap for the tiles by using the given Datastore.
- Inheritance
-
- Object
- JobRenderer
- MapDataStoreRenderer
Constructors
- MapDataStoreRenderer(Datastore datastore, RenderTheme renderTheme, SymbolCache symbolCache, bool renderLabels, {bool useIsolate = false})
Properties
- datastore → Datastore
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- renderLabels → bool
-
When using the map heading north we can render the labels onto the images.
However if you want to support rotation the labels should not rotate with
the map so we are not allowed to render the labels onto the images.
final
- renderTheme → RenderTheme
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- symbolCache → SymbolCache
-
final
- tileDependencies ↔ TileDependencies?
-
getter/setter pair
- useIsolate → bool
-
true if isolates should be used for reading the mapfile. Isolate is flutter's
way of using threads. However due to the huge amount of data which must
be tunneled between the threads isolates are currently slower than working
directly in the main thread. The only advantage so far is that the main thread
is not blocked while the data are read.
final
Methods
-
createErrorBitmap(
int tileSize, dynamic error) → Future< TileBitmap> -
creates a bitmap tile with the given errormessage
inherited
-
createMissingBitmap(
int tileSize) → Future< TileBitmap> -
creates a tile bitmap with the information that the rendering of the given tile is not yet finished. This tile will normally
be replaced
when the rendering finishes.
inherited
-
createNoDataBitmap(
int tileSize) → Future< TileBitmap> -
Creates a tilebitmap which denotes that there are no maps with any data found for the given tile.
inherited
-
dispose(
) → void -
override
-
executeJob(
Job job) → Future< JobResult> -
Executes a given job and returns a future with the bitmap of this job.
@returns null if the datastore does not support the requested tile
@returns the Bitmap for the requested tile
override
-
getRenderKey(
) → String -
Returns a key for the caches. In order to use different caches for different renderings the
renderer can provide a unique key. The key should be the same if the rendering should provide the
exact same image again. The key should be different if the renderer provides different images. This
can be used for light/dark themes.
Note that different DisplayModels also may lead to different renderings (e.g. scaleFactors) but this
is currently not implemented in the default renderers. We assume that the displaymodel stays the same
at one single device or the cache will be deleted if the user changes the scalieFactors.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
retrieveLabels(
Job job) → Future< JobResult> -
For mapfiles we can either render everything into the images or render just the basic map and rotate the captions while rotating the map.
If supported this method returns the captions to draw each time (maybe rotated)
override
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- TAG_NATURAL_WATER → Tag
-
final
Static Methods
-
getTilePixelCoordinates(
int tileSize) → List< Mappoint>