org.edg.data.reptor.storage
Class StorageResourceGridFTPImpl

java.lang.Object
  extended byorg.edg.data.reptor.storage.StorageResourceGridFTPImpl
All Implemented Interfaces:
StorageResource

public class StorageResourceGridFTPImpl
extends java.lang.Object
implements StorageResource

Dummy gridftp implementation of a storage resource. Knows only how to get the rudimentary fileinfo.

Version:
$Id: StorageResourceGridFTPImpl.java,v 1.39 2004/08/03 12:06:04 jamesc Exp $
Author:
Peter Kunszt

Constructor Summary
StorageResourceGridFTPImpl(Configuration config, java.lang.String seHost)
           
 
Method Summary
 java.net.URI generateSURL(java.lang.String storagePath)
          generate a SURL on this StorageResource.
 java.rmi.Remote getEndpoint()
          Return the SOAP endpoint for this Storage Resource.
 FileInfo getFileInfo(java.net.URI file)
           
 StorageElementInfo getInfo()
           
 SRMRequestStatus getRequestStatus(java.lang.String requestId)
           
 boolean isValidSurl(java.net.URI surl)
          Is a surl valid for a given Storage Resource.
 SRMRequestStatus prepareToGet(java.net.URI surl, java.lang.String protocol)
           
 SRMRequestStatus prepareToPut(java.net.URI surl, long size, java.lang.String protocol)
           
 void putActive(SRMRequestStatus requestID)
           
 void putDone(SRMRequestStatus requestID)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StorageResourceGridFTPImpl

public StorageResourceGridFTPImpl(Configuration config,
                                  java.lang.String seHost)
                           throws StorageResourceException
Method Detail

getFileInfo

public FileInfo getFileInfo(java.net.URI file)
                     throws java.io.FileNotFoundException,
                            StorageResourceException
Specified by:
getFileInfo in interface StorageResource
Throws:
java.io.FileNotFoundException
StorageResourceException

prepareToGet

public SRMRequestStatus prepareToGet(java.net.URI surl,
                                     java.lang.String protocol)
                              throws UnknownProtocolException,
                                     StorageResourceException
Specified by:
prepareToGet in interface StorageResource
Throws:
UnknownProtocolException
StorageResourceException

prepareToPut

public SRMRequestStatus prepareToPut(java.net.URI surl,
                                     long size,
                                     java.lang.String protocol)
Specified by:
prepareToPut in interface StorageResource

putDone

public void putDone(SRMRequestStatus requestID)
Specified by:
putDone in interface StorageResource

putActive

public void putActive(SRMRequestStatus requestID)
Specified by:
putActive in interface StorageResource

getRequestStatus

public SRMRequestStatus getRequestStatus(java.lang.String requestId)
Specified by:
getRequestStatus in interface StorageResource

getEndpoint

public java.rmi.Remote getEndpoint()
Description copied from interface: StorageResource
Return the SOAP endpoint for this Storage Resource. Returns null if the StorageResource does not have a SOAP control channel

Specified by:
getEndpoint in interface StorageResource

generateSURL

public java.net.URI generateSURL(java.lang.String storagePath)
Description copied from interface: StorageResource
generate a SURL on this StorageResource. If path is supplied, and not null use this as a path below the VO specific root directory. Otherwise construct a path. It returns null if the user's VO is not supported on that StorageResource.

Specified by:
generateSURL in interface StorageResource
Parameters:
storagePath - the storage path we would like, or null
Returns:
A SURL on this storage resource

isValidSurl

public boolean isValidSurl(java.net.URI surl)
Description copied from interface: StorageResource
Is a surl valid for a given Storage Resource. Checks the scheme and host are compatible.

Specified by:
isValidSurl in interface StorageResource
Parameters:
surl - the SURL
Returns:
true if the surl is valid, otherwise false

getInfo

public StorageElementInfo getInfo()
Specified by:
getInfo in interface StorageResource