Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add null UUID definition to use for comparing #128

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions base/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ set(BASE_SOURCES
thread.cpp
thread_pool.cpp
time.cpp
uuid.cpp
version.cpp)

if(WIN32)
Expand Down
13 changes: 13 additions & 0 deletions base/uuid.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
// LAF Base Library
// Copyright (c) 2025 Igara Studio S.A.
//
// This file is released under the terms of the MIT license.
// Read LICENSE.txt for more information.

#include "base/uuid.h"

namespace base {

const Uuid Uuid::Null;

} // namespace base
5 changes: 4 additions & 1 deletion base/uuid.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// LAF Base Library
// Copyright (c) 2023 Igara Studio S.A.
// Copyright (c) 2023-2025 Igara Studio S.A.
//
// This file is released under the terms of the MIT license.
// Read LICENSE.txt for more information.
Expand All @@ -25,6 +25,9 @@ namespace base {
// A universally unique identifier.
class Uuid {
public:
// Null UUID
static const Uuid Null;

enum { HashSize = 36 };

static Uuid Generate();
Expand Down
Loading