Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
12/04/08 17:28:52 (15 years ago)
Author:
svonolfe
Message:

Added userGroupAdapter, clientGroupAdapter interfaces (#372)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Hive.Server.Core/ServiceLocator.cs

    r899 r910  
    3232  private static IClientAdapter clientAdapter = null;
    3333
     34  private static IClientGroupAdapter clientGroupAdapter = null;
     35
    3436  private static IUserAdapter userAdapter = null;
     37
     38  private static IUserGroupAdapter userGroupAdapter = null;
    3539 
    3640  /// <summary>
     
    4751
    4852  /// <summary>
     53  /// Gets the client group database adapter
     54  /// </summary>
     55  /// <returns></returns>
     56  internal static IClientGroupAdapter GetClientGroupAdapter() {
     57    if (clientGroupAdapter == null) {
     58      clientGroupAdapter = discoveryService.GetInstances<IClientGroupAdapter>()[0];
     59    }
     60
     61    return clientGroupAdapter;
     62  }
     63
     64  /// <summary>
    4965  /// Gets the user database adapter
    5066  /// </summary>
     
    5773    return userAdapter;
    5874  }
     75
     76  /// <summary>
     77  /// Gets the user group database adapter
     78  /// </summary>
     79  /// <returns></returns>
     80  internal static IUserGroupAdapter GetUserGroupAdapter() {
     81    if (userGroupAdapter == null) {
     82      userGroupAdapter = discoveryService.GetInstances<IUserGroupAdapter>()[0];
     83    }
     84
     85    return userGroupAdapter;
     86  }
    5987}
Note: See TracChangeset for help on using the changeset viewer.