Package org.javlo.user
Interface IUserFactory
-
- All Known Implementing Classes:
AbstractDBUserFactory
,AdminUserFactory
,HardUserFactory
,InternalDBUserFactory
,LdapDirectUserFactory
,MapDbUserFactory
,UserFactory
public interface IUserFactory
-
-
Field Summary
Fields Modifier and Type Field Description static int
AUTO_LOGIN_AGE_SEC
static String
TOKEN_PARAM
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addOrModifyUserInfo(IUserInfo userInfo)
if user info found, update datavoid
addUserInfo(IUserInfo userInfo)
User
adminFakeLogin(javax.servlet.http.HttpServletRequest request, String login)
User
autoLogin(javax.servlet.http.HttpServletRequest request, String login)
String
checkUserAviability(ContentContext ctx, String login)
check the login is availablevoid
clearUserInfoList()
IUserInfo
createUserInfos()
void
deleteUser(String login)
Set<String>
getAllRoles(GlobalContext globalContext, javax.servlet.http.HttpSession session)
get all roles of the user.User
getCurrentUser(GlobalContext globalContext, javax.servlet.http.HttpSession session)
RoleWrapper
getRoleWrapper(ContentContext ctx, User user)
String
getSessionKey()
String
getTokenCreateIfNotExist(User user)
User
getUser(String login)
User
getUserByEmail(String email)
List<IUserInfo>
getUserInfoForRoles(String[] inRoles)
List<IUserInfo>
getUserInfoList()
IUserInfo
getUserInfos(String id)
void
init(GlobalContext globalContext, javax.servlet.http.HttpSession newSession)
boolean
isStandardStorage()
check if the user system use standard storage system of wcmsUser
login(javax.servlet.http.HttpServletRequest request, String token)
User
login(javax.servlet.http.HttpServletRequest request, String login, String password)
void
logout(javax.servlet.http.HttpSession session)
void
mergeUserInfo(IUserInfo userInfo)
void
releaseUserInfoList()
void
reload(GlobalContext globalContext, javax.servlet.http.HttpSession session)
void
store()
void
updateUserInfo(IUserInfo userInfo)
-
-
-
Field Detail
-
TOKEN_PARAM
static final String TOKEN_PARAM
- See Also:
- Constant Field Values
-
AUTO_LOGIN_AGE_SEC
static final int AUTO_LOGIN_AGE_SEC
- See Also:
- Constant Field Values
-
-
Method Detail
-
logout
void logout(javax.servlet.http.HttpSession session)
-
getCurrentUser
User getCurrentUser(GlobalContext globalContext, javax.servlet.http.HttpSession session)
-
releaseUserInfoList
void releaseUserInfoList()
-
clearUserInfoList
void clearUserInfoList()
-
addUserInfo
void addUserInfo(IUserInfo userInfo) throws UserAllreadyExistException
- Throws:
UserAllreadyExistException
-
addOrModifyUserInfo
void addOrModifyUserInfo(IUserInfo userInfo) throws UserAllreadyExistException
if user info found, update data- Parameters:
userInfo
-- Throws:
UserAllreadyExistException
-
mergeUserInfo
void mergeUserInfo(IUserInfo userInfo) throws IOException
- Throws:
IOException
-
updateUserInfo
void updateUserInfo(IUserInfo userInfo) throws IOException
- Throws:
IOException
-
deleteUser
void deleteUser(String login)
-
store
void store() throws IOException
- Throws:
IOException
-
createUserInfos
IUserInfo createUserInfos()
-
getTokenCreateIfNotExist
String getTokenCreateIfNotExist(User user) throws IOException
- Throws:
IOException
-
checkUserAviability
String checkUserAviability(ContentContext ctx, String login)
check the login is available- Parameters:
ctx
-login
-- Returns:
- null if ok, error message otherwise
-
getAllRoles
Set<String> getAllRoles(GlobalContext globalContext, javax.servlet.http.HttpSession session)
get all roles of the user.- Parameters:
globalContext
-session
-- Returns:
-
init
void init(GlobalContext globalContext, javax.servlet.http.HttpSession newSession)
-
reload
void reload(GlobalContext globalContext, javax.servlet.http.HttpSession session)
-
isStandardStorage
boolean isStandardStorage()
check if the user system use standard storage system of wcms- Returns:
- true if standard system is used, false else a external system is used.
-
getRoleWrapper
RoleWrapper getRoleWrapper(ContentContext ctx, User user)
-
getSessionKey
String getSessionKey()
-
-