Package org.spongepowered.api.map.color
Interface MapColor
- All Superinterfaces:
DataSerializable
-
Nested Class Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic MapColor.Builder
builder()
Creates aMapColor.Builder
for generating a newMapColor
.color()
static MapColor
of
(Supplier<MapColorType> mapColorTypeSupplier) A method to ease usingMapColorTypes
enumeration.static MapColor
of
(Supplier<MapColorType> mapColorTypeSupplier, Supplier<MapShade> mapShadeSupplier) A method to ease using theMapColorTypes
andMapShade
.static MapColor
of
(MapColorType mapColorType) static MapColor
of
(MapColorType mapColorType, MapShade mapShade) shade()
type()
Gets theMapColorType
that thisMapColor
was built from.Methods inherited from interface org.spongepowered.api.data.persistence.DataSerializable
contentVersion, toContainer
-
Method Details
-
builder
Creates aMapColor.Builder
for generating a newMapColor
.- Returns:
- The builder
-
of
- Parameters:
mapColorType
- TheMapColorType
- Returns:
- The
MapColor
that represents the provided type
-
of
A method to ease usingMapColorTypes
enumeration. Unwraps the given supplier and callsof(MapColorType)
.- Parameters:
mapColorTypeSupplier
- Supplier to unwrap.- Returns:
- The
MapColor
that represents the provided type
-
of
- Parameters:
mapColorType
- TheMapColorType
mapShade
- TheMapShade
- Returns:
- The
MapColor
that represents the provided type
-
of
static MapColor of(Supplier<MapColorType> mapColorTypeSupplier, Supplier<MapShade> mapShadeSupplier) A method to ease using theMapColorTypes
andMapShade
. Unwraps the given suppliers and callsof(MapColorType, MapShade)
.- Parameters:
mapColorTypeSupplier
- Supplier to unwrapmapShadeSupplier
- Supplier to unwrap- Returns:
- The
MapColor
that represents the provided type.
-
type
MapColorType type()Gets theMapColorType
that thisMapColor
was built from.- Returns:
- The
MapColorType
-
shade
MapShade shade()- Returns:
- The
MapShade
-
color
Color color()- Returns:
- The
Color
-