Interface RateControl

All Known Implementing Classes:
WindowRateControl

public interface RateControl
Controls rate of events via onEvent(Object).
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
    Factory to create RateControl instances.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final RateControl
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    onEvent(Object event)
    Applications should call this method when they want to signal an event that is subject to rate control.
  • Field Details

    • NO_RATE_CONTROL

      static final RateControl NO_RATE_CONTROL
  • Method Details

    • onEvent

      boolean onEvent(Object event)

      Applications should call this method when they want to signal an event that is subject to rate control.

      Implementations should return true if the event does not exceed the desired rate, or false to signal that the event exceeded the desired rate.

      Parameters:
      event - the event subject to rate control.
      Returns:
      true IFF the rate is within limits