Package io.papermc.paper.registry.set
Interface RegistryKeySet<T extends Keyed>
- All Superinterfaces:
Iterable<TypedKey<T>>
,RegistrySet<T>
- All Known Subinterfaces:
Tag<T>
@Experimental
@NullMarked
@NonExtendable
public non-sealed interface RegistryKeySet<T extends Keyed>
extends Iterable<TypedKey<T>>, RegistrySet<T>
-
Method Summary
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface io.papermc.paper.registry.set.RegistrySet
isEmpty, registryKey
-
Method Details
-
size
default int size()Description copied from interface:RegistrySet
Get the size of this set.- Specified by:
size
in interfaceRegistrySet<T extends Keyed>
- Returns:
- the size
-
values
@Unmodifiable Collection<TypedKey<T>> values()Get the keys for the values in this set.- Returns:
- the keys
-
resolve
Resolve this set into a collection of values. Prefer usingvalues()
.- Parameters:
registry
- the registry to resolve the values from (must matchRegistrySet.registryKey()
)- Returns:
- the resolved values
- See Also:
-
contains
Checks if this set contains the value with the given key.- Parameters:
valueKey
- the key to check- Returns:
- true if the value is in this set
-
iterator
-