Metall
v0.29
A persistent memory allocator for data-centric analytics
logger.cpp
This is an example of how to use Metall's logger.
// Copyright 2023 Lawrence Livermore National Security, LLC and other Metall
// Project Developers. See the top-level COPYRIGHT file for details.
//
// SPDX-License-Identifier: (Apache-2.0 OR MIT)
#include <
metall/metall.hpp
>
int
main
() {
// Set the log level to , for example, verbose.
// The log level can be changed at any time.
metall::logger::set_log_level
(
metall::logger::level_filter::verbose
);
// Enable the program to abort when a critical log message is displayed.
metall::logger::abort_on_critical_error
(
true
);
// Do Metall operations
metall::manager
manager
(metall::create_only,
"/tmp/dir"
);
return
0;
}
metall::basic_manager
A generalized Metall manager class.
Definition:
basic_manager.hpp:40
metall::logger::set_log_level
static void set_log_level(const level_filter lvl) noexcept
Set the minimum logger level to show message.
Definition:
logger.hpp:94
metall::logger::abort_on_critical_error
static bool abort_on_critical_error() noexcept
Definition:
logger.hpp:99
main
int main()
Definition:
jgraph.cpp:24
metall.hpp
metall::manager
basic_manager<> manager
Default Metall manager class which is an alias of basic_manager with the default template parameters.
Definition:
metall.hpp:34
metall::logger::level_filter::verbose
static const level_filter verbose
Log all messages.
Definition:
logger.hpp:78
Generated by
1.9.1