You create a Windows Communication Foundation (WCF) service by using Microsoft .NET Framework 3.5. You write the following code segment. (Line numbers are included for reference only.)
01 public interface IMyService
02 {
04 string ProcessString(string name);
05 }
You create a host for the WCF service.
You also create a service endpoint at http://localhost:8080/service.
You add an instance of the HttpTransferEndPointBehavior class to the host.
You need to ensure that the ProcessString method can be invoked from a Web browser by using the URL http://localhost:8080/service/process?name=value
Which code segment should you insert at line 03?
A.
[OperationContract(Name=”process”, Action=”Get”)]
B.
[OperationContract(Name=”process”, Action=”Post”)]
C.
[OperationContract]
[WebGet(UriTemplate=”process?name={name}”)]
D.
[OperationContract]
[WebInvoke(UriTemplate=”process?name={name}”)]