Interface Counter

All Known Implementing Classes:
NoopCounter

public interface Counter
A mutable number.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Decrement this by 1.
    void
    decrement(long n)
    Decrement this by n.
    void
    Increment this by 1.
    void
    increment(long n)
    Increment this by n.
  • Method Details

    • increment

      void increment()
      Increment this by 1.
    • increment

      void increment(long n)
      Increment this by n.
      Parameters:
      n - The amount to increment.
    • decrement

      void decrement()
      Decrement this by 1.
    • decrement

      void decrement(long n)
      Decrement this by n.
      Parameters:
      n - The amount to decrement.