Generates ID 's at random.
The random number source is java.util.Random .
Random ID 's are very useful if you're inserting
elements created by Betwixt into a stream with existing
elements.
Using random ID 's should reduce the danger of collision
with existing element ID 's.
This class can generate positive-only ids (the default)
or it can generate a mix of negative and postive ones.
This behaviour can be set by
RandomIDGenerator.setPositiveIds
or by using the
RandomIDGenerator.RandomIDGenerator(boolean onlyPositiveIds)
constructor.
author: Robert Burrell Donkin version: $Revision: 438373 $ |