Go to the source code of this file.
Classes | |
| struct | gid_metadata |
Macros | |
| #define | UINT32_WIDTH 32 |
| #define | gid_size_to_words(size) |
Functions | |
| void | gid_init (struct gid_metadata *const metadata) |
| uint32_t | gid_alloc (struct gid_metadata *const metadata) |
| void | gid_free (struct gid_metadata *const metadata, uint32_t id) |
| bool | gid_check (struct gid_metadata *metadata, uint32_t id) |
Globally unique Identifer facility header
See common/gid.c for discussion
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
| #define gid_size_to_words | ( | size | ) |
convert the maximum number of gids into a number of words needed to store the bitmap
| uint32_t gid_alloc | ( | struct gid_metadata *const | metadata | ) |
Allocates a gid from the gid structure and returns it.
| [in] | metadata | The gid_metadata to record to the gid structure |
| bool gid_check | ( | struct gid_metadata * | metadata, |
| uint32_t | id ) |
Checks if the gid specified is allocated.
| [in] | metadata | The gid_metadata to check |
| id | The gid value indicating the metadata's position in the gid structure |
| void gid_free | ( | struct gid_metadata *const | metadata, |
| uint32_t | id ) |
Frees the gid specified from the structure.
| [in] | metadata | The gid_metadata to free from the gid structure |
| id | The gid value indicating the metadata's position in the gid structure |
| void gid_init | ( | struct gid_metadata *const | metadata | ) |
Initializes a gid_metadata structure by "freeing" all IDs in the bitmap
| [in] | metadata | The gid_metadata structure to initialize |