8#ifndef SEN_KERNEL_KERNEL_H
9#define SEN_KERNEL_KERNEL_H
20#include "stl/sen/kernel/basic_types.stl.h"
21#include "stl/sen/kernel/network_footprint.stl.h"
85 std::unique_ptr<impl::KernelImpl> pimpl_;
114bool arm(
const std::filesystem::path& reportDirectory = {});
Here we define a set of template meta-programming helpers to let the compiler take some decisions bas...
Contiguous view of elements of type T. Inspired by http://www.open-std.org/jtc1/sc22/wg21/docs/papers...
Definition span.h:34
Holds the kernel configuration information.
Definition kernel_config.h:33
static const BuildInfo & getBuildInfo() noexcept
Gets the kernel build information.
friend class KernelApi
Definition kernel.h:78
const KernelConfig & getConfig() const noexcept
Gets the configuration used to construct the kernel. This method is thread-safe.
Kernel(KernelConfig config)
int run(KernelBlockMode blockMode=KernelBlockMode::doBlock)
Fire up the execution of the kernel. In case the is already running, -1 is returned....
friend class PreloadApi
Definition kernel.h:79
friend class impl::Runner
Definition kernel.h:81
void requestStop(int exitCode=0)
Stops the execution and deallocates runtime resources. This method is thread-safe.
std::filesystem::path getConfigPath() const noexcept
Gets the path to the configuration file used to construct the kernel. This method is thread-safe.
friend class TestKernel
Definition kernel.h:82
NetworkFootprint getNetworkFootprint(Span< const BusAddress > suppliedBusAddresses)
Builds the process network footprint after preloading the configured components.
friend class UnloadApi
Definition kernel.h:80
Kernel class only meant for unit testing your packages or components. It starts in virtual time mode.
Definition test_kernel.h:27
Crash reporting, which belongs to the process rather than to any one kernel: a process has one crash ...
Definition kernel.h:91
std::optional< int > runHandlerIfRequested(int argc, char *argv[])
Give main() its own arguments here, before anything else, and leave with the value it returns when it...
bool arm(const std::filesystem::path &reportDirectory={})
Turns on crash reporting for this process: a terminate handler for an uncaught exception,...
Strong type for the unique identifier for a transport timer.
Definition native_object_impl.h:39
KernelBlockMode
How to deal with the thread that calls the Kernel::run() function.
Definition kernel.h:36
@ doNotBlock
Does not block the caller thread.
Definition kernel.h:37
@ doBlock
Blocks the caller thread.
Definition kernel.h:38