actf 0.0.1
An acute CTF reader
Loading...
Searching...
No Matches
/home/adwe/code/actf/mappings.h
Go to the documentation of this file.
1/*
2 * This file is a part of ACTF.
3 *
4 * Copyright (C) 2024 Adam Wendelin <adwe live se>
5 *
6 * ACTF is free software: you can redistribute it and/or modify it
7 * under the terms of the GNU Lesser General Public License as
8 * published by the Free Software Foundation, either version 3 of the
9 * License, or (at your option) any later version.
10 *
11 * ACTF is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General
14 * Public License for more details.
15 *
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with ACTF. If not, see
18 * <https://www.gnu.org/licenses/>.
19 */
20
25#ifndef ACTF_MAPPINGS_H
26#define ACTF_MAPPINGS_H
27
28#include <stddef.h>
29#include <stdint.h>
30
31#include "types.h"
32
35
41size_t actf_mappings_len(const actf_mappings *maps);
42
56const char *actf_mappings_find_uint(const actf_mappings *maps, uint64_t val, actf_it *it);
57
68const char *actf_mappings_find_first_uint(const actf_mappings *maps, uint64_t val);
69
71const char *actf_mappings_find_sint(const actf_mappings *maps, int64_t val, actf_it *it);
72
74const char *actf_mappings_find_first_sint(const actf_mappings *maps, int64_t val);
75
76#endif /* ACTF_MAPPINGS_H */
const char * actf_mappings_find_uint(const actf_mappings *maps, uint64_t val, actf_it *it)
Find the next name matching the provided value.
const char * actf_mappings_find_first_uint(const actf_mappings *maps, uint64_t val)
Find the first name matching the provided value.
size_t actf_mappings_len(const actf_mappings *maps)
Get the number of mappings.
struct actf_mappings actf_mappings
Mappings map names to integer range sets.
Definition mappings.h:34
const char * actf_mappings_find_first_sint(const actf_mappings *maps, int64_t val)
const char * actf_mappings_find_sint(const actf_mappings *maps, int64_t val, actf_it *it)
An iterator.
Definition types.h:136
Basic types used by ACTF.