Esempio n. 1
0
 //todo tests IsNotNull
 public static bool IsNotNull(this UserAuthenticateCommand userAuthenticateCommand)
 {
     return(AssertionConcern.IsSatisfiedBy(AssertionConcern.AssertNotNull(userAuthenticateCommand, Resources.Messages.InvalidCommandRequested)));
 }
Esempio n. 2
0
 public static bool HasActiveUser(this UserAuthenticateCommand userAuthenticateCommand, Person person)
 {
     return(AssertionConcern.IsSatisfiedBy(AssertionConcern.AssertTrue(person != null && person.PersonUserStatus.Value == PersonUserStatus.Active.Value, Resources.Messages.UserAuthenticateUserIsInactive)));
 }
Esempio n. 3
0
 public static bool HasPassword(this UserAuthenticateCommand userAuthenticateCommand)
 {
     return(AssertionConcern.IsSatisfiedBy(AssertionConcern.AssertNotNull(userAuthenticateCommand.Password, Resources.Messages.UserAuthenticatePasswordRequired)));
 }
Esempio n. 4
0
 public static bool HasFoundAuthorizedUser(this UserAuthenticateCommand userAuthenticateCommand, Person person)
 {
     return(AssertionConcern.IsSatisfiedBy(AssertionConcern.AssertNotNull(person, Resources.Messages.UserAuthenticateLoginFailed)));
 }
Esempio n. 5
0
 public static bool HasUserName(this UserAuthenticateCommand userAuthenticateCommand)
 {
     return(AssertionConcern.IsSatisfiedBy(AssertionConcern.AssertNotNull(userAuthenticateCommand.User, Resources.Messages.UserAuthenticateUserRequired)));
 }