|
Libmagicxx v10.0.3
A modern C++23 wrapper for libmagic — the library that powers the Unix file command.
|
Main header file for the libmagicxx library. More...
#include <bitset>#include <expected>#include <map>#include <memory>#include <optional>#include <string_view>#include <vector>#include "magic_exception.hpp"#include "progress_tracker.hpp"#include "utility.hpp"

Go to the source code of this file.
Classes | |
| class | Recognition::Magic |
| A modern C++23 wrapper for libmagic — the library that powers the Unix file command. More... | |
Namespaces | |
| namespace | Recognition |
| Root namespace for the libmagicxx library. | |
Functions | |
| std::string | Recognition::ToString (const Magic::FileTypeEntryT &file_type_entry, const std::string &type_separator=" -> ") |
| Convert a file type entry to a string. | |
| std::string | Recognition::ToString (const Magic::FileTypeMapT &file_type_map, const std::string &type_separator=" -> ", const std::string &file_separator="\n") |
| Convert a file type map to a string. | |
| std::string | Recognition::ToString (const Magic::ExpectedFileTypeT &expected_file_type) |
| Convert an expected file type result to a string. | |
| std::string | Recognition::ToString (const Magic::ExpectedFileTypeEntryT &expected_file_type_entry, const std::string &type_separator=" -> ") |
| Convert an expected file type entry to a string. | |
| std::string | Recognition::ToString (const Magic::ExpectedFileTypeMapT &expected_file_type_map, const std::string &type_separator=" -> ", const std::string &file_separator="\n") |
| Convert an expected file type map to a string. | |
| std::string | Recognition::ToString (Magic::Flags flag) |
| Convert a Magic flag to its string name. | |
| std::string | Recognition::ToString (const Magic::FlagsContainerT &flags, const std::string &separator=", ") |
| Convert a container of flags to a string. | |
| std::string | Recognition::ToString (Magic::Parameters parameter) |
| Convert a Magic parameter to its string name. | |
| std::string | Recognition::ToString (const Magic::ParameterValueT ¶meter_value, const std::string &value_separator=": ") |
| Convert a parameter-value pair to a string. | |
| std::string | Recognition::ToString (const Magic::ParameterValueMapT ¶meters, const std::string &value_separator=": ", const std::string ¶meter_separator=", ") |
| Convert a parameter-value map to a string. | |
Main header file for the libmagicxx library.
This file contains the Magic class, a modern C++23 wrapper for libmagic — the library that powers the Unix file command. It provides type-safe, RAII-based file type identification based on content rather than file extensions.