com.sun.enterprise.util.cluster.windows.io
Class WindowsRemoteFile

java.lang.Object
  extended by com.sun.enterprise.util.cluster.windows.io.WindowsRemoteFile

public final class WindowsRemoteFile
extends java.lang.Object

Author:
Byron Nevins

Constructor Summary
WindowsRemoteFile(WindowsCredentials bonafides, java.lang.String path)
           
WindowsRemoteFile(WindowsRemoteFile parent, java.lang.String path)
           
WindowsRemoteFile(WindowsRemoteFileSystem wrfs, java.lang.String path)
           
 
Method Summary
 void copyFrom(java.io.BufferedInputStream sin)
          Copies from sin to this WindowsRemoteFile
 void copyFrom(java.util.Collection<java.lang.String> from)
           
 void copyFrom(java.io.File from, WindowsRemoteFileCopyProgress progress)
           
 void copyFrom(java.lang.String from)
           
 void copyTo(java.io.File file)
          Copy the remote Windows file to the given File
 void copyTo(java.io.File file, WindowsRemoteFileCopyProgress progress)
          Copy the remote Windows file to the given File
 void copyTo(WindowsRemoteFile wf)
           
 void createNewFile()
           
 void delete()
           
 boolean exists()
           
 java.lang.String getPath()
           
 java.lang.String[] list()
           
 void mkdirs()
           
 void mkdirs(boolean force)
           
 void setLastModified(long when)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WindowsRemoteFile

public WindowsRemoteFile(WindowsRemoteFile parent,
                         java.lang.String path)
                  throws WindowsException
Throws:
WindowsException

WindowsRemoteFile

public WindowsRemoteFile(WindowsCredentials bonafides,
                         java.lang.String path)
                  throws WindowsException
Throws:
WindowsException

WindowsRemoteFile

public WindowsRemoteFile(WindowsRemoteFileSystem wrfs,
                         java.lang.String path)
                  throws WindowsException
Throws:
WindowsException
Method Detail

exists

public final boolean exists()
                     throws WindowsException
Throws:
WindowsException

list

public final java.lang.String[] list()
                              throws WindowsException
Throws:
WindowsException

createNewFile

public final void createNewFile()
                         throws WindowsException
Throws:
WindowsException

copyTo

public final void copyTo(WindowsRemoteFile wf)
                  throws WindowsException
Throws:
WindowsException

copyTo

public final void copyTo(java.io.File file)
                  throws WindowsException
Copy the remote Windows file to the given File

Parameters:
f - The File that will be created or overwritten with the contents of this Windows Remote File.
Throws:
WindowsException
Since:
3.1.2

copyTo

public final void copyTo(java.io.File file,
                         WindowsRemoteFileCopyProgress progress)
                  throws WindowsException
Copy the remote Windows file to the given File

Parameters:
f - The File that will be created or overwritten with the contents of this Windows Remote File.
progress - The optional callback object that gets called for each chunk of data that gets copied over the wire. Setting it to null is OK.
Throws:
WindowsException
Since:
3.1.2

delete

public final void delete()
                  throws WindowsException
Throws:
WindowsException

mkdirs

public final void mkdirs()
                  throws WindowsException
Throws:
WindowsException

mkdirs

public final void mkdirs(boolean force)
                  throws WindowsException
Throws:
WindowsException

copyFrom

public final void copyFrom(java.io.BufferedInputStream sin)
                    throws WindowsException
Copies from sin to this WindowsRemoteFile

Parameters:
sin - the opened stream. It will automatically be closed here.
Throws:
WindowsException - if any errors.

copyFrom

public final void copyFrom(java.io.File from,
                           WindowsRemoteFileCopyProgress progress)
                    throws WindowsException
Throws:
WindowsException

copyFrom

public final void copyFrom(java.util.Collection<java.lang.String> from)
                    throws WindowsException
Throws:
WindowsException

copyFrom

public final void copyFrom(java.lang.String from)
                    throws WindowsException
Throws:
WindowsException

setLastModified

public final void setLastModified(long when)
                           throws WindowsException
Throws:
WindowsException

getPath

public final java.lang.String getPath()


Copyright © 2012 GlassFish Community. All Rights Reserved.