コード例 #1
0
ファイル: ServiceFactory.cs プロジェクト: 921819535/cms
 /// <summary>
 ///
 /// </summary>
 /// <param name="method"></param>
 /// <returns></returns>
 public static ICmsServiceProvider GetService(ServiceCallMethod method)
 {
     if (method == ServiceCallMethod.Redirect)
     {
         return(_redirect ?? (_redirect = new RedirectCallService()));
     }
     throw new NotSupportedException("目前仅支持直接调用接口");
 }
コード例 #2
0
ファイル: ServiceFactory.cs プロジェクト: coodream/cms
 /// <summary>
 /// 
 /// </summary>
 /// <param name="method"></param>
 /// <returns></returns>
 public static ICmsServiceProvider GetService(ServiceCallMethod method)
 {
     if (method == ServiceCallMethod.Redirect)
            return _redirect ??(_redirect = new RedirectCallService());
     throw new NotSupportedException("目前仅支持直接调用接口");
 }