|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Field Summary | |
static java.lang.String |
ROLE
|
Method Summary | |
void |
addSessionListener(SessionListener listener)
|
void |
addTransferListener(TransferListener listener)
|
void |
connect(Repository source)
|
void |
connect(Repository source,
AuthenticationInfo authenticationInfo)
|
void |
connect(Repository source,
AuthenticationInfo authenticationInfo,
ProxyInfo proxyInfo)
|
void |
connect(Repository source,
ProxyInfo proxyInfo)
|
void |
disconnect()
|
void |
get(java.lang.String resourceName,
java.io.File destination)
Downloads specified resource from the repository to given file. |
java.util.List |
getFileList(java.lang.String destinationDirectory)
Returns a List of strings naming the files and directories in the directory denoted by
this abstract pathname. |
boolean |
getIfNewer(java.lang.String resourceName,
java.io.File destination,
long timestamp)
Downloads specified resource from the repository if it was modfified since specified date. |
Repository |
getRepository()
|
boolean |
hasSessionListener(SessionListener listener)
|
boolean |
hasTransferListener(TransferListener listener)
|
boolean |
isInteractive()
|
void |
openConnection()
|
void |
put(java.io.File source,
java.lang.String destination)
Copy a file from local system to remote |
void |
putDirectory(java.io.File sourceDirectory,
java.lang.String destinationDirectory)
Copy a directory from local system to remote |
void |
removeSessionListener(SessionListener listener)
|
void |
removeTransferListener(TransferListener listener)
|
boolean |
resourceExists(java.lang.String resourceName)
Check if a remote resource exists |
void |
setInteractive(boolean interactive)
|
boolean |
supportsDirectoryCopy()
|
Field Detail |
public static final java.lang.String ROLE
Method Detail |
public void get(java.lang.String resourceName, java.io.File destination) throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
resourceName
- destination
-
TransferFailedException
ResourceDoesNotExistException
AuthorizationException
public boolean getIfNewer(java.lang.String resourceName, java.io.File destination, long timestamp) throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
resourceName
- destination
- timestamp
-
true
if newer resource has been downloaded, false
if resource
in the repository is older or has the same age.
TransferFailedException
ResourceDoesNotExistException
AuthorizationException
public void put(java.io.File source, java.lang.String destination) throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
source
- the local filedestination
- the remote destination
TransferFailedException
ResourceDoesNotExistException
AuthorizationException
public void putDirectory(java.io.File sourceDirectory, java.lang.String destinationDirectory) throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
sourceDirectory
- the local directorydestinationDirectory
- the remote destination
TransferFailedException
ResourceDoesNotExistException
AuthorizationException
public boolean resourceExists(java.lang.String resourceName) throws TransferFailedException, AuthorizationException
resourceName
-
TransferFailedException
- if there's an error trying to access the remote side
AuthorizationException
- if not authorized to verify the existence of the resourcepublic java.util.List getFileList(java.lang.String destinationDirectory) throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
Returns a List
of strings naming the files and directories in the directory denoted by
this abstract pathname.
If this abstract pathname does not denote a directory, or does not exist, then this method throws
ResourceDoesNotExistException
.
Otherwise a List
of strings is returned, one for each file or directory in the directory.
Names denoting the directory itself and the directory's parent directory are not included in
the result. Each string is a file name rather than a complete path.
There is no guarantee that the name strings in the resulting list will appear in any specific order; they are not, in particular, guaranteed to appear in alphabetical order.
destinationDirectory
- directory to list contents of
List
of strings naming the files and directories in the directory denoted by
this abstract pathname. The List
will be empty if the directory is empty.
TransferFailedException
- if there's an error trying to access the remote side
ResourceDoesNotExistException
- if destinationDirectory does not exist or is not a directory
AuthorizationException
- if not authorized to list the contents of the directorypublic boolean supportsDirectoryCopy()
public Repository getRepository()
public void connect(Repository source) throws ConnectionException, AuthenticationException
ConnectionException
AuthenticationException
public void connect(Repository source, ProxyInfo proxyInfo) throws ConnectionException, AuthenticationException
ConnectionException
AuthenticationException
public void connect(Repository source, AuthenticationInfo authenticationInfo) throws ConnectionException, AuthenticationException
ConnectionException
AuthenticationException
public void connect(Repository source, AuthenticationInfo authenticationInfo, ProxyInfo proxyInfo) throws ConnectionException, AuthenticationException
ConnectionException
AuthenticationException
public void openConnection() throws ConnectionException, AuthenticationException
ConnectionException
AuthenticationException
public void disconnect() throws ConnectionException
ConnectionException
public void addSessionListener(SessionListener listener)
public void removeSessionListener(SessionListener listener)
public boolean hasSessionListener(SessionListener listener)
public void addTransferListener(TransferListener listener)
public void removeTransferListener(TransferListener listener)
public boolean hasTransferListener(TransferListener listener)
public boolean isInteractive()
public void setInteractive(boolean interactive)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |