コード例 #1
0
  @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;
  }
コード例 #2
0
 @Override
 public Property[] getLibraryProperties(Item item) {
   Factory factory = (Factory) repositoryFolder.getChild("script-factory");
   return factory.getProperties(item);
 }
コード例 #3
0
 @Override
 public int getNextSequence() {
   Factory factory = (Factory) repositoryFolder.getChild("script-factory");
   int nextId = Sequences.getNext(factory.getSequence());
   return nextId;
 }