knowrob  2.1.0
A Knowledge Base System for Cognition-enabled Robots
Storage.h File Reference
#include <boost/property_tree/ptree.hpp>
#include "knowrob/semweb/TriplePattern.h"
#include "knowrob/semweb/Triple.h"
#include "knowrob/semweb/TripleContainer.h"
#include "knowrob/semweb/Vocabulary.h"
#include "knowrob/PropertyTree.h"
#include "knowrob/ThreadPool.h"
#include "knowrob/DataSourceHandler.h"
#include "knowrob/plugins/PluginFactory.h"
#include "knowrob/plugins/TypedPluginFactory.h"
Include dependency graph for Storage.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  knowrob::Storage
 

Namespaces

 knowrob
 

Macros

#define KNOWROB_STORAGE_PLUGIN(classType, pluginName)
 

Enumerations

enum class  knowrob::StorageFeature : std::uint8_t {
  knowrob::NothingSpecial = 1ul << 0 , knowrob::ReAssignment = 1ul << 2 , knowrob::TripleContext = 1ul << 3 , knowrob::NothingSpecial = 1ul << 0 ,
  knowrob::ReAssignment = 1ul << 2 , knowrob::TripleContext = 1ul << 3
}
 

Functions

StorageFeature knowrob::operator| (StorageFeature a, StorageFeature b)
 
bool knowrob::operator& (StorageFeature a, StorageFeature b)
 

Macro Definition Documentation

◆ KNOWROB_STORAGE_PLUGIN

#define KNOWROB_STORAGE_PLUGIN (   classType,
  pluginName 
)
Value:
extern "C" { \
std::shared_ptr<knowrob::DataBackend> knowrob_createPlugin(const std::string &pluginID) \
{ return std::make_shared<classType>(); } \
const char* knowrob_getPluginName() { return pluginName; } }
TermRule & string()
Definition: terms.cpp:63

Define a data backend plugin. The macro generates two functions that are used as entry points for loading the plugin. First, a factory function is defined that creates instances of classType. This will only work when classType has a single argument constructor that accepts a string as argument (the KG instance ID). Second, a function is generated that exposes the plugin name.

Parameters
classTypethe type of the backend, must be a subclass of DataBackend
pluginNamea plugin identifier, e.g. the name of the backend type.

Definition at line 171 of file Storage.h.