package api.account;

import org.jetbrains.annotations.NotNull;
import api.ExecuteResult;

/**
 * Версия 5 интерфейса. Позволяет узнать максимально разрешённое число игроков на шарде и установить новое значение этого лимита.
 * @author andrey.kuprishov
 */
public interface AccountAPIInterface5 extends AccountAPIInterface4 {
  /**
   * Gets limit of max connected users for shard, or -1 if shard not found.
   */
  int getMaxUsersOnShard(@NotNull String shardName);

  /**
   * Sets new limit for max connected users to shard.
   * @return  result that can be succeeded or failed (due to shard not found, too big limit or too small limit etc.)
   */
  @NotNull
  ExecuteResult setMaxUsersOnShard(@NotNull String shardName, int newLimit);
}