diff options
| author | Paul Buetow <paul@buetow.org> | 2008-05-25 08:10:13 +0000 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2008-05-25 08:10:13 +0000 |
| commit | c015d586d22b69078b6da61858e5675793856b0b (patch) | |
| tree | efbc9881cf59363abef52a0beb5eedf9e81a224a /sources/utils/VSRandom.java | |
| parent | 62fe28f0b0b0c9ebde18a6dc33907889ff3aa21b (diff) | |
JAutoDoc :)
Diffstat (limited to 'sources/utils/VSRandom.java')
| -rw-r--r-- | sources/utils/VSRandom.java | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/sources/utils/VSRandom.java b/sources/utils/VSRandom.java index 4f23e7e..088da4f 100644 --- a/sources/utils/VSRandom.java +++ b/sources/utils/VSRandom.java @@ -1,16 +1,40 @@ +/* + * VS is (c) 2008 by Paul C. Buetow + * vs@dev.buetow.org + */ package utils; import java.util.Random; +// TODO: Auto-generated Javadoc +/** + * The Class VSRandom. + */ public final class VSRandom extends Random { + + /** + * Instantiates a new vS random. + * + * @param seedAdd the seed add + */ public VSRandom(long seedAdd) { super(seedAdd*System.currentTimeMillis()+seedAdd); } + /* (non-Javadoc) + * @see java.util.Random#nextInt() + */ public int nextInt() { return Math.abs(super.nextInt()); } + /** + * Next long. + * + * @param mod the mod + * + * @return the long + */ public long nextLong(long mod) { return Math.abs((super.nextLong() + System.currentTimeMillis()) % mod); } |
