Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can WCF be used with/from native (C++) applications?

Tags:

c++

.net

wcf

What the question says. How do you interface with the WCF "world" from a native application, that does not have .NET available?

EDIT: Sorry, I should have been more specific as it appears that WCF covers such a broad spectrum. I was thinking of the case where you have several applications using WCF/TCP communication as their communication/IPC mechanism and you now need to integrate a native (C++) application that hasn't .NET available.

like image 381
Martin Ba Avatar asked Dec 09 '22 12:12

Martin Ba


1 Answers

WCF is protocol agnostic - well almost. But you need to consider this in the way you are going to communicate with WCF:

As long as you can send messages as the other side can use, you should be alright.

1) Named-pipe binding: It is propriety and difficult to use outside .NET

2) TCP binding: It is propriety and difficult to use outside .NET

3) basicHttp binding: It is one of the easiest to implement outside .NET

4) wsHttp binding: as long as you have a nativelibrary that can create and consume ws* messages you are fine but a bit difficult.

5) REST API: It is indeed the easiest and I recommend this one if you have a control over what kind of service is provided to you.

like image 117
Aliostad Avatar answered Dec 28 '22 02:12

Aliostad