Added atomic sessions in TC
This commit is contained in:
@@ -9,6 +9,8 @@ namespace Bloom::TargetController::Commands
|
||||
GENERIC,
|
||||
SHUTDOWN,
|
||||
GET_TARGET_DESCRIPTOR,
|
||||
START_ATOMIC_SESSION,
|
||||
END_ATOMIC_SESSION,
|
||||
STOP_TARGET_EXECUTION,
|
||||
RESUME_TARGET_EXECUTION,
|
||||
RESET_TARGET,
|
||||
|
||||
25
src/TargetController/Commands/EndAtomicSession.hpp
Normal file
25
src/TargetController/Commands/EndAtomicSession.hpp
Normal file
@@ -0,0 +1,25 @@
|
||||
#pragma once
|
||||
|
||||
#include "Command.hpp"
|
||||
|
||||
#include "src/TargetController/Responses/AtomicSessionId.hpp"
|
||||
|
||||
namespace Bloom::TargetController::Commands
|
||||
{
|
||||
class EndAtomicSession: public Command
|
||||
{
|
||||
public:
|
||||
static constexpr CommandType type = CommandType::END_ATOMIC_SESSION;
|
||||
static const inline std::string name = "EndAtomicSession";
|
||||
|
||||
AtomicSessionIdType sessionId;
|
||||
|
||||
explicit EndAtomicSession(AtomicSessionIdType sessionId)
|
||||
: sessionId(sessionId)
|
||||
{}
|
||||
|
||||
[[nodiscard]] CommandType getType() const override {
|
||||
return EndAtomicSession::type;
|
||||
}
|
||||
};
|
||||
}
|
||||
21
src/TargetController/Commands/StartAtomicSession.hpp
Normal file
21
src/TargetController/Commands/StartAtomicSession.hpp
Normal file
@@ -0,0 +1,21 @@
|
||||
#pragma once
|
||||
|
||||
#include "Command.hpp"
|
||||
|
||||
#include "src/TargetController/Responses/AtomicSessionId.hpp"
|
||||
|
||||
namespace Bloom::TargetController::Commands
|
||||
{
|
||||
class StartAtomicSession: public Command
|
||||
{
|
||||
public:
|
||||
using SuccessResponseType = Responses::AtomicSessionId;
|
||||
|
||||
static constexpr CommandType type = CommandType::START_ATOMIC_SESSION;
|
||||
static const inline std::string name = "StartAtomicSession";
|
||||
|
||||
[[nodiscard]] CommandType getType() const override {
|
||||
return StartAtomicSession::type;
|
||||
}
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user