WCF Interview Question and Answers

16. What is meant by Service contracts?
  Service contracts define the operations that a service will perform when executed. They tell the outside world a lot about the service such as message data types, operation locations, the protocols the client will need in order to communicate with the service, and the operations the service provides.
 
Your Name Your Email-ID
Your Answer
17. What is meant by Message contracts?
  Message contracts allow the control of SOAP messages that are produced and consumed by WCF. Basically it boils down to being able to customize the format of contract parameters and the placing of elements within a SOAP message, or in other words, having control of the structure as well as the contents of a SOAP message.
 
Your Name Your Email-ID
Your Answer
18. What is meant by Data contract?
  Data contracts specifically define the data that is being exchanged between a client and service. The data contract is an agreement, meaning that the client and the service must agree on the data contract in order for the exchange of data to take place.
 
Your Name Your Email-ID
Your Answer
19. What are the different types of layers in WCF?
 
    There are four layers in WCF are
  • Contracts - Defines the different functionalities that are exposed by the service to the client.
  • Service runtime - Defines the various run time behaviors of the service.
  • Messaging - Defines the channels that are used for processing and exchanging messages.
  • Activation and Hosting - Defines the way a WCF service is hosted.
 
Your Name Your Email-ID
Your Answer
20. What are Contracts in WCF and its types?
  A Contract is basically an agreement between the two parties i.e. Service and Client. In WCF, Contracts can be categorized as behavioral or structural.
 
Your Name Your Email-ID
Your Answer
12345 Page 4 of 5