Interface IPlayerConfigManagerAPI


public interface IPlayerConfigManagerAPI
API for the player config manager on the server side
  • Method Details

    • getLoadedConfig

      @Nonnull IPlayerConfigAPI getLoadedConfig(@Nullable UUID id)
      Gets or creates the player config for the player with a specified UUID.

      Gets the wilderness config if the specified UUID is null, the server claims config if the UUID is PlayerConfig.SERVER_CLAIM_UUID, the expired claims config if the UUID is PlayerConfig.EXPIRED_CLAIM_UUID.

      Parameters:
      id - the UUID of the player, null for wilderness
      Returns:
      the player config instance, not null
    • getDefaultConfig

      @Nonnull IPlayerConfigAPI getDefaultConfig()
      Gets the default player config instance.
      Returns:
      the default player config instance, not null
    • getWildernessConfig

      @Nonnull IPlayerConfigAPI getWildernessConfig()
      Gets the wilderness config instance.
      Returns:
      the wilderness config instance, not null
    • getServerClaimConfig

      @Nonnull IPlayerConfigAPI getServerClaimConfig()
      Gets the server claims config instance.
      Returns:
      the server claims config instance, not null
    • getExpiredClaimConfig

      @Nonnull IPlayerConfigAPI getExpiredClaimConfig()
      Gets the expired claims config instance.
      Returns:
      the expired claims config instance, not null
    • getAllOptionsStream

      @Nonnull Stream<IPlayerConfigOptionSpecAPI<?>> getAllOptionsStream()
      Gets a stream of all player config option types, including the dynamic ones.
      Returns:
      a stream of all player config options, not null
    • getOptionForId

      @Nullable IPlayerConfigOptionSpecAPI<?> getOptionForId(@Nonnull String id)
      Gets the option type specification with a specified string option id, including dynamic options.

      Returns null if no such option exists.

      Parameters:
      id - the option id, not null
      Returns:
      the option type specification instance, null when doesn't exist