@Override public UserDetails getDetails() { UserDetails userDetails = new UserDetails(); userDetails.setEmail(userAsFolder.getProperty(EMAIL_PROPERTY, "")); userDetails.setName(userAsFolder.getProperty(NAME_PROPERTY, "")); userDetails.setSurname(userAsFolder.getProperty(SURNAME_PROPERTY, "")); Text userStatisticsText = (Text) userAsFolder.getChild(UserPersistencyOnJease.USER_STATISTICS); String userStatisticsXML = null; if (userStatisticsText != null) { userStatisticsXML = userStatisticsText.getContent(); } userDetails.setUserStatistics( UserPersistencyOnJease.getUserStatisticsFromText(userStatisticsXML)); return userDetails; }
@Override public UserRole getRole() { return UserRole.valueOf(userAsFolder.getProperty(ROLE_PROPERTY, UserRole.DEFAULT.toString())); }
@Override public String getEncryptedPassword() { return userAsFolder.getProperty(ENCRYPTED_PASSWORD_PROPERTY, ""); }