In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article mainly shows you "how to use WCF controls", the content is easy to understand, clear, hope to help you solve your doubts, the following let the editor lead you to study and learn "how to use WCF controls" this article.
WCF (Windows Communication Foundation) is a technology that enables different parts of software to communicate with each other. Now there are many similar technologies, even if you have not used them, you must have heard of them, such as COM (Components Object Model), DCOM (distributed component object Model), MSMQ (Microsoft Message Queueing,Microsoft message queuing) and so on, but these technologies are very different from WCF controls, and these technologies can only be run in specific scenarios.
Empty theory is difficult to understand, just feel the charm of WCF controls with me! In order to allow other software to communicate with the classes we define, we will use the WCF access model to add communication functions to them. We can create a WCF service, and then access the service we wrote at the terminal. To put it bluntly, it is to remotely call the service class we write, but the invocation function of this class is very powerful. You can use the program written by java to call the class we wrote. It can also be called with other language classes.
The contract for defining WCF is very simple, just define an interface and then add some properties to the interface. Let me write a WCF control service together.
(1) from the VS2008 menu, select File, New Project, other Project types, visual Studio solution, named WCFSolution, and add a class library named Calculator in the solution.
(2) Delete the default Class.cs file in Calculator and create a new interface ICalculator, as follows:
Using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace Calculator {public interface ICalculator {int Add (int num1,int num2); int Multiply (int num1,int num2);}} these are all the contents of the article "how to use WCF controls". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.