#1029: Trial changing a small number of inner enums to classes/interfaces to better support custom values

This PR is a subset of the enum PR #660 and is designed as a low impact
trial run of the design and backwards compatibility to inform subsequent
development.

Additional plugin compatibility features may be available by setting
`settings.compatibility.enum-compatibility-mode` to `true` in
`bukkit.yml`.

By: DerFrZocker <derrieple@gmail.com>
This commit is contained in:
Bukkit/Spigot
2024-07-06 17:14:17 +10:00
parent 250d585147
commit abc756fce8
7 changed files with 293 additions and 128 deletions

View File

@@ -31,5 +31,10 @@
<li>Implementation classes. Concrete implementation classes packaged with
Bukkit (eg those beginning with Simple) are not API. You should access them
via their interfaces instead.</li>
<li>The "enumness" of enums which implement {@link org.bukkit.Keyed}.
Such enums are liable to conversion to regular classes and therefore
usages deriving from their status as an enum (including, but not limited
to, use in switch statements and classes such as {@link java.util.EnumSet})
should be avoided.</li>
</ul>
</body>