Class PlayerChatBucket

java.lang.Object
games.stendhal.server.entity.player.PlayerChatBucket
Direct Known Subclasses:
AdminChatBucket

public class PlayerChatBucket extends Object
a bucket to manage chat traffic shaping.
Author:
hendrik
  • Constructor Details

    • PlayerChatBucket

      public PlayerChatBucket()
  • Method Details

    • checkAndAdd

      public boolean checkAndAdd(int length)
      checks that the bucket is not full, yet and adds the turn in case there is still room.
      Parameters:
      length - length of chat message
      Returns:
      true if the bucket is not full, yet; false otherwise.