List of utility methods to do UUID Create
String | generateUniqueString() generate Unique String String uniqueKey = UUID.randomUUID().toString(); return uniqueKey.replaceAll("-", ""); |
String | generateUniqueText() This method generates a unique string based on the current system date/time. Date date = new Date(); SimpleDateFormat UNIQUE_DATE_TIME_STRING_FORMAT = new SimpleDateFormat("yyyyMMddHHmmSS"); String dateTimeString = UNIQUE_DATE_TIME_STRING_FORMAT.format(date); return dateTimeString; |
String | generateUri() generate Uri return PREFIX + UUID.randomUUID().toString();
|
String | generateURN() Generates the URN string of "urn:st" namespace return "urn:st:" + UUID.randomUUID().toString(); |
String | generateUUID() UUID generator random return UUID.randomUUID().getLeastSignificantBits() + ""; |
String | generateUUID() generate UUID new UUID(new Random().nextLong(), new Random().nextLong()); UUID generatedUUID = UUID.randomUUID(); return generatedUUID.toString(); |
String | generateUUID() generate UUID return createSimpleDateFormat().format(new Date()) + "-" + new Random().nextInt(10000); |
String | generateUUID() Generates a random UUID used as a RequestID for SAML request. UUID uuid = UUID.randomUUID(); String strUUID = "a" + uuid.toString(); return strUUID; |
String | generateUUID() This method generates a unique ID (UUID - Universally unique identifier) UUID uuid = UUID.randomUUID();
return uuid.toString();
|
String | generateUUID() Returns a string of 16 HEX chars. UUID uuid = UUID.randomUUID();
return Long.toHexString(uuid.getMostSignificantBits());
|