com.partnersoft.io.net
Class YonderClient
java.lang.Object
com.partnersoft.io.net.YonderClient
- All Implemented Interfaces:
- YonderConstants
public class YonderClient
- extends java.lang.Object
- implements YonderConstants
Client for the Yonder remote file server.
- Author:
- Paul Reavis
Copyright 2004 Partner Software, Inc.
| Fields inherited from interface com.partnersoft.io.net.YonderConstants |
OP_CLOSE, OP_CONNECT, OP_DISCONNECT, OP_ERROR, OP_FETCH, OP_FETCHALL, OP_LIST, OP_NOK, OP_OK, OP_OPEN, YONDER_PORT, YONDER_VERSION |
|
Constructor Summary |
YonderClient(java.lang.String serverName)
|
|
Method Summary |
void |
connect()
Connect to the YonderServer. |
void |
connect(boolean resolveHostName)
|
void |
disconnect()
Disconnect from the YonderServer. |
void |
download(java.lang.String remotePath,
java.io.File localFile)
Download by copying a remote file to a local file. |
java.io.InputStream |
inputStreamFor(java.lang.String path)
|
java.lang.String[] |
list(java.lang.String remotePath)
List contents of remote directory. |
VFSRandomAccess |
randomAccessFor(java.lang.String path)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
YonderClient
public YonderClient(java.lang.String serverName)
connect
public void connect()
throws java.io.IOException
- Connect to the YonderServer.
- Throws:
java.io.IOException
connect
public void connect(boolean resolveHostName)
throws java.io.IOException
- Throws:
java.io.IOException
disconnect
public void disconnect()
throws java.io.IOException
- Disconnect from the YonderServer.
- Throws:
java.io.IOException
download
public void download(java.lang.String remotePath,
java.io.File localFile)
throws java.io.IOException
- Download by copying a remote file to a local file. Overwrites the local file.
- Throws:
java.io.IOException
list
public java.lang.String[] list(java.lang.String remotePath)
throws java.io.IOException
- List contents of remote directory. Subdirectories will be
marked with trailing slashes.
- Throws:
java.io.IOException
inputStreamFor
public java.io.InputStream inputStreamFor(java.lang.String path)
throws java.io.IOException
- Throws:
java.io.IOException
randomAccessFor
public VFSRandomAccess randomAccessFor(java.lang.String path)
throws java.io.IOException
- Throws:
java.io.IOException