diff options
Diffstat (limited to 'platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/exceptions/TooManySpritesException.java')
-rw-r--r-- | platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/exceptions/TooManySpritesException.java | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/exceptions/TooManySpritesException.java b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/exceptions/TooManySpritesException.java new file mode 100644 index 0000000000..d36c99edd2 --- /dev/null +++ b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/exceptions/TooManySpritesException.java @@ -0,0 +1,21 @@ +package com.mapbox.mapboxsdk.exceptions; + +import com.mapbox.mapboxsdk.annotations.Sprite; +import com.mapbox.mapboxsdk.annotations.SpriteFactory; + +/** + * <p> + * A {@code TooManySpritesException} is thrown by {@link SpriteFactory} when it + * cannot create a {@link Sprite} because there are already too many. + * </p> + * You should try to reuse Sprite objects whenever possible. + * + * @see SpriteFactory + */ +public class TooManySpritesException extends RuntimeException { + + public TooManySpritesException() { + super("Cannot create a Sprite because there are already too many. Try reusing Sprites."); + } + +} |