Пример #1
0
 /// <summary>
 /// Define a user actor for a <see cref="ISecurable">securable</see>
 /// </summary>
 /// <param name="securable"><see cref="ISecurable"/> to secure</param>
 /// <returns>The <see cref="UserSecurityActor"/></returns>
 public static UserSecurityActor User(this ISecurable securable)
 {
     var actor = new UserSecurityActor();
     securable.AddActor(actor);
     return actor;
 }
Пример #2
0
 /// <summary>
 /// Define a user actor for a <see cref="ISecurable">securable</see>
 /// </summary>
 /// <param name="securable"><see cref="ISecurable"/> to secure</param>
 /// <returns>The <see cref="UserSecurityActor"/></returns>
 public static UserSecurityActor User(this ISecurable securable)
 {
     var actor = new UserSecurityActor(Configure.Instance.Container.Get<ICanResolvePrincipal>());
     securable.AddActor(actor);
     return actor;
 }