public void RemoveAuthenticationMethod(DSMAuthenticationMethod method)
 {
     if (AuthenticationSection.ContainsKey(method))
     {
         AuthenticationSection.Remove(AuthenticationSection[method]);
     }
 }
 public DSMAuthentication GetAuthenticationMethod(DSMAuthenticationMethod method)
 {
     if (AuthenticationSection.ContainsKey(method))
     {
         return(AuthenticationSection[method]);
     }
     else
     {
         return(null);
     }
 }
 public DSMAuthentication GetOrAddAuthenticationMethod(DSMAuthenticationMethod method)
 {
     if (AuthenticationSection.ContainsKey(method))
     {
         return(AuthenticationSection[method]);
     }
     else
     {
         var added = new DSMAuthentication(method);
         AuthenticationSection.Add(added);
         return(added);
     }
 }
示例#4
0
 public bool HasAuthenticationMethod(DSMAuthenticationMethod method)
 {
     return(AuthenticationSection.ContainsKey(method));
 }