Package io.scanbot.sdk.ui_v2.common
Class BadgeStyle
-
- All Implemented Interfaces:
-
android.os.Parcelable
public final class BadgeStyle implements Parcelable
Configuration of the badge.
-
-
Field Summary
Fields Modifier and Type Field Description private Booleanvisibleprivate BackgroundStylebackgroundprivate ScanbotColorforegroundColor
-
Constructor Summary
Constructors Constructor Description BadgeStyle(Map<String, Object> source)BadgeStyle(JSONObject json)BadgeStyle(Boolean visible, BackgroundStyle background, ScanbotColor foregroundColor)
-
Method Summary
Modifier and Type Method Description final BooleangetVisible()Determines whether the badge is visible or not. final UnitsetVisible(Boolean visible)Determines whether the badge is visible or not. final BackgroundStylegetBackground()Configuration of the background appearance for the badge. final UnitsetBackground(BackgroundStyle background)Configuration of the background appearance for the badge. final ScanbotColorgetForegroundColor()The color of the badge's foreground (icon, text). final UnitsetForegroundColor(ScanbotColor foregroundColor)The color of the badge's foreground (icon, text). final JSONObjecttoJson(ToJsonConfiguration config)final BadgeStyleclone()final static BadgeStyledefault()-
-
Constructor Detail
-
BadgeStyle
BadgeStyle(JSONObject json)
-
BadgeStyle
BadgeStyle(Boolean visible, BackgroundStyle background, ScanbotColor foregroundColor)
-
-
Method Detail
-
getVisible
final Boolean getVisible()
Determines whether the badge is visible or not.
Default is true
-
setVisible
final Unit setVisible(Boolean visible)
Determines whether the badge is visible or not.
Default is true
-
getBackground
final BackgroundStyle getBackground()
Configuration of the background appearance for the badge.
-
setBackground
final Unit setBackground(BackgroundStyle background)
Configuration of the background appearance for the badge.
-
getForegroundColor
final ScanbotColor getForegroundColor()
The color of the badge's foreground (icon, text).
Default is "?sbColorOnSurface"
-
setForegroundColor
final Unit setForegroundColor(ScanbotColor foregroundColor)
The color of the badge's foreground (icon, text).
Default is "?sbColorOnSurface"
-
toJson
final JSONObject toJson(ToJsonConfiguration config)
-
clone
final BadgeStyle clone()
-
default
final static BadgeStyle default()
-
-
-
-