top button
Flag Notify
    Connect to us
      Facebook Login
      Site Registration Why to Join

Facebook Login
Site Registration

What is Contract? What are the types of Contract in WCF?

+1 vote
What is Contract? What are the types of Contract in WCF?
posted Sep 1, 2015 by Jdk

Share this question
Facebook Share Button Twitter Share Button Google+ Share Button LinkedIn Share Button Multiple Social Share Button

1 Answer

+2 votes
Best answer

It is the agreement between client and service which specifies:

[ServiceContract] - which services are exposed to the client.

[OperationContract] - which operations the client can perform on the service.

[DataContract] – which data types are passed to and from the service.

[MessageContract] - allow the service to interact directly with messages. Message contracts can be typed or untyped and are useful in interoperability cases when another party has already dictated some explicit (typically proprietary) message format.

[FaultContract] -which errors are raised by the service and how the service handles andpropagates errors to its clients.

answer Sep 2, 2015 by Manikandan J
Contact Us
+91 9880187415
#280, 3rd floor, 5th Main
6th Sector, HSR Layout
Karnataka INDIA.