Interface SkinManager


public interface SkinManager
Manages the retrieval and caching of player skins.

This manager handles fetching skin data from various sources (e.g., Mojang, SkinsRestorer) and provides a fallback skin when a profile cannot be resolved.

Since:
1.15.2
  • Method Summary

    Modifier and Type
    Method
    Description
    @NotNull CompletableFuture<? extends SkinData>
    Asynchronously completes an uncompleted model profile to retrieve its skin data.
    @NotNull SkinData
    Returns the fallback skin data used when a skin cannot be resolved.
    void
    removeCache(@NotNull ModelProfile profile)
    Removes a specific profile from the skin cache.
    boolean
    Checks if a skin provider (like SkinsRestorer) is supported and available.
  • Method Details

    • supported

      boolean supported()
      Checks if a skin provider (like SkinsRestorer) is supported and available.
      Returns:
      true if supported, false otherwise
      Since:
      1.15.2
    • fallback

      @NotNull @NotNull SkinData fallback()
      Returns the fallback skin data used when a skin cannot be resolved.
      Returns:
      the fallback skin data
      Since:
      1.15.2
    • complete

      @NotNull @NotNull CompletableFuture<? extends SkinData> complete(@NotNull ModelProfile.Uncompleted profile)
      Asynchronously completes an uncompleted model profile to retrieve its skin data.
      Parameters:
      profile - the uncompleted profile
      Returns:
      a future that completes with the skin data
      Since:
      1.15.2
    • removeCache

      void removeCache(@NotNull @NotNull ModelProfile profile)
      Removes a specific profile from the skin cache.
      Parameters:
      profile - the profile to remove
      Since:
      1.15.2