Package net.pl3x.map.core.markers.option
Class Options
java.lang.Object
net.pl3x.map.core.markers.option.Options
- All Implemented Interfaces:
JsonSerializable
Represents a
Marker
's options.-
Nested Class Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription@NotNull Options.Builder
Create a newOptions.Builder
from thisOptions
instancestatic @NotNull Options.Builder
builder()
Create a newOptions.Builder
.boolean
static @NotNull Options
fromJson
(@NotNull com.google.gson.JsonObject obj) @Nullable Fill
getFill()
Get fill rules.@Nullable Popup
getPopup()
Get popup rules.@Nullable Stroke
Get stroke rules.@Nullable Tooltip
Get tooltip rules.int
hashCode()
@NotNull Options
Set new fill rules.@NotNull Options
Set new popup rules.@NotNull Options
Set new stroke rules.@NotNull Options
setTooltip
(@Nullable Tooltip tooltip) Set new tooltip rules.@NotNull com.google.gson.JsonObject
toJson()
Jsonify this object.@NotNull String
toString()
-
Constructor Details
-
Options
public Options()Create empty marker options. -
Options
public Options(@Nullable @Nullable Stroke stroke, @Nullable @Nullable Fill fill, @Nullable @Nullable Tooltip tooltip, @Nullable @Nullable Popup popup) Create marker options.- Parameters:
stroke
- stroke rulesfill
- fill rulestooltip
- tooltip rules
-
-
Method Details
-
builder
Create a newOptions.Builder
. -
getStroke
Get stroke rules.- Returns:
- stroke rules
-
setStroke
Set new stroke rules.- Parameters:
stroke
- new stroke rules.- Returns:
- this marker options
-
getFill
Get fill rules.- Returns:
- fill rules
-
setFill
Set new fill rules.- Parameters:
fill
- new fill rules- Returns:
- this marker options
-
getTooltip
Get tooltip rules.- Returns:
- tooltip rules
-
setTooltip
Set new tooltip rules.- Parameters:
tooltip
- new tooltip rules- Returns:
- this marker options
-
getPopup
Get popup rules.- Returns:
- popup rules
-
setPopup
Set new popup rules.- Parameters:
popup
- new popup rules- Returns:
- this marker options
-
asBuilder
Create a newOptions.Builder
from thisOptions
instance- Returns:
- new builder
-
toJson
@NotNull public @NotNull com.google.gson.JsonObject toJson()Description copied from interface:JsonSerializable
Jsonify this object.- Specified by:
toJson
in interfaceJsonSerializable
- Returns:
- object as json element
-
fromJson
-
equals
-
hashCode
public int hashCode() -
toString
-