mirror of
https://github.com/mudita/MuditaOS.git
synced 2026-01-16 10:00:03 -05:00
Improve structure of the module sys. Problems within this module prevents from linking others. Signed-off-by: Marcin Smoczyński <smoczynski.marcin@gmail.com>
30 lines
968 B
C++
30 lines
968 B
C++
// Copyright (c) 2017-2021, Mudita Sp. z.o.o. All rights reserved.
|
|
// For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md
|
|
|
|
#pragma once
|
|
|
|
#include <string>
|
|
|
|
#include "TimerHandle.hpp"
|
|
|
|
namespace sys
|
|
{
|
|
class Service; // Forward declaration
|
|
} // namespace sys
|
|
|
|
namespace sys
|
|
{
|
|
class TimerFactory
|
|
{
|
|
public:
|
|
static TimerHandle createSingleShotTimer(Service *parent,
|
|
const std::string &name,
|
|
std::chrono::milliseconds interval,
|
|
timer::TimerCallback &&callback);
|
|
static TimerHandle createPeriodicTimer(Service *parent,
|
|
const std::string &name,
|
|
std::chrono::milliseconds interval,
|
|
timer::TimerCallback &&callback);
|
|
};
|
|
} // namespace sys
|