Package org.olat.core.util.vfs

Examples of org.olat.core.util.vfs.VFSItem.canWrite()


        // container node
        String filePath = parentPath + childName + "/";
        GenericTreeNode tChild = new GenericTreeNode(childName, filePath); // filePath is the information to be remembered later
        tChild.setIconCssClass("b_filetype_folder");
        tChild.setAltText(child.getName());
        tChild.setAccessible(selectableFolders ? (child.canWrite() == VFSConstants.YES) : false);
        tParent.addChild(tChild);
        boolean addedChildren = buildTree(tChild, (VFSContainer)child, filePath);
        if (foldersOnly || addedChildren) {
          addedAtLeastOneChild = true;
        } else {
View Full Code Here


    }
    if (item == null) return false;
   
    VFSStatus status;
    if (item instanceof VFSContainer) {
      status = item.canWrite();
    } else {
      // read/write is not defined on item level, only on directory level
      status = item.getParentContainer().canWrite();
    }
    return VFSConstants.YES.equals(status);
View Full Code Here

          return;
        }
        VFSStatus vfsStatus = VFSConstants.SUCCESS;
        VFSContainer rootContainer = folderComponent.getRootContainer();
        VFSItem vfsItem = rootContainer.resolve(selectedPath);
        if (vfsItem == null || (vfsItem.canWrite() != VFSConstants.YES)) {
          abortFailed(ureq, "failed");
          return;
        }
        // copy the files
        VFSContainer target = (VFSContainer)vfsItem;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.