LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   C++ windows server but linux client app remotely invoking methods (https://www.linuxquestions.org/questions/programming-9/c-windows-server-but-linux-client-app-remotely-invoking-methods-675888/)

linuxmandrake 10-12-2008 02:12 PM

C++ windows server but linux client app remotely invoking methods
 
Hi
In .net or java there's is remote method invocation. In the .net world it's called remoting. I was wondering does C++ have a eqivulent or do I have to use socket programming? I assume socket programming in C++ isn't that difficult? I need a windows server but a linux client.

irishbitte 10-12-2008 04:12 PM

in Java, it's called RMI, (remote method invocation). I don't think a similar thing exists for C++, but I may be proved wrong, after all, I'm not a programmer per se.

ta0kira 10-12-2008 08:09 PM

Quote:

Originally Posted by linuxmandrake (Post 3307888)
Hi
In .net or java there's is remote method invocation. In the .net world it's called remoting. I was wondering does C++ have a eqivulent or do I have to use socket programming? I assume socket programming in C++ isn't that difficult? I need a windows server but a linux client.

C++ doesn't actually have socket programming. It has files, but they're far from ideal for use with sockets. You normally need to use an OS-dependent library to use sockets with C++ (but boost would be a likely place for a portable library.) In the case of Linux, you need to use libc and the POSIX API socket functions. It isn't at all related to C++, but you can set up the routines in classes (I've never done it because C doesn't scare me.) I don't know how the higher-level languages deal with sockets, so I don't know what sort of automation you're expecting. I can tell you one thing for sure: without a third-party library, using sockets in C++ on Linux isn't as pretty as any given built-in in Java, and it's also comparatively easy to do something wrong.
ta0kira


All times are GMT -5. The time now is 06:09 PM.