Package net.kyori.adventure.pointer
Interface Pointered
- All Known Subinterfaces:
 Audience,ForwardingAudience,ForwardingAudience.Single
public interface Pointered
Something that can retrieve values based on a given 
Pointer.- Since:
 - 4.8.0
 
- 
Method Summary
Modifier and TypeMethodDescriptiondefault <T> @NotNull Optional<T>Gets the value ofpointer.default <T> TgetOrDefault(@NotNull Pointer<T> pointer, T defaultValue) Gets the value ofpointer.default <T> @UnknownNullability TgetOrDefaultFrom(@NotNull Pointer<T> pointer, @NotNull Supplier<? extends T> defaultValue) Gets the value ofpointer.default @NotNull Pointerspointers()Gets the pointers for this object. 
- 
Method Details
- 
get
Gets the value ofpointer.- Type Parameters:
 T- the type- Parameters:
 pointer- the pointer- Returns:
 - the value
 - Since:
 - 4.8.0
 
 - 
getOrDefault
@Contract("_, null -> _; _, !null -> !null") @Nullable default <T> T getOrDefault(@NotNull @NotNull Pointer<T> pointer, @Nullable T defaultValue) Gets the value ofpointer.If this
Audienceis unable to provide a value forpointer,defaultValuewill be returned.- Type Parameters:
 T- the type- Parameters:
 pointer- the pointerdefaultValue- the default value- Returns:
 - the value
 - Since:
 - 4.8.0
 
 - 
getOrDefaultFrom
default <T> @UnknownNullability T getOrDefaultFrom(@NotNull @NotNull Pointer<T> pointer, @NotNull @NotNull Supplier<? extends T> defaultValue) Gets the value ofpointer.If this
Audienceis unable to provide a value forpointer, the value supplied bydefaultValuewill be returned.- Type Parameters:
 T- the type- Parameters:
 pointer- the pointerdefaultValue- the default value supplier- Returns:
 - the value
 - Since:
 - 4.8.0
 
 - 
pointers
Gets the pointers for this object.- Returns:
 - the pointers
 - Since:
 - 4.8.0
 
 
 -