nexuslua
Loading...
Searching...
No Matches
nexuslua Namespace Reference

The nexuslua library is implemented inside this namespace. More...

Namespaces

namespace  description
namespace  LuaExtension
namespace  utility
 various helper functions

Classes

class  Agent
 base class of the three types of agents More...
class  AgentMessage
 This class describes a message that can be sent via nexuslua send or AgentMessage::Send. More...
class  agents
 Functions related to agents or plugins, which are (un-)installable agents with meta data like a version, see class nexuslua::Agent. More...
class  Configuration
 stores internal and user configuration More...
struct  LuaTable
 This type is used for the parameters of nexuslua::Message. In its serialized representation, it can be passed to or returned by functions of shared libraries that are imported via nexuslua function import. It is the composition of a std::map of cbeam::container::xpod::type instances (cbeam::container::table_of_values) and a std::map of cbeam::container::nested_map instances (cbeam::container::nested_table). The std::variant cbeam::container::xpod::type which is used for keys and values is central to the functionality of nexuslua. More...
struct  Message
 This type is the actual message type that is sent by function send. More...
class  PluginRegistry
 This class provides the interface to nexuslua "plugins" (agents that are installable from an online repository) More...
struct  PluginUninstallResult
 result values of agents::UninstallPlugin More...

Typedefs

typedef std::function< void(std::shared_ptr< Message >)> CppHandler
 the signature of a function that is called whenever a C++ nexuslua::agent receives a message
using LuaTableBase = cbeam::container::nested_map<cbeam::container::xpod::type, cbeam::container::xpod::type>

Enumerations

enum class  AgentType { Undefined = -1 , Lua = 0 , Cpp = 1 }
enum class  PluginInstallResult {
  SUCCESS , ERROR_PLUGIN_ALREADY_INSTALLED , ERROR_DIRECTORY_DOES_NOT_EXIST , ERROR_COPYING_PLUGIN_TO_TARGET_DIRECTORY ,
  ERROR_INVALID_SRC , ERROR_WHILE_CREATING_INSTANCE
}
 result values of agents::InstallPlugin More...
enum class  DownloadProgress {
  CONNECTING , SENDING_REQUEST , READING_HTTP_RESPONSE , READING_DATA ,
  DOWNLOADING , ERR , ABORTED
}
 used by utils::ReadHttp to call a function to describe the download state, including a string with further information More...

Detailed Description

The nexuslua library is implemented inside this namespace.

Typedef Documentation

◆ CppHandler

typedef std::function<void(std::shared_ptr<Message>)> nexuslua::CppHandler

the signature of a function that is called whenever a C++ nexuslua::agent receives a message

The callback function is registered via nexuslua::agents::Add. All message names that will be sent must first be registered via nexuslua::agents::AddMessageForCppAgent.

◆ LuaTableBase

using nexuslua::LuaTableBase = cbeam::container::nested_map<cbeam::container::xpod::type, cbeam::container::xpod::type>

Enumeration Type Documentation

◆ AgentType

enum class nexuslua::AgentType
strong
Enumerator
Undefined 
Lua 
Cpp 

◆ DownloadProgress

enum class nexuslua::DownloadProgress
strong

used by utils::ReadHttp to call a function to describe the download state, including a string with further information

Enumerator
CONNECTING 
SENDING_REQUEST 
READING_HTTP_RESPONSE 
READING_DATA 
DOWNLOADING 

string will contain current download size

ERR 

string will contain error message

ABORTED 

◆ PluginInstallResult

enum class nexuslua::PluginInstallResult
strong

result values of agents::InstallPlugin

Enumerator
SUCCESS 
ERROR_PLUGIN_ALREADY_INSTALLED 

the target directory already exists. If user wants to update, he first has to uninstall that plugin

ERROR_DIRECTORY_DOES_NOT_EXIST 

the source directory the user specified does not exist

ERROR_COPYING_PLUGIN_TO_TARGET_DIRECTORY 
ERROR_INVALID_SRC 
ERROR_WHILE_CREATING_INSTANCE 

in case of this result, parameter errorMessage of method InstallPlugin contains an English error message that has to be shown to the user (who is a plugin developer in this case)