uuid4.h 438 B

1234567891011121314151617181920212223242526
  1. /**
  2. * Copyright (c) 2018 rxi
  3. *
  4. * This library is free software; you can redistribute it and/or modify it
  5. * under the terms of the MIT license. See LICENSE for details.
  6. */
  7. #ifndef UUID4_H
  8. #define UUID4_H
  9. #define UUID4_VERSION "1.0.0"
  10. #define UUID4_LEN 33
  11. #include <string>
  12. enum {
  13. UUID4_ESUCCESS = 0,
  14. UUID4_EFAILURE = -1
  15. };
  16. int uuid4_init(void);
  17. void uuid4_generate(char *dst);
  18. std::string uuid4_generate(int len);
  19. #endif