Class UUIDGenerator

  • All Implemented Interfaces:
    ValueGenerator<java.lang.String>

    public class UUIDGenerator
    extends AbstractGenerator<java.lang.String>
    Value generator for a String utilising the JDK UUID class (128-bit, 36 character). Results in Strings of length 36 characters, like "2cdb8cee-9134-453f-9d7a-14c0ae8184c6".
    • Constructor Detail

      • UUIDGenerator

        public UUIDGenerator​(StoreManager storeMgr,
                             java.lang.String name)
        Constructor.
        Parameters:
        storeMgr - StoreManager
        name - Symbolic name for this generator
    • Method Detail

      • getStorageClass

        public static java.lang.Class getStorageClass()
        Accessor for the storage class for values generated with this generator.
        Returns:
        Storage class (in this case String.class)
      • reserveBlock

        protected ValueGenerationBlock<java.lang.String> reserveBlock​(long size)
        Method to reserve "size" values to the block.
        Specified by:
        reserveBlock in class AbstractGenerator<java.lang.String>
        Parameters:
        size - The block size
        Returns:
        The reserved block