当前位置: 首页>>代码示例>>C#>>正文


C# Services.ToString方法代码示例

本文整理汇总了C#中Services.ToString方法的典型用法代码示例。如果您正苦于以下问题:C# Services.ToString方法的具体用法?C# Services.ToString怎么用?C# Services.ToString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Services的用法示例。


在下文中一共展示了Services.ToString方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: GetEntityService

        public override IService GetEntityService(Services serviceName)
        {
            var obj = new object();
            var type = Type.GetType(GetImplName(serviceName.ToString()));
            if (type != null) obj = Activator.CreateInstance(type);

            return (IService) obj;
        }
开发者ID:phowland1,项目名称:PassOneWeb,代码行数:8,代码来源:EntityFactory.cs

示例2: GetService

 public override IService GetService(Services serviceName)
 {
     Type type;
     var obj = new object();
     try
     {
         type = Type.GetType(GetImplName(serviceName.ToString()));
         obj = Activator.CreateInstance(type);
     }
     catch (Exception e)
     {
         Console.WriteLine("Exception occured: {0}", e);
         throw e;
     }
     return (IService)obj;
 }
开发者ID:phowland1,项目名称:PassOneDesktop,代码行数:16,代码来源:EntityFactory.cs

示例3: GetSoapService

 /// <summary>
 /// Abstract implementation method, returns the requested service
 /// </summary>
 /// <param name="serviceName">Enum - defines the specific service to be retrived</param>
 /// <param name="path">The directory path to where the app can find the PassOne data files</param>
 /// <param name="passOneUser">Optional parameter - required for credentials services</param>
 /// <returns></returns>
 public override IService GetSoapService(Services serviceName, string path,  PassOneUser passOneUser = null)
 {
     Type type;
     var obj = new object();
     try
     {
         type = Type.GetType(GetImplName(serviceName.ToString()));
         obj = Activator.CreateInstance(type);
     }
     catch (MissingMethodException)
     {
         obj = new CredentialsSoapSerializer(passOneUser);
     }
     catch (Exception e)
     {
         Console.WriteLine("Exception occured: {0}", e);
         throw e;
     }
     ((ISerializeSvc)obj).SetPath(path);
     return (IService) obj;
 }
开发者ID:phowland1,项目名称:PassOneWeb,代码行数:28,代码来源:SoapFactory.cs

示例4: UpdateStateOfMatchChoice

        private long? UpdateStateOfMatchChoice(Services.Contracts.Common.ChoiceTypeEnum choiceType,
                                               Choice choice,
                                               long userID)
        {
            long? result = null;

            if (choice.ProfileChoice.ChoiceType == Services.Contracts.Common.ChoiceTypeEnum.Like)
            {
                if (choice.ProfileChoice.MatchChoice != null)
                {
                    if (choice.ProfileChoice.MatchChoice.MatchChoiceType == Services.Contracts.Common.ChoiceTypeEnum.Like)
                    {
                        // Transition the state to consent.
                        result = ChoiceTypeID(choiceType.ToString());

                        // set the match user state to consent as well.
                        var matchChoice = choice.CreateProfileChoiceModelInstance(choice.ProfileChoice.MatchUser.UserID.Value,
                                                                                  userID,
                                                                                  choice.ProfileChoice.MatchChoice.ID.Value);
                        base.ProfileChocies.Attach(matchChoice);

                        matchChoice = choice.SetProfileChoiceModelInstance(matchChoice,
                                                                           result.Value);
                    }
                }
            }

            return result;
        }
开发者ID:tsnyder569,项目名称:PLuvMiddleTier,代码行数:29,代码来源:TICPuppyLoveDbContext.cs

示例5: TextInput

 public static void TextInput(Services title, string message)
 {
     var dialog = new MessageDialog(message, title.ToString()).ShowAsync();
 }
开发者ID:CodeRevver,项目名称:sea-rover,代码行数:4,代码来源:Message.cs

示例6: AddLog

 public void AddLog(PortalSettings _PortalSettings, int UserID, Services.Log.EventLog.EventLogController.EventLogType objLogType)
 {
     LogProperties objProperties = new LogProperties();
     AddLog(objProperties, _PortalSettings, UserID, objLogType.ToString(), false);
 }
开发者ID:jackiechou,项目名称:thegioicuaban.com,代码行数:5,代码来源:EventLogController.cs

示例7: Run

 public static void Run(Services service, DirectoryInfo directory, ExecMode mode = ExecMode.Run, bool noNewWindows=true)
 {
     Shell.SilentMode = noNewWindows;
     Main(new string[] { service.ToString(), directory.FullName, mode.ToString() });
 }
开发者ID:IvanSorokin,项目名称:Tuto,代码行数:5,代码来源:Program.cs


注:本文中的Services.ToString方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。