|
Sen API
Sen Libraries
|
Strong type for the unique identifier for a transport timer. More...
Classes | |
| class | Bootloader |
| Configures a kernel for running. More... | |
| class | Component |
| Base class for implementing sen kernel components. More... | |
| struct | ComponentMonitoringInfo |
| Monitoring information about components. More... | |
| struct | KernelMonitoringInfo |
| Kernel monitoring information. More... | |
| class | KernelApi |
| User-facing kernel functions. More... | |
| class | ConfigGetter |
| Allows for fetching configuration parameters. More... | |
| class | RegistrationApi |
| API for objects when registered. More... | |
| class | PreloadApi |
| What can be done when preloading a component. More... | |
| class | LoadApi |
| What can be done when loading a component. More... | |
| class | InitApi |
| What can be done when initializing a component. More... | |
| class | RunApi |
| What can be done while a component is running. More... | |
| class | UnloadApi |
| What can be done when unloading a component. More... | |
| class | Kernel |
| Main entry point of a sen microkernel. More... | |
| struct | ComponentContext |
| Holds a component instance and basic info. More... | |
| class | KernelConfig |
| Holds the kernel configuration information. More... | |
| class | PackageManager |
| Utility class for loading types from Sen packages. More... | |
| class | SourceInfo |
| Provides information about sources as strings. More... | |
| class | SessionInfoProvider |
| class | SessionsDiscoverer |
| class | TestKernel |
| Kernel class only meant for unit testing your packages or components. It starts in virtual time mode. More... | |
| class | TestComponent |
| Convenience class for using lambdas instead of inheritance when defining test components. More... | |
| class | Tracer |
| Interface implemented by tracers. You can use it to trace the behavior of your code. Please note that not all tracers support the functions below. More... | |
| struct | BusId |
| struct | ParticipantAddr |
| To identify remote participants. More... | |
| class | UniqueByteBufferManager |
| class | TransportListener |
| Interface for the internal Sen element that reacts to transport events. More... | |
| struct | TransportStats |
| Global transport statistics. More... | |
| class | Transport |
| Interface for implementing a Sen inter-process transport solution. More... | |
Typedefs | |
| using | FuncResult = Result<void, ExecError> |
| The result of operations that are called once. | |
| using | PassResult = Result<OpState, ExecError> |
| The result of operations that may be called multiple times. | |
| using | TracerFactory = std::function<std::unique_ptr<Tracer>(std::string_view)> |
| A factory function for tracers. | |
| using | BestEffortBlockPtr = std::shared_ptr<FixedMemoryBlock> |
| Pointer to a memory block of fixed size, used for best effort communication. | |
| using | ReliableBlockPtr = std::shared_ptr<ResizableHeapBlock> |
| Pointer to a resizable memory block, used for reliable communication. | |
| using | BestEffortBufferList = std::vector<BestEffortBlockPtr> |
| A list (vector) of fixed-size memory blocks. | |
| using | TransportFactory = std::function<std::unique_ptr<Transport>(const std::string&, std::unique_ptr<Tracer> tracer)> |
| A function that creates a transport given a session name. | |
Enumerations | |
| enum class | KernelBlockMode { doNotBlock , doBlock } |
| How to deal with the thread that calls the Kernel::run() function. More... | |
Functions | |
| VarMap | getConfigAsVarFromYaml (const std::filesystem::path &path, bool printFinalConfig=false) |
| Loads a configuration YAML file and returns its contents as a sen::VarMap. This function does not validate the correctness of the configuration, but simply translates the contents into the Var. It resolves included yamls. | |
| VarMap | getConfigAsVarFromYaml (const std::string &content, const std::filesystem::path &path, bool printFinalConfig=false) |
| Loads a configuration YAML file and returns its contents as a sen::VarMap. This function does not validate the correctness of the configuration, but simply translates the contents into the Var. It resolves included yamls. If the "path" argument is not correct, it will not resolve the inclusions. | |
| PassResult | done () |
| Convenience helper for doing sen::Ok(sen::kernel::OpState {sen::kernel::OpFinished {}}). | |
| constexpr bool | getDebugEnabled () noexcept |
| constexpr WordSize | getWordSize () noexcept |
| constexpr const char * | getGitRef () noexcept |
| constexpr const char * | getGitHash () noexcept |
| GitStatus | getGitStatus () noexcept |
| TracerFactory | getDefaultTracerFactory () |
| A function that returns a no-op tracer. | |
| bool | operator== (const ParticipantAddr &lhs, const ParticipantAddr &rhs) noexcept |
| bool | operator!= (const ParticipantAddr &lhs, const ParticipantAddr &rhs) noexcept |
| uint32_t | getKernelProtocolVersion () noexcept |
| The protocol version of kernel messaging. | |
| CustomTypeSpec | makeCustomTypeSpec (const CustomType *type) |
| Implementation detail for the kernel. | |
| bool | equivalent (const Type *localType, const Type *remoteType) |
| Checks if two meta types are equivalent (same hash). | |
| ConstTypeHandle< CustomType > | buildNonNativeType (const CustomTypeSpec &remoteType, const CustomTypeRegistry &nativeTypes, const CustomTypeRegistry &nonNativeTypes) |
| Implementation detail for the kernel. | |
| std::vector< std::string > | getRuntimeDifferences (const Type *localType, const Type *remoteType) |
| Detects which differences cause. | |
| std::vector< std::string > | runtimeCompatible (const Type *localType, const Type *remoteType) |
| Checks if two types are runtime-compatible and returns the error string in case they are not. | |
| CustomTypeSpec | toCurrentVersion (const CustomTypeSpecV4 &v4) |
| Translates a CustomTypeSpec from V4 to the current version (V6) of the kernel protocol. | |
| CustomTypeSpec | toCurrentVersion (const CustomTypeSpecV5 &v5) |
| Translates a CustomTypeSpec from V5 to the current version (V6) of the kernel protocol. | |
| ProcessInfo | getOwnProcessInfo (std::string_view sessionName) |
| Utility function to fetch our process info. | |
| uint32_t | getHostId () |
| Utility function to fetch our host ID. | |
| uint32_t | getUniqueSenProcessId () |
| Utility function to fetch our process ID. | |
Variables | |
| constexpr auto * | componentMakerFuncName = SEN_STRINGIFY(SEN_COMPONENT_MAKER) |
| constexpr auto * | componentInfoMakerFuncName = SEN_STRINGIFY(SEN_COMPONENT_INFO_MAKER) |
| constexpr std::size_t | maxBestEffortMessageSize = 65527U |
| The maximum UDP payload size. | |
Strong type for the unique identifier for a transport timer.
| struct sen::kernel::ComponentMonitoringInfo |
Monitoring information about components.
| Class Members | ||
|---|---|---|
| ComponentInfo | info | |
| ComponentConfig | config | |
| bool | requiresRealTime = false | |
| optional< Duration > | cycleTime | |
| size_t | objectCount = 0 | |
| struct sen::kernel::KernelMonitoringInfo |
Kernel monitoring information.
| Class Members | ||
|---|---|---|
| RunMode | runMode = RunMode::realTime | |
| TransportStats | transportStats {} | |
| vector< ComponentMonitoringInfo > | components | |
| using sen::kernel::FuncResult = Result<void, ExecError> |
The result of operations that are called once.
| using sen::kernel::PassResult = Result<OpState, ExecError> |
The result of operations that may be called multiple times.
| using sen::kernel::TracerFactory = std::function<std::unique_ptr<Tracer>(std::string_view)> |
A factory function for tracers.
|
strong |
How to deal with the thread that calls the Kernel::run() function.
| Enumerator | |
|---|---|
| doNotBlock | Does not block the caller thread. |
| doBlock | Blocks the caller thread. |
|
inlinenodiscard |
Convenience helper for doing sen::Ok(sen::kernel::OpState {sen::kernel::OpFinished {}}).
|
nodiscardconstexprnoexcept |
|
nodiscardconstexprnoexcept |
|
nodiscardconstexprnoexcept |
|
nodiscardconstexprnoexcept |
|
inlinenodiscardnoexcept |
|
nodiscard |
A function that returns a no-op tracer.
| ProcessInfo sen::kernel::getOwnProcessInfo | ( | std::string_view | sessionName | ) |
Utility function to fetch our process info.
|
nodiscard |
Utility function to fetch our host ID.
|
nodiscard |
Utility function to fetch our process ID.
|
constexpr |
|
constexpr |