org.directdemocracyportal.democracy.service
Class UserServiceImpl

Package class diagram package UserServiceImpl
java.lang.Object
  extended by org.directdemocracyportal.democracy.service.UserServiceImpl
All Implemented Interfaces:
UserService

@Transactional(propagation=REQUIRED)
public class UserServiceImpl
extends java.lang.Object
implements UserService

The Class UserServiceImpl.


Constructor Summary
Constructor and Description
UserServiceImpl(UserDAO userDAO, PortalDAO portalDAO, PersonDAO personDAO, UserSessionDAO userSessionDAO, org.springframework.mail.javamail.JavaMailSenderImpl javaMailSenderImpl, org.springframework.mail.SimpleMailMessage simpleMailMessage)
          Instantiates a new user service impl.
 
Method Summary
Modifier and Type Method and Description
 void endActiveUserSessions()
          End active user sessions.
 java.util.List<Portal> getPortals()
          Gets the portals.
 User getUser(java.lang.Long userId)
          Gets the user.
 java.util.List<User> getUsers()
          Gets the users.
 User login(java.lang.String username, java.lang.String password, java.lang.String sessionId)
          Login.
 void logout(User user)
          Logout.
 User register(RegisterCommand command, java.lang.String sessionId)
          Register.
 void sendEmailConfirmationRequest(RegisterCommand command)
          Send email confirmation request.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UserServiceImpl

public UserServiceImpl(UserDAO userDAO,
                       PortalDAO portalDAO,
                       PersonDAO personDAO,
                       UserSessionDAO userSessionDAO,
                       org.springframework.mail.javamail.JavaMailSenderImpl javaMailSenderImpl,
                       org.springframework.mail.SimpleMailMessage simpleMailMessage)
Instantiates a new user service impl.

Parameters:
userDAO - the user dao
portalDAO - the portal dao
personDAO - the person dao
userSessionDAO - the user session dao
javaMailSenderImpl - the java mail sender impl
simpleMailMessage - the simple mail message
Method Detail

register

public User register(RegisterCommand command,
                     java.lang.String sessionId)
              throws UserAlreadyExistException
Description copied from interface: UserService
Register.

Specified by:
register in interface UserService
Parameters:
command - the command
sessionId - the session id
Returns:
the user
Throws:
UserAlreadyExistException - the user already exist exception

sendEmailConfirmationRequest

public void sendEmailConfirmationRequest(RegisterCommand command)
Send email confirmation request.

Parameters:
command - the command

getUsers

public java.util.List<User> getUsers()
Description copied from interface: UserService
Gets the users.

Specified by:
getUsers in interface UserService
Returns:
the users

login

public User login(java.lang.String username,
                  java.lang.String password,
                  java.lang.String sessionId)
Description copied from interface: UserService
Login.

Specified by:
login in interface UserService
Parameters:
username - the username
password - the password
sessionId - the session id
Returns:
the user

logout

public void logout(User user)
Description copied from interface: UserService
Logout.

Specified by:
logout in interface UserService
Parameters:
user - the user

getPortals

public java.util.List<Portal> getPortals()
Description copied from interface: UserService
Gets the portals.

Specified by:
getPortals in interface UserService
Returns:
the portals

endActiveUserSessions

public void endActiveUserSessions()
Description copied from interface: UserService
End active user sessions.

Specified by:
endActiveUserSessions in interface UserService

getUser

public User getUser(java.lang.Long userId)
Description copied from interface: UserService
Gets the user.

Specified by:
getUser in interface UserService
Parameters:
userId - the user id
Returns:
the user


Copyright © 2004-2010 www.DirectDemocracyPortal.org. All Rights Reserved.