summaryrefslogtreecommitdiff
path: root/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/style/layers/BackgroundLayer.java
diff options
context:
space:
mode:
authorCameron Mace <cameron@mapbox.com>2016-12-16 16:19:15 -0500
committerGitHub <noreply@github.com>2016-12-16 16:19:15 -0500
commit20b958301eb208fe9ed0ae8edfb14b6f3741d8f2 (patch)
tree94ae0ce250cda159be13f9a21cc70c92d4908974 /platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/style/layers/BackgroundLayer.java
parentf95b4838ea816b9da0c151a953a1f98f97c79a39 (diff)
downloadqtlocation-mapboxgl-20b958301eb208fe9ed0ae8edfb14b6f3741d8f2.tar.gz
Adds checkstyle to CI (#7442)
* adds checkstyle to CI * fixed gradlew path * resolved testapp checkstyle violations * added back mapboxMap variable for test * checkstyle annotations * checkstyle SDK round 1 * maps package checkstyle * rest of SDK checkstyle * checkstyle gesture library * checkstyle test * finished rest of test checkstyle * resolved all checkstyle errors * fixed class name * removed old test file * fixed camera postion test * fixed native crash
Diffstat (limited to 'platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/style/layers/BackgroundLayer.java')
-rw-r--r--platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/style/layers/BackgroundLayer.java166
1 files changed, 83 insertions, 83 deletions
diff --git a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/style/layers/BackgroundLayer.java b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/style/layers/BackgroundLayer.java
index c78887ff15..45523b41ab 100644
--- a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/style/layers/BackgroundLayer.java
+++ b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/style/layers/BackgroundLayer.java
@@ -1,12 +1,11 @@
-// This file is generated. Edit android/platform/scripts/generate-style-code.js, then run `make android-style-code`.
package com.mapbox.mapboxsdk.style.layers;
-
-import android.support.annotation.UiThread;
+// This file is generated. Edit android/platform/scripts/generate-style-code.js, then run `make android-style-code`.
import android.support.annotation.ColorInt;
import android.support.annotation.NonNull;
+import android.support.annotation.UiThread;
-import static com.mapbox.mapboxsdk.utils.ColorUtils.*;
+import static com.mapbox.mapboxsdk.utils.ColorUtils.rgbaToColor;
/**
* The background color or pattern of the map.
@@ -16,93 +15,94 @@ import static com.mapbox.mapboxsdk.utils.ColorUtils.*;
@UiThread
public class BackgroundLayer extends Layer {
- /**
- * Creates a BackgroundLayer.
- *
- * @param nativePtr pointer used by core
- */
- public BackgroundLayer(long nativePtr) {
- super(nativePtr);
- }
-
- /**
- * Creates a BackgroundLayer.
- *
- * @param layerId the id of the layer
- */
- public BackgroundLayer(String layerId) {
- initialize(layerId);
+ /**
+ * Creates a BackgroundLayer.
+ *
+ * @param nativePtr pointer used by core
+ */
+ public BackgroundLayer(long nativePtr) {
+ super(nativePtr);
+ }
+
+ /**
+ * Creates a BackgroundLayer.
+ *
+ * @param layerId the id of the layer
+ */
+ public BackgroundLayer(String layerId) {
+ initialize(layerId);
+ }
+
+ protected native void initialize(String layerId);
+
+ /**
+ * Set a property or properties.
+ *
+ * @param properties the var-args properties
+ * @return This
+ */
+ public BackgroundLayer withProperties(@NonNull Property<?>... properties) {
+ setProperties(properties);
+ return this;
+ }
+
+ // Property getters
+
+ /**
+ * Get the BackgroundColor property
+ *
+ * @return property wrapper value around String
+ */
+ @SuppressWarnings("unchecked")
+ public PropertyValue<String> getBackgroundColor() {
+ return (PropertyValue<String>) new PropertyValue(nativeGetBackgroundColor());
+ }
+
+ /**
+ * The color with which the background will be drawn.
+ *
+ * @return int representation of a rgba string color
+ * @throws RuntimeException thrown if property isn't a value
+ */
+ @ColorInt
+ public int getBackgroundColorAsInt() {
+ PropertyValue<String> value = getBackgroundColor();
+ if (value.isValue()) {
+ return rgbaToColor(value.getValue());
+ } else {
+ throw new RuntimeException("background-color was set as a Function");
}
+ }
- protected native void initialize(String layerId);
-
- /**
- * Set a property or properties.
- *
- * @param properties the var-args properties
- * @return This
- */
- public BackgroundLayer withProperties(@NonNull Property<?>... properties) {
- setProperties(properties);
- return this;
- }
- // Property getters
+ /**
+ * Get the BackgroundPattern property
+ *
+ * @return property wrapper value around String
+ */
+ @SuppressWarnings("unchecked")
+ public PropertyValue<String> getBackgroundPattern() {
+ return (PropertyValue<String>) new PropertyValue(nativeGetBackgroundPattern());
+ }
- /**
- * Get the BackgroundColor property
- *
- * @return property wrapper value around String
- */
- @SuppressWarnings("unchecked")
- public PropertyValue<String> getBackgroundColor() {
- return (PropertyValue<String>) new PropertyValue(nativeGetBackgroundColor());
- }
- /**
- * The color with which the background will be drawn.
- *
- * @return int representation of a rgba string color
- * @throws RuntimeException thrown if property isn't a value
- */
- @ColorInt
- public int getBackgroundColorAsInt() {
- PropertyValue<String> value = getBackgroundColor();
- if (value.isValue()) {
- return rgbaToColor(value.getValue());
- } else {
- throw new RuntimeException("background-color was set as a Function");
- }
- }
+ /**
+ * Get the BackgroundOpacity property
+ *
+ * @return property wrapper value around Float
+ */
+ @SuppressWarnings("unchecked")
+ public PropertyValue<Float> getBackgroundOpacity() {
+ return (PropertyValue<Float>) new PropertyValue(nativeGetBackgroundOpacity());
+ }
-
- /**
- * Get the BackgroundPattern property
- *
- * @return property wrapper value around String
- */
- @SuppressWarnings("unchecked")
- public PropertyValue<String> getBackgroundPattern() {
- return (PropertyValue<String>) new PropertyValue(nativeGetBackgroundPattern());
- }
-
- /**
- * Get the BackgroundOpacity property
- *
- * @return property wrapper value around Float
- */
- @SuppressWarnings("unchecked")
- public PropertyValue<Float> getBackgroundOpacity() {
- return (PropertyValue<Float>) new PropertyValue(nativeGetBackgroundOpacity());
- }
-
- private native Object nativeGetBackgroundColor();
+ private native Object nativeGetBackgroundColor();
- private native Object nativeGetBackgroundPattern();
+ private native Object nativeGetBackgroundPattern();
- private native Object nativeGetBackgroundOpacity();
+ private native Object nativeGetBackgroundOpacity();
- @Override
- protected native void finalize() throws Throwable;
+ @Override
+ protected native void finalize() throws Throwable;
}