Introducing a namespace
This way we can call the methods the same as in the APImaster
parent
806e836df5
commit
2050f105ba
|
@ -14,12 +14,12 @@
|
|||
static const char *ASYNC_SERVER_NAME = "security.pep";
|
||||
static const char *ASYNC_SERVER_PATH = "/security/pep";
|
||||
|
||||
pEpServer::pEpServer(DBus::Connection &connection)
|
||||
pEp::Server::Server(DBus::Connection &connection)
|
||||
: DBus::ObjectAdaptor(connection, ASYNC_SERVER_PATH)
|
||||
{
|
||||
}
|
||||
|
||||
pEpServer::~pEpServer() {};
|
||||
pEp::Server::~Server() {};
|
||||
|
||||
DBus::BusDispatcher dispatcher;
|
||||
|
||||
|
@ -34,7 +34,7 @@ void niam(int sig)
|
|||
status = decrypt_message( mSession, (message*)&src, (message**)&dst, (stringlist_t**)&keylist, (PEP_rating*)rating, (PEP_encrypt_flags_t*)&flags );
|
||||
//dbus_g_method_return( status );
|
||||
}*/
|
||||
void pEpServer::decryptMessage(const pEpDBusMessage& src, const pEpDBusStringList& keylist, const pEpDBusRating& rating,
|
||||
void pEp::Server::decryptMessage(const pEpDBusMessage& src, const pEpDBusStringList& keylist, const pEpDBusRating& rating,
|
||||
const pEpDBusEncryptionFlags& flags, pEpDBusStatus& status, pEpDBusMessage& dst)
|
||||
{
|
||||
}
|
||||
|
@ -49,7 +49,7 @@ int main()
|
|||
DBus::Connection conn = DBus::Connection::SessionBus();
|
||||
conn.request_name(ASYNC_SERVER_NAME);
|
||||
|
||||
pEpServer server(conn);
|
||||
pEp::Server server(conn);
|
||||
|
||||
dispatcher.enter();
|
||||
|
||||
|
|
|
@ -9,14 +9,15 @@
|
|||
|
||||
struct _pEpSession;
|
||||
|
||||
class pEpServer
|
||||
namespace pEp {
|
||||
class Server
|
||||
: public security::pep_adaptor,
|
||||
public DBus::IntrospectableAdaptor,
|
||||
public DBus::ObjectAdaptor
|
||||
{
|
||||
public:
|
||||
pEpServer(DBus::Connection &connection);
|
||||
~pEpServer();
|
||||
Server(DBus::Connection &connection);
|
||||
~Server();
|
||||
|
||||
// Message API
|
||||
void decryptMessage(const pEpDBusMessage& src, const pEpDBusStringList& keylist, const pEpDBusRating& rating,
|
||||
|
@ -26,5 +27,6 @@ private:
|
|||
struct _pEpSession* mSession;
|
||||
|
||||
};
|
||||
}
|
||||
|
||||
#endif//__DEMO_ASYNC_SERVER_H
|
||||
|
|
Loading…
Reference in New Issue