PROTOTYPE
Not reviewed yet: use at your own risk!

satin.remotelauncher
Class RemoteFile

java.lang.Object
  |
  +--satin.aro.AROobject
        |
        +--satin.aro.AROremoteObject
              |
              +--satin.remotelauncher.RemoteFile

public class RemoteFile
extends AROremoteObject

Represents a file on a remote system, accessed through the RemoteLauncher. This class implements most of the methods of the standard Java File class. Each object represents a file that is accessed from the system on which a RemoteLauncher server is running.

The permissions granted to the user of this class are those of the RemoteLauncher server, which in turn are those of the user who was logged into the remote system when the server was launched.

Author:
Ed Stauff

Fields inherited from class satin.aro.AROremoteObject
server
 
Fields inherited from class satin.aro.AROobject
id
 
Constructor Summary
RemoteFile(RemoteLauncher srvr, java.lang.String pathName)
          The constructor.
 
Method Summary
boolean createNewFile()
          Creates a new file.
boolean delete()
          Deletes the file.
java.lang.String getAbsolutePath()
          Returns the absolute path for the file.
java.lang.String getCanonicalPath()
          Returns the canonical path for the file.
java.lang.String getName()
          Returns the name of the file.
java.lang.String getParent()
          Returns the pathname string of this abstract pathname's parent, or null if this pathname does not name a parent directory.
boolean isDirectory()
          Returns whether the abstract path refers to a directory.
boolean isFile()
          Returns whether the abstract path refers to a file.
java.lang.String[] list()
          Returns an array of strings naming the files and directories in the directory denoted by this abstract pathname.
boolean mkdir()
          Creates the directory named by this abstract pathname.
boolean mkdirs()
          Creates the directory named by this abstract pathname, including any necessary but nonexistent parent directories.
java.lang.String toString()
          Converts the object to a human-readable representation.
 
Methods inherited from class satin.aro.AROremoteObject
equals, exists, getAROclassName
 
Methods inherited from class satin.aro.AROobject
getID, setID, toAROstring
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RemoteFile

public RemoteFile(RemoteLauncher srvr,
                  java.lang.String pathName)
           throws java.io.IOException,
                  AROexception
The constructor.

Parameters:
srvr
the RemoteLauncher which will handle the file manipulation operations for this object.
pathName
the path name of the file, relative to the system on which the RemoteLauncher is running.
Method Detail

createNewFile

public boolean createNewFile()
                      throws java.io.IOException,
                             AROexception
Creates a new file. See File.createNewFile.

delete

public boolean delete()
               throws java.io.IOException,
                      AROexception
Deletes the file. See File.delete.

getAbsolutePath

public java.lang.String getAbsolutePath()
                                 throws java.io.IOException,
                                        AROexception
Returns the absolute path for the file. See File.getAbsolutePath.

getCanonicalPath

public java.lang.String getCanonicalPath()
                                  throws java.io.IOException,
                                         AROexception
Returns the canonical path for the file. See File.getCanonicalPath.

getName

public java.lang.String getName()
                         throws java.io.IOException,
                                AROexception
Returns the name of the file. See File.getName.

getParent

public java.lang.String getParent()
                           throws java.io.IOException,
                                  AROexception
Returns the pathname string of this abstract pathname's parent, or null if this pathname does not name a parent directory. See File.getParent.

isDirectory

public boolean isDirectory()
                    throws java.io.IOException,
                           AROexception
Returns whether the abstract path refers to a directory. See File.isDirectory.

isFile

public boolean isFile()
               throws java.io.IOException,
                      AROexception
Returns whether the abstract path refers to a file. See File.isFile.

list

public java.lang.String[] list()
                        throws java.io.IOException,
                               AROexception
Returns an array of strings naming the files and directories in the directory denoted by this abstract pathname. See File.list.

mkdir

public boolean mkdir()
              throws java.io.IOException,
                     AROexception
Creates the directory named by this abstract pathname. See File.mkdir.

mkdirs

public boolean mkdirs()
               throws java.io.IOException,
                      AROexception
Creates the directory named by this abstract pathname, including any necessary but nonexistent parent directories. See File.mkdirs.

toString

public java.lang.String toString()
Description copied from class: AROobject
Converts the object to a human-readable representation.

Overrides:
toString in class AROobject

Following copied from class: satin.aro.AROobject

Returns:
The string representation of the object.
Revision History

6/19/01 Ed Stauff - made changes per API review.

4/17/01 Ed Stauff - file created.



Generated on 5/9/2001 19:37 from RemoteFile.java (PRIVATE SOURCES)