简体   繁体   中英

WCF Service used by Java client and Java Service used by WCF client

I am working on a web service interface, where my WCF application works both as a Client and a Service. There are multiple Java clients that need to connect to my web service. I will need to accept stream of images and documents and send back stream of converted images.

I would also need to connect to other Java services to send the image streams as a payload to be stored in a database. I am new to web services, is there good documentation on how to enable streaming contracts between WCF and Java clients and vice verse.

If I want to return other information along with the stream of (group) images to the client, how would I do that? Like the size of each image, the offset in the stream, so they can separate images.

Thanks

In order to return additional information with your images you will need to define a DataContract which contains the metadata elements as well as a collection to contain your images. Perhaps representing your image collection as a byte array rather than just returning a raw stream of images? There are several ways to address the issue, however the best solution depends on your design requirements.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM