如何检测iOS或Android是否请求wcf调用?
我有以下WCF方法。
public Stream GetSmartLinkImage(string SmartLinkId)
{
wmas_subsDataContext dc = new wmas_subsDataContext();
string path = string.Empty;
var fileRecord = from p in dc.Images where p.ImageTitle == "IMG0001" select p;
if (fileRecord.Count() > 0)
{
path = ConfigurationManager.AppSettings["ImagesPath"].ToString() + "\\" + fileRecord.First().ImageName;
}
FileStream fs = File.OpenRead(path);
return fs;
}