Feature #1521
LocalServer lacks a Callback<void,void> specialization
Status: | Resolved | Start date: | 05/29/2013 | |
---|---|---|---|---|
Priority: | Normal | Due date: | ||
Assignee: | J. Moringen | % Done: | 100% | |
Category: | C++ | |||
Target version: | - |
Description
Currently it is not possible to register a method with no argument and no return value to a rsb server.
Solution: Add following overload of Callback to the rsb server:
class Callback<void, void>: public CallbackBase {
[...]
virtual void call(const std::string& methodName) = 0;
[...]
};
Associated revisions
Added rsb::patterns::LocalServer::Callback<void,void> in src/rsb/patterns/Server.h
fixes #1521
- src/rsb/patterns/Server.h (header): updated copyright
(Server::Callback<void, void): new class; Callback specialization
for methods which neither take arguments nor return results - examples/server/server.cpp (header): updated copyright
(VoidVoidCallback): new calls; demonstrates void-void callback
(main): register method "void" with VoidVoidCallback - examples/server/client.cpp (header): updated copyright
(main): call "void" method of the remote server
History
#1 Updated by J. Moringen almost 11 years ago
- Assignee set to J. Moringen
I already did this once but it did not quite work for some reason I can't remember. I will try again.
#2 Updated by J. Moringen almost 11 years ago
- Tracker changed from Bug to Feature
- Subject changed from Server lacks a Callback<void,void> overload to LocalServer lacks a Callback<void,void> specialization
- Status changed from New to In Progress
- % Done changed from 0 to 50
#3 Updated by J. Moringen almost 11 years ago
- Status changed from In Progress to Resolved
- % Done changed from 50 to 100
Applied in changeset rsb-cpp|commit:2eefc46c2880bea316bb9e6711d47173514a7bec.
#4 Updated by J. Moringen almost 11 years ago
- Status changed from Resolved to In Progress
- % Done changed from 100 to 50
An example can be found in the examples/server
directory.
#5 Updated by J. Moringen almost 11 years ago
- Status changed from In Progress to Resolved
- % Done changed from 50 to 100