f4b6a3 / uuid-creator

UUID Creator is a Java library for generating Universally Unique Identifiers.
MIT License
431 stars 44 forks source link

uuid-ncname-58 #104

Closed blop closed 4 weeks ago

blop commented 1 month ago

Hello,

According to https://datatracker.ietf.org/doc/html/draft-taylor-uuid-ncname#name-encoding-algorithm, there is a uuid-ncname-58 that is forseen. Will it be supported by this library also ?

Thank you! Regards,

Olivier

fabiolimace commented 1 month ago

Hello @blop !

For now, I'm not planning to add support for ncname-58.

However, if you only need a base-58 encoding, you can use Base58BtdCodec:

Base58BtcCodec codec = new Base58BtcCodec();
System.out.println(codec.encode(UUID.randomUUID()));
System.out.println(codec.encode(UUID.randomUUID()));
System.out.println(codec.encode(UUID.randomUUID()));
RErkpFw5zFXPMbA8LuJRBJ
2Lpf9CqQt7fKfz9P3hrjnS
EWP984vucSkhfUGJPNSutN