Class SmbFiles


  • public class SmbFiles
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      SmbFiles()  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static int copy​(java.io.File source, DiskShare share, java.lang.String destPath, boolean overwrite)
      Copies local file to a destination path on the share
      void mkdirs​(DiskShare diskShare, SmbPath path)
      Create a set of nested sub-directories in the given path, for example, 2345 \ 3456 \ 4453 \ 123123.txt
      void mkdirs​(DiskShare diskShare, java.lang.String path)
      Create a set of nested sub-directories in the given path, for example, 2345 \ 3456 \ 4453 \ 123123.txt
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SmbFiles

        public SmbFiles()
    • Method Detail

      • copy

        public static int copy​(java.io.File source,
                               DiskShare share,
                               java.lang.String destPath,
                               boolean overwrite)
                        throws java.io.IOException
        Copies local file to a destination path on the share
        Parameters:
        share - the share
        destPath - the path to write to
        source - the local File
        overwrite - true/false to overwrite existing file
        Returns:
        the actual number of bytes that was written to the file
        Throws:
        java.io.FileNotFoundException
        java.io.IOException
      • mkdirs

        public void mkdirs​(DiskShare diskShare,
                           java.lang.String path)
                    throws SMBApiException
        Create a set of nested sub-directories in the given path, for example, 2345 \ 3456 \ 4453 \ 123123.txt
        Throws:
        SMBApiException