From 2660725d7a45996cfefe65274ad6498ec01f460b Mon Sep 17 00:00:00 2001 From: Cobollatin Date: Fri, 29 Nov 2024 21:57:44 +0100 Subject: [PATCH] format --- include/faker-cxx/string.h | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/include/faker-cxx/string.h b/include/faker-cxx/string.h index 858d134b..9636c380 100644 --- a/include/faker-cxx/string.h +++ b/include/faker-cxx/string.h @@ -7,8 +7,8 @@ #include #include #include -#include #include +#include #include #include @@ -75,12 +75,15 @@ template std::string uuidV1(RandomGenerator gen = RandomGenerator{}) { // Get current timestamp in 100-nanosecond intervals since UUID epoch (15 Oct 1582) - const uint64_t UUID_EPOCH_OFFSET = 0x01B21DD213814000ULL; // Number of 100-ns intervals between UUID epoch and Unix epoch + const uint64_t UUID_EPOCH_OFFSET = + 0x01B21DD213814000ULL; // Number of 100-ns intervals between UUID epoch and Unix epoch auto now = std::chrono::system_clock::now(); auto since_epoch = now.time_since_epoch(); // Adjusted to use microseconds - uint64_t timestamp = UUID_EPOCH_OFFSET + static_cast(std::chrono::duration_cast(since_epoch).count() * 10); + uint64_t timestamp = + UUID_EPOCH_OFFSET + + static_cast(std::chrono::duration_cast(since_epoch).count() * 10); // Generate clock sequence (14 bits) std::uniform_int_distribution clock_seq_dist(0, 0x3FFF); @@ -214,8 +217,6 @@ std::string uuid(Uuid uuid = Uuid::V4, RandomGenerator gen = RandomGenerator< } } - - /** * @brief Generates an Universally Unique Lexicographically Sortable Identifier. *