package ai1.serverjava.session; import java.io.Serializable; /** * Calculates the sum of a serie of ints. */ public class CounterBean implements Serializable { private int sum = 0; /** * Adds the given value to the sum. The somehow strange name * setAdd is used to conform to the JavaBeans specification. * * @param value The value that is added to the sum. */ public void setAdd(int value) { sum += value; } /** * Returns the sum. * * @return The sum. */ public int getSum() { return sum; } }