Server

namespace Server

The server component implements the server concept of the Common API C++ client/server architecture, it supports both D-Bus and SOME/IP runtime bindings.

In this project, it implements a stub and a non-persistent storage to test the different functionalities of the Common API C++ framework, refer to the application for details of how it fits with the rest of the architecture.

class AppService : public Utils::Capi::Priv::ServiceBase<Stub>

Implementation of the application service.

Public Functions

AppService(const std::string &domain, const std::string &instance, const std::string &connection)

Class constructor.

Parameters:
  • domain[in] Common API C++ domain for the application service.

  • instance[in] Common API C++ instance for the application service.

  • connection[in] Common API C++ connection for the application service.

~AppService(void) override

Class Destructor.

void ping(const std::shared_ptr<CommonAPI::ClientId> client, std::string request, pingReply_t reply) override

Implementation of ‘ping’ in the server.

Parameters:
  • client – An identifier for the client performing the request.

  • request – The message for the request.

  • reply – The function to use to reply back to the client.

Utils::Error::ID App::Server::main(void)

Main function for a server executable.

Returns:

Identifier for the error.