Package com.adito.vfs

Examples of com.adito.vfs.FileObjectVFSResource


      }
      VFSResource parent = null;
      if (path.equals("")) {
        parent = getStore().getStoreResource();
      }
      return new FileObjectVFSResource(getLaunchSession(), this,
              parent,
              path,
              getStore().getRepository(),
              requestCredentials);
    }
View Full Code Here


            throws IOException {
      VFSResource parent = null;
      if (path.equals("")) {
        parent = getStore().getStoreResource();
      }
      return new FileObjectVFSResource(getLaunchSession(), this,
              parent,
              path,
              getStore().getRepository(),
              requestCredentials);
    }
View Full Code Here

          public String toString() {
            return SimpleDateFormat.getInstance().format(this.getTime());
          }
        };
                gc.setTimeInMillis(0);
        FileObjectVFSResource element = (FileObjectVFSResource) itr.next();
        // this is an extra defense against imaginary files.
        FileType ft = null;
        try {
          ft = element.getFile().getType();
        } catch (FileSystemException e) {
        } catch (IOException e) {
        }
        FileSystemItem item = null;
        if (ft != null && element.getFile().getType().equals(FileType.FOLDER)
          && fileSystemForm.getNetworkPlace().isAllowRecursive()) {
          // if it is a folder
                    if(element.getLastModified() != null)
                        gc.setTime(element.getLastModified());
          item = new FolderItem(fileSystemForm.getLaunchSession(), element.getDisplayName(), res.getMount()
                  .getStore()
                  .getName(), fileSystemForm.getPath(), gc, element.getFile().getType().getName(), false, i);
        } else if (ft != null && element.getFile().getType().equals(FileType.FILE)) {
          // if it is a file
                    if(element.getLastModified() != null)
                        gc.setTime(element.getLastModified());
          item = new FileItem(fileSystemForm.getLaunchSession(), element.getDisplayName(), element.getContentLength()
                  .longValue(), gc, element.getFile().getType().getName(), false, i);
        } else {
          if (log.isInfoEnabled())
            log.info("Unable to display file " + element.getDisplayName() + " as it is an imaginary file.");
          warnings.add(Constants.REQ_ATTR_WARNINGS, new BundleActionMessage(NetworkPlacePlugin.MESSAGE_RESOURCES_KEY,
                  "vfs.imaginary.file",
                  element.getDisplayName()));

          // decrement the counter as there is no file added.
          i--;
        }
        if (item != null) {
View Full Code Here

TOP

Related Classes of com.adito.vfs.FileObjectVFSResource

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.