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


C# ProviderType.ToString方法代码示例

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


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

示例1: GetProvidersByType

 public List<Provider> GetProvidersByType(ProviderType providerType, int takeMax)
 {
     using (var connection = DbContextFactory.CreateConnection())
     {
         return connection
             .Query<Provider>("Provider_GetLatestByType", new { ProviderType = providerType.ToString(), Max = takeMax }, commandType: CommandType.StoredProcedure)
             .ToList();
     }
 }
开发者ID:wijayakoon,项目名称:Unixmo,代码行数:9,代码来源:ProviderRepository.cs

示例2: Search

 public List<Provider> Search(ProviderType providerType, string keyword, int? serviceTypeId, string providerSuburb, string providerState, int? make)
 {
     using (var conn = DbContextFactory.CreateConnection())
     {
         return conn
             .Query<Provider>("Provider_Search", new
             {
                 providerType = providerType.ToString(),
                 keyword,
                 serviceTypeId,
                 providerSuburb,
                 providerState,
                 make
             }, commandType: CommandType.StoredProcedure)
             .ToList();
     }
 }
开发者ID:wijayakoon,项目名称:Unixmo,代码行数:17,代码来源:ProviderRepository.cs

示例3: Provider

 public ConnectionBuilder Provider(ProviderType providerType) {
     _connection.Provider = providerType.ToString().ToLower();
     return this;
 }
开发者ID:modulexcite,项目名称:Transformalize,代码行数:4,代码来源:ConnectionBuilder.cs

示例4: FindByIdentityAsync

        public async Task<DomainUser> FindByIdentityAsync(ProviderType provider, string userIdentifier)
        {
            var user = await _userRepository.FindByIdentityAsync(provider.ToString(), userIdentifier);
            if (user == null)
            {
                throw new NotFoundException(string.Format("User with identity '{0}:{1}' was not found.", provider, userIdentifier));
            }

            CheckUserState(user);

            return _mapper.Map<UserEntity, DomainUser>(user);
        }
开发者ID:GusLab,项目名称:video-portal,代码行数:12,代码来源:UserService.cs

示例5: DeleteMembersipAsync

        public async Task DeleteMembersipAsync(string userId, ProviderType provider)
        {
            var user = await _userRepository.GetAsync(userId);
            if (user == null)
            {
                throw new NotFoundException(string.Format("Could not find user '{0}'.", userId));
            }

            await _userRepository.DeleteMembershipAsync(userId, provider.ToString());
        }
开发者ID:GusLab,项目名称:video-portal,代码行数:10,代码来源:UserService.cs

示例6: SetProviderType

 /// <summary>
 /// Sets specified provider class type
 /// </summary>
 private static void SetProviderType(ProviderType providerType, Type classType)
 {
     _loadedProviders[providerType.ToString()] = classType;
 }
开发者ID:wangscript,项目名称:tcgcms,代码行数:7,代码来源:Providers.cs

示例7: GetProviderType

 /// <summary>
 /// Gets specified provider class type.
 /// </summary>
 private static Type GetProviderType(ProviderType providerType)
 {
     return (Type)_loadedProviders[providerType.ToString()];
 }
开发者ID:wangscript,项目名称:tcgcms,代码行数:7,代码来源:Providers.cs


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