I m trying to rest-ify our existing WCF service and one of the hurdle is mapping complex type using Uritemplate. For example take a look at the below code
[DataContract]
public class Stock
{
[DataMember]
public string Symbol { get;set; }
[DataMember]
public double FaceValue { get; set; }
}
[ServiceContract]
public interface IRestService
{
[OperationContract]
[WebGet(UriTemplate = "?Symbol={stk.Symbol}")]
void Test1(Stock stk);
}
The above Uritemplate declaration will definitely not work, but this is what is my intention of mapping the input query variable to one of the property of that object.. Is this possible ?
Tks in advance for your help.