Woman, Life, Freedom


Adaptive AUTOSAR
ARA public interface header documentation
operation_cycle.h
1#ifndef OPERATION_CYCLE_H
2#define OPERATION_CYCLE_H
3
4#include <functional>
5#include "../core/instance_specifier.h"
6#include "../core/result.h"
7
8namespace ara
9{
10 namespace diag
11 {
14 {
15 private:
16 const ara::core::InstanceSpecifier &mSpecifier;
17 std::function<void()> mNotifier;
18
19 public:
22 explicit OperationCycle(const ara::core::InstanceSpecifier &specifier);
23
24 ~OperationCycle() noexcept = default;
25
30 ara::core::Result<void> SetNotifier(std::function<void()> notifier);
31
35 };
36 }
37}
38
39#endif
AUTOSAR shortname-path wrapper.
Definition: instance_specifier.h:14
A wrapper around the callee's return value and its possible error.
Definition: result.h:16
A class for handling a monitoring operation cycle.
Definition: operation_cycle.h:14
ara::core::Result< void > SetNotifier(std::function< void()> notifier)
Set a callback to be invoked when the operation cycle is restarted.
Definition: operation_cycle.cpp:11
ara::core::Result< void > RestartOperationCycle()
Restart the operation cycle.
Definition: operation_cycle.cpp:19
OperationCycle(const ara::core::InstanceSpecifier &specifier)
Constructor.
Definition: operation_cycle.cpp:7