What is Operation Contract in WCF Service?

In my earlier blog I wrote about Contracts and Service Contract. Please refer this link Service Contract in WCF

Here we will learn about Operation Contract.

Operation Contracts are nothing but the functions or methods exposed to the client which may or may not return to perform some logic at server end.

A simple Operation Contract with Service Contract will look like this.

public interface ICalculate
    int Sum(int num1, int num2); 
//A function to add 2 numbers which will return an integer.



Popular posts from this blog

CAML Query in SharePoint 2010

Calling REST APi from server side code - C#

All about SharePoint 2010 Content Type Hub

SharePoint Interview Questions and Answers

Calling ASP.Net WebMethod using jQuery AJAX