Package dev.turboism.sdk.ui.toolbar
Enum Class PaletteToolbarRegistry.Unavailable
java.lang.Object
java.lang.Enum<PaletteToolbarRegistry.Unavailable>
dev.turboism.sdk.ui.toolbar.PaletteToolbarRegistry.Unavailable
- All Implemented Interfaces:
PaletteToolbarRegistry,Serializable,Comparable<PaletteToolbarRegistry.Unavailable>,Constable
- Enclosing interface:
- PaletteToolbarRegistry
public static enum PaletteToolbarRegistry.Unavailable
extends Enum<PaletteToolbarRegistry.Unavailable>
implements PaletteToolbarRegistry
Sentinel returned by
PaletteToolbarRegistry.unavailable(): unsupported calls throw a stable UnsupportedOperationException.-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>Nested classes/interfaces inherited from interface dev.turboism.sdk.ui.toolbar.PaletteToolbarRegistry
PaletteToolbarRegistry.PaletteToolbarContribution, PaletteToolbarRegistry.Unavailable -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptioncontribute(PaletteToolbarRegistry.PaletteToolbarContribution contribution) Adds one toolbar button to the palette named by the contribution.booleanReports whether a live runtime surface backs this instance.Returns the enum constant of this class with the specified name.static PaletteToolbarRegistry.Unavailable[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
INSTANCE
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
isAvailable
public boolean isAvailable()Description copied from interface:PaletteToolbarRegistryReports whether a live runtime surface backs this instance.- Specified by:
isAvailablein interfacePaletteToolbarRegistry- Returns:
falseonly for thePaletteToolbarRegistry.unavailable()sentinel
-
contribute
Description copied from interface:PaletteToolbarRegistryAdds one toolbar button to the palette named by the contribution.- Specified by:
contributein interfacePaletteToolbarRegistry- Parameters:
contribution- what to add, and where- Returns:
- a handle whose closure removes the contributed button
-