summaryrefslogtreecommitdiff
path: root/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/offline/OfflineRegionDefinition.java
blob: 782968fb004a24140873b88c8cc5275f8201ff26 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
package com.mapbox.mapboxsdk.offline;

import android.support.annotation.Keep;

import com.mapbox.mapboxsdk.geometry.LatLngBounds;

/**
 * This is the interface that all Offline Region definitions have to implement.
 * <p>
 * For the present, a tile pyramid is the only type of offline region.
 */
@Keep
public interface OfflineRegionDefinition {

  /**
   * Gets the bounds of the OfflineRegion.
   *
   * @return the bounds of the OfflineRegion.
   */
  LatLngBounds getBounds();

  /**
   * Returns the map style url of the OfflineRegion.
   *
   * @return The URL of the map style.
   */
  String getStyleURL();

  /**
   * Gets the minimum zoom level the OfflineRegion map can be displayed at.
   *
   * @return The minimum zoom level.
   */
  double getMinZoom();

  /**
   * Gets the maximum zoom level the OfflineRegion map can be displayed at.
   *
   * @return The maximum zoom level.
   */
  double getMaxZoom();

  /**
   * Gets the pixel ratio of the OfflineRegion map.
   *
   * @return The pixel ratio of the OfflineRegion map.
   */
  float getPixelRatio();

  /**
   * Specifies whether to include ideographic glyphs in downloaded font data.
   * Ideographic glyphs make up the majority of downloaded font data, but
   * it is possible to configure the renderer to use locally installed fonts
   * instead of relying on fonts downloaded as part of the offline pack.
   *
   * Defaults to `true`
   *
   * @return true if offline region will include ideographic glyphs
   * @see MapboxMapOptions localIdeographFontFamily
   */
  boolean getIncludeIdeographs();

  /**
   * Gets the type of the OfflineRegionDefinition for telemetry ("tileregion", "shaperegion").
   *
   * @return The type of the OfflineRegionDefinition.
   */
  String getType();

}