@Test(expected = AuthenticationException.class) public void testGetNullUserExists() throws Exception { defaultAuthentication.getUserExists(null); }
@Override public UserInfo getUserExists(final String userEmail) { LOGGER.debug("Authentication token received as: {}", userEmail); if (!isBlank(userEmail)) { return userDirectory.lookupUserByEmail(userEmail); } else { throw new AuthenticationException("user does not exists in system"); } }
DefaultAuthentication implements Authentication { @Override public UserInfo getUserExists(final String userEmail) { LOGGER.debug("Authentication token received as: {}", userEmail); if (!isBlank(userEmail)) { return userDirectory.lookupUserByEmail(userEmail); } else { throw new AuthenticationException("user does not exists in system"); } } }
DefaultAuthentication implements Authentication { @Override public UserInfo getUserExists(final String userEmail) { LOGGER.debug("Authentication token received as: {}", userEmail); if (!isBlank(userEmail)) { return userDirectory.lookupUserByEmail(userEmail); } else { throw new AuthenticationException("user does not exists in system"); } } @Inject  DefaultAuthentication(final UserDirectory userDirectory); }
DefaultAuthentication implements Authentication { @Override public UserInfo getUserExists(final String userEmail) { LOGGER.debug("Authentication token received as: {}", userEmail); if (!isBlank(userEmail)) { return userDirectory.lookupUserByEmail(userEmail); } else { throw new AuthenticationException("user does not exists in system"); } } @Inject  DefaultAuthentication(final UserDirectory userDirectory); @Override LoginToken logIn(final String authHeader); @Override LoginToken verifyToken(final String tokenHeader); @Override boolean logOut(final String tokenHeader); @Override UserInfo getUserExists(final String userEmail); }
DefaultAuthentication implements Authentication { @Override public UserInfo getUserExists(final String userEmail) { LOGGER.debug("Authentication token received as: {}", userEmail); if (!isBlank(userEmail)) { return userDirectory.lookupUserByEmail(userEmail); } else { throw new AuthenticationException("user does not exists in system"); } } @Inject  DefaultAuthentication(final UserDirectory userDirectory); @Override LoginToken logIn(final String authHeader); @Override LoginToken verifyToken(final String tokenHeader); @Override boolean logOut(final String tokenHeader); @Override UserInfo getUserExists(final String userEmail); static final String BASIC; static final String EMPTY; }