Blender
V3.3
|
Go to the source code of this file.
Functions | |
bUUID | BLI_uuid_generate_random (void) |
bUUID | BLI_uuid_nil (void) |
bool | BLI_uuid_is_nil (bUUID uuid) |
bool | BLI_uuid_equal (bUUID uuid1, bUUID uuid2) |
void | BLI_uuid_format (char *buffer, bUUID uuid) ATTR_NONNULL() |
bool | BLI_uuid_parse_string (bUUID *uuid, const char *buffer) ATTR_NONNULL() |
Functions for generating and handling UUID structs according to RFC4122.
Note that these are true UUIDs, not to be confused with the "session uuid" defined in BLI_session_uuid.h
.
Definition in file BLI_uuid.h.
Compare two UUIDs, return true only if they are equal.
Definition at line 81 of file uuid.cc.
Referenced by BLI_uuid_is_nil(), file_set_asset_catalog_filter_settings(), blender::operator==(), and blender::bke::tests::TEST().
Format UUID as string. The buffer must be at least 37 bytes (36 bytes for the UUID + terminating 0). Use UUID_STRING_LEN
from DNA_uuid_types.h if you want to use a constant for this.
Definition at line 86 of file uuid.cc.
References buffer, bUUID::clock_seq_hi_and_reserved, bUUID::clock_seq_low, bUUID::node, bUUID::time_hi_and_version, bUUID::time_low, and bUUID::time_mid.
Referenced by blender::ed::asset::index::AssetEntryWriter::add_catalog_id(), blender::ed::asset_browser::AssetCatalogTreeViewItem::build_context_menu(), operator<<(), and blender::tests::TEST().
UUID generator for random (version 4) UUIDs. See RFC4122 section 4.4. This function is not thread-safe.
Definition at line 21 of file uuid.cc.
References bUUID::clock_seq_hi_and_reserved, max, min, seed, and bUUID::time_hi_and_version.
Referenced by blender::bke::AssetCatalog::from_path(), blender::bke::tests::TEST(), blender::tests::TEST(), and blender::bke::tests::TEST_F().
Return true only if this is the nil UUID.
Definition at line 76 of file uuid.cc.
References BLI_uuid_equal(), and BLI_uuid_nil().
Referenced by blender::bke::AssetCatalogTree::insert_item(), blender::bke::AssetCatalogFilter::is_known(), blender::bke::AssetLibrary::refresh_catalog_simplename(), blender::bke::tests::TEST(), blender::tests::TEST(), and blender::bke::tests::TEST_F().
Return the UUID nil value, consisting of all-zero fields.
Definition at line 70 of file uuid.cc.
Referenced by BKE_asset_metadata_catalog_id_clear(), BLI_uuid_is_nil(), blender::tests::TEST(), and blender::bke::tests::TEST_F().
Parse a string as UUID. The string MUST be in the format xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
, as produced by BLI_uuid_format().
Return true if the string could be parsed, and false otherwise. In the latter case, the UUID may have been partially updated.
Definition at line 103 of file uuid.cc.
References buffer, bUUID::clock_seq_hi_and_reserved, bUUID::clock_seq_low, bUUID::node, bUUID::time_hi_and_version, bUUID::time_low, and bUUID::time_mid.
Referenced by asset_catalog_delete_exec(), blender::bke::AssetCatalogDefinitionFile::parse_catalog_line(), and blender::tests::TEST().