Class UUIDs


  • public class UUIDs
    extends java.lang.Object
    Utilities for manipulating a universally unique identifier (UUID).
    Author:
    Garret Wilson
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String UUID_URN_NAMESPACE
      The UUID URN namespace identifier "uuid".
    • Constructor Summary

      Constructors 
      Constructor Description
      UUIDs()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.String toHexString​(java.util.UUID uuid)
      Constructs a string of hexadecimal characters equivalent to the return value of UUID.toString() with all non-digits removed.
      static java.net.URI toURI​(java.util.UUID uuid)
      Creates a URI from the UUID in the form urn:uuid:uuid.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • UUID_URN_NAMESPACE

        public static final java.lang.String UUID_URN_NAMESPACE
        The UUID URN namespace identifier "uuid".
        See Also:
        Constant Field Values
    • Constructor Detail

      • UUIDs

        public UUIDs()
    • Method Detail

      • toHexString

        public static java.lang.String toHexString​(java.util.UUID uuid)
        Constructs a string of hexadecimal characters equivalent to the return value of UUID.toString() with all non-digits removed.
        Parameters:
        uuid - The UUID from which to construct a hex string.
        Returns:
        A pure hex string representing the UUID.