/** * Copyright (c): Uwe Schmidt, FH Wedel * * You may study, modify and distribute this source code * FOR NON-COMMERCIAL PURPOSES ONLY. * This copyright message has to remain unchanged. * * Note that this document is provided 'as is', * WITHOUT WARRANTY of any kind either expressed or implied. */ /** * * f(i) = i * * --> 0 1 2 3 4 5 ... */ //-------------------- public class Count extends Sequence { private long cnt; public Count() { this(0); } public Count(long start) { cnt = start; } public long next() { return cnt++; } } //--------------------