Exemplo n.º 1
0
 public Theme loadTheme(String themeName) throws RepositoryException {
   try {
     RepositoryObjectProvider objectProvider = m_provider.getObject(themeName, false);
     Theme theme = Theme.createFromJSONObject(objectProvider.getObject());
     return theme;
   } catch (JSONException ex) {
     throw new RepositoryException(ex);
   }
 }
Exemplo n.º 2
0
  public List<ThemeContainerEntry> getEntries(boolean loadThumbnails) throws RepositoryException {

    ArrayList<ThemeContainerEntry> m_entries = new ArrayList<ThemeContainerEntry>();

    for (RepositoryObjectProvider objectProvider : m_provider.getObjects(loadThumbnails)) {
      ThemeContainerEntry entry =
          new ThemeContainerEntry(
              objectProvider.getObjectName(),
              objectProvider.getLastChangedDate(),
              objectProvider.getThumbnail());
      m_entries.add(entry);
    }

    Collections.sort(m_entries);

    return m_entries;
  }