Package com.atomrain.labs.architect.service

Examples of com.atomrain.labs.architect.service.UserServiceException


   */
  public User getUserById(long id) throws UserServiceException {
    try {
      return this.userMapper.getUserById(id);
    } catch (Exception e) {
      throw new UserServiceException(UserServiceException.GET_USER_BY_ID, new Object[] {id});
    }
  }
View Full Code Here


   */
  public User getUserByUsername(String username) throws UserServiceException {
    try {
      return userMapper.getUserByUsername(username);
    } catch (Exception e) {
      throw new UserServiceException(UserServiceException.GET_USER_BY_USERNAME, new Object[] {username});
    }
  }
View Full Code Here

   */
  public User getUserByEmail(String email) throws UserServiceException {
    try {
      return userMapper.getUserByEmail(email);
    } catch (Exception e) {
      throw new UserServiceException(UserServiceException.GET_USER_BY_EMAIL, new Object[] {email});
    }
  }
View Full Code Here

   */
  public void createLazyUser(String username, String password, String email) throws UserServiceException {
    try {
      this.userMapper.createUser(username, password, email);
    } catch (Exception e) {
      throw new UserServiceException(UserServiceException.CREATE_LAZY_USER, new Object[] {username, password, email});
    }
  }
View Full Code Here

   */
  public User createEagerUser(String username, String password, String email) throws UserServiceException {
    try {
      this.userMapper.createUser(username, password, email);
    } catch (Exception e) {
      throw new UserServiceException(UserServiceException.CREATE_EAGER_USER, new Object[] {username, password, email});
    }
    return getUserByUsername(username);
  }
View Full Code Here

   */
  public void removeUserById(long id) throws UserServiceException {
    try {
      this.userMapper.removeUserById(id);
    } catch (Exception e) {
      throw new UserServiceException(UserServiceException.REMOVE_USER_BY_ID, new Object[] {id});
    }
  }
View Full Code Here

   */
  public void removeUserByUsername(String username) throws UserServiceException {
    try {
      this.userMapper.removeUserByUsername(username);
    } catch (Exception e) {
      throw new UserServiceException(UserServiceException.REMOVE_USER_BY_USERNAME, new Object[] {username});
    }
  }
View Full Code Here

   */
  public void removeUserByEmail(String email) throws UserServiceException {
    try {
      this.userMapper.removeUserByEmail(email);
    } catch (Exception e) {
      throw new UserServiceException(UserServiceException.REMOVE_USER_BY_EMAIL, new Object[] {email});
    }
  }
View Full Code Here

TOP

Related Classes of com.atomrain.labs.architect.service.UserServiceException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.