Update message to inform user that UUID is not Time-Based (Version 1).

This commit is contained in:
Igor Kulikov 2017-10-10 12:32:22 +03:00
parent e6a46c788d
commit 3ca943ee86

View File

@ -31,7 +31,7 @@ public class UUIDConverter {
public static String fromTimeUUID(UUID src) { public static String fromTimeUUID(UUID src) {
if (src.version() != 1) { if (src.version() != 1) {
throw new IllegalArgumentException("Not a time UUID!"); throw new IllegalArgumentException("Only Time-Based UUID (Version 1) is supported!");
} }
String str = src.toString(); String str = src.toString();
// 58e0a7d7-eebc-11d8-9669-0800200c9a66 => 1d8eebc58e0a7d796690800200c9a66. Note that [11d8] -> [1d8] // 58e0a7d7-eebc-11d8-9669-0800200c9a66 => 1d8eebc58e0a7d796690800200c9a66. Note that [11d8] -> [1d8]