# Class Sorter.Counter

public class Counter
extends Object

A general purpose counter class.

##

count
  The stored count
delta
  The amount the count is incremented by every update()

##

Counter (int)
  The constructor for the class

##

clear ()
  Clears the stored count
getCount ()
  Accessor method for the stored count
setDelta (int)
  Accessor method for the increment value
update ()
  Increments the internal count by delta

##

count

    private int count = 0

  The stored count.

delta

    private int delta = 0

  The amount the count is incremented by every update().

##

Counter

    public  Counter(int delta)

  The constructor for the class.

  Parameters:
    delta - The amount to increment the counter by every time the counter is updated.

##

update

    public void update()

  Increments the internal count by delta.

clear

    public void clear()

  Clears the stored count.

setDelta

    public void setDelta(int delta)

  Accessor method for the increment value.

  Parameters:
    delta -

getCount

    public int getCount()

  Accessor method for the stored count.

  Returns: