/ExpressInteropBinding/WCFInteroperableServiceApplicationTemplate/Service.svc.cs
# · C# · 28 lines · 25 code · 2 blank · 1 comment · 3 complexity · cd9c58a5718964b0b8e2aa03aba4efd7 MD5 · raw file
- using System;
- using System.Collections.Generic;
- $if$ ($targetframeworkversion$ >= 3.5)using System.Linq;
- $endif$using System.Runtime.Serialization;
- using System.ServiceModel;
- using System.Text;
-
- // NOTE: You can use the "Rename" command on the "Refactor" menu to change the class name "Service" in code, svc and config file together.
- public class Service : IService
- {
- public string GetData(int value)
- {
- return string.Format("You entered: {0}", value);
- }
-
- public CompositeType GetDataUsingDataContract(CompositeType composite)
- {
- if (composite == null)
- {
- throw new ArgumentNullException("composite");
- }
- if (composite.BoolValue)
- {
- composite.StringValue += "Suffix";
- }
- return composite;
- }
- }