public UserServiceImpl( IUserData userData, IAuthenticatorData authenticateData, UserDtoAdapter userDtoAdapter, ISessionManager sessionManager) { this.userData = userData; this.userDtoAdapter = userDtoAdapter; this.authenticateData = authenticateData; this.sessionManager = sessionManager; this.userIdGenerator = new UserIdGenerator(userData); this.authenticateIdGenerator = new AuthenticateIdGenerator(authenticateData); }
private void init() { AuthenticateInMemoryAdapter authenticateInMemoryAdapter = new AuthenticateInMemoryAdapter(); authenticator = new AuthenticateInMemoryImpl(authenticateInMemoryAdapter); Authenticate authenticate0 = new Authenticate(new AuthenticateId("0"), "login0", Role.librarian); authenticator.Add(authenticate0, "password0"); Authenticate authenticate1 = new Authenticate(new AuthenticateId("1"), "login1", Role.librarian); authenticator.Add(authenticate1, "password1"); Authenticate authenticate2 = new Authenticate(new AuthenticateId("2"), "login2", Role.librarian); authenticator.Add(authenticate2, "password2"); }
public AuthenticateIdGenerator(IAuthenticatorData authenticateData) { this.authenticateData = authenticateData; }
private void initEmpty() { AuthenticateInMemoryAdapter authenticateInMemoryAdapter = new AuthenticateInMemoryAdapter(); authenticator = new AuthenticateInMemoryImpl(authenticateInMemoryAdapter); }