Exemplo n.º 1
0
 public ComBoostPrincipal(IPrincipal user)
 {
     if (user == null)
         throw new ArgumentNullException("user");
     OriginPrincipal = user;
     Identity = new ComBoostIdentity(this);
 }
Exemplo n.º 2
0
 public ComBoostPrincipal(IPrincipal user)
 {
     if (user == null)
     {
         throw new ArgumentNullException("user");
     }
     OriginPrincipal = user;
     Identity        = new ComBoostIdentity(this);
 }
Exemplo n.º 3
0
 /// <summary>
 /// Initialize comboost principal.
 /// </summary>
 /// <param name="user">Principal to wrapper.</param>
 public ComBoostPrincipal(IPrincipal user)
 {
     if (user == null)
         throw new ArgumentNullException("user");
     CurrentRoute = RouteTable.Routes.GetRouteData(new HttpContextWrapper(HttpContext.Current));
     if (ComBoostAuthentication.IsEnabled)
     {
         Identity = new ComBoostIdentity(this);
         OriginPrincipal = this;
     }
     else
     {
         Identity = user.Identity;
         OriginPrincipal = user;
     }
 }
Exemplo n.º 4
0
 /// <summary>
 /// Initialize comboost principal.
 /// </summary>
 /// <param name="user">Principal to wrapper.</param>
 public ComBoostPrincipal(IPrincipal user)
 {
     if (user == null)
     {
         throw new ArgumentNullException("user");
     }
     CurrentRoute = RouteTable.Routes.GetRouteData(new HttpContextWrapper(HttpContext.Current));
     if (ComBoostAuthentication.IsEnabled)
     {
         Identity        = new ComBoostIdentity(this);
         OriginPrincipal = this;
     }
     else
     {
         Identity        = user.Identity;
         OriginPrincipal = user;
     }
 }