Class UlidFactory

    • Constructor Detail

      • UlidFactory

        public UlidFactory()
    • Method Detail

      • create

        public Ulid create()
        Returns a UUID.
        Returns:
        a ULID
      • create

        public abstract Ulid create​(long time)
        Returns a UUID with a specific time. This method must be implemented by all subclasses.
        Parameters:
        time - a specific time
        Returns:
        a ULID
      • withRandomGenerator

        public <T extends UlidFactory> T withRandomGenerator​(RandomGenerator randomGenerator)
        Replaces the default random generator with another. The default random generator uses SecureRandom. See Random.
        Type Parameters:
        T - the type parameter
        Parameters:
        randomGenerator - a random generator
        Returns:
        UlidFactory