Skip to content
Snippets Groups Projects
Commit 6e6aa233 authored by Philip Scherer's avatar Philip Scherer
Browse files

Add PredictingMemoryInterface to armem

parent 1fa22455
No related branches found
No related tags found
1 merge request!238Add prediction interface to Armem servers
......@@ -110,6 +110,7 @@ set(SLICE_FILES
armem/io.ice
armem/commit.ice
armem/memory.ice
armem/predictions.ice
armem/query.ice
armem/client.ice
......@@ -120,7 +121,7 @@ set(SLICE_FILES
armem/server/StoringMemoryInterface.ice
armem/server/LoadingMemoryInterface.ice
armem/server/MemoryInterface.ice
armem/server/MemoryPredictorInterface.ice
armem/server/PredictingMemoryInterface.ice
armem/server/ReadingMemoryInterface.ice
armem/server/WritingMemoryInterface.ice
......
#pragma once
module armarx
{
module armem
{
module predictions
{
module data
{
struct PredictionSettings
{
string predictionEngine = "";
};
sequence<string> PredictionEngineSeq;
};
};
};
};
......@@ -3,3 +3,4 @@
#include <RobotAPI/interface/armem/server/MemoryInterface.ice>
#include <RobotAPI/interface/armem/server/ReadingMemoryInterface.ice>
#include <RobotAPI/interface/armem/server/WritingMemoryInterface.ice>
#include <RobotAPI/interface/armem/server/PredictingMemoryInterface.ice>
......@@ -5,6 +5,8 @@
#include <RobotAPI/interface/armem/server/ReadingMemoryInterface.ice>
#include <RobotAPI/interface/armem/server/WritingMemoryInterface.ice>
#include <RobotAPI/interface/armem/server/PredictingMemoryInterface.ice>
#include <RobotAPI/interface/armem/server/ActionsInterface.ice>
#include <RobotAPI/interface/armem/client/MemoryListenerInterface.ice>
......@@ -27,6 +29,7 @@ module armarx
interface MemoryInterface extends
WorkingMemoryInterface,
LongTermMemoryInterface,
PredictingMemoryInterface,
actions::ActionsInterface,
client::MemoryListenerInterface
{
......
#pragma once
#include <RobotAPI/interface/armem/server/ReadingMemoryInterface.ice>
#include <RobotAPI/interface/armem/server/WritingMemoryInterface.ice>
module armarx {
module armem {
module server {
interface MemoryPredictorInterface
{
// TODO
void predict();
}
};
};
};
#pragma once
#include <RobotAPI/interface/armem/memory.ice>
#include <RobotAPI/interface/armem/predictions.ice>
#include <RobotAPI/interface/armem/query.ice>
module armarx
{
module armem
{
module server
{
interface PredictingMemoryInterface
{
armem::query::data::Result
predict(armem::data::MemoryID memoryID,
predictions::data::PredictionSettings predictionSettings);
predictions::data::PredictionEngineSeq getAvailableEngines();
}
};
};
};
......@@ -117,4 +117,19 @@ namespace armarx::armem::server::plugins
return {};
}
// PREDICTIONS
armem::query::data::Result ReadWritePluginUser::predict(const data::MemoryID& /*memoryID*/, const armem::predictions::data::PredictionSettings& /*predictionSettings*/, const ::Ice::Current& /*unused*/)
{
armem::query::data::Result result;
result.success = false;
result.errorMessage = "This memory does not implement predictions.";
result.memory = nullptr;
return result;
}
armem::predictions::data::PredictionEngineSeq ReadWritePluginUser::getAvailableEngines(const ::Ice::Current& /*unused*/)
{
return {};
}
} // namespace armarx::armem::server::plugins
......@@ -55,6 +55,10 @@ namespace armarx::armem::server::plugins
virtual armem::actions::GetActionsOutputSeq getActions(const armem::actions::GetActionsInputSeq& inputs, const ::Ice::Current&) override;
virtual armem::actions::ExecuteActionOutputSeq executeActions(const armem::actions::ExecuteActionInputSeq& inputs, const ::Ice::Current&) override;
// PredictingInterface interface
virtual armem::query::data::Result predict(const data::MemoryID& memoryID, const armem::predictions::data::PredictionSettings& predictionSettings, const ::Ice::Current& = Ice::emptyCurrent) override;
virtual armem::predictions::data::PredictionEngineSeq getAvailableEngines(const ::Ice::Current& = Ice::emptyCurrent) override;
public:
Plugin& memoryServerPlugin();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment