Package org.damour.base.client.objects

Examples of org.damour.base.client.objects.RepositoryTreeNode


                    + " OR file.globalRead = true OR file.id in " + getUserPermissionQuery(user, "file") + " OR file.id in "
                    + getGroupPermissionQuery(user, "file") + ")").setCacheable(true).list();
      }
    }
    for (Folder folder : folders) {
      RepositoryTreeNode childNode = new RepositoryTreeNode();
      parentNode.getFolders().put(folder, childNode);
      buildRepositoryTreeNode(session, user, childNode, folder);
    }
    parentNode.setFiles(files);
  }
View Full Code Here


    for (int i = 0; i < 5; i++) {
      System.out.println("Starting dump");
      session = HibernateUtil.getInstance().getSession();
      // as user, get files i can see
      RepositoryTreeNode root = new RepositoryTreeNode();
      RepositoryHelper.buildRepositoryTreeNode(session, user2, root, null);
      RepositoryHelper.dumpTreeNode(root, 0);
      session.close();
      System.out.println("End dump");
    }
View Full Code Here

  }

  public RepositoryTreeNode getRepositoryTree() throws SimpleMessageException {
    try {
      User authUser = getAuthenticatedUser(session.get());
      RepositoryTreeNode root = new RepositoryTreeNode();
      RepositoryHelper.buildRepositoryTreeNode(session.get(), authUser, root, null);
      return root;
    } catch (Throwable t) {
      Logger.log(t);
      throw new SimpleMessageException(t.getMessage());
View Full Code Here

      } else if (createRootItem) {
        rootItem.addItem(folderItem);
      } else {
        addItem(folderItem);
      }
      RepositoryTreeNode treeNode = repositoryTreeNode.getFolders().get(folder);
      if (showOnlyFolders && treeNode.getFolders().size() == 0) {
        TreeItem hiddenItem = new TreeItem();
        folderItem.addItem(hiddenItem);
        String tooltip = folder.getDescription();
        new ToolTip(label, null, tooltip);
        hiddenItem.setVisible(false);
      } else if (treeNode.getFiles().size() == 0 && treeNode.getFolders().size() == 0) {
        TreeItem hiddenItem = new TreeItem();
        folderItem.addItem(hiddenItem);
        String tooltip = folder.getDescription() + " (empty)";
        new ToolTip(label, null, tooltip);
        hiddenItem.setVisible(false);
View Full Code Here

TOP

Related Classes of org.damour.base.client.objects.RepositoryTreeNode

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.