Public Member Functions | |
virtual Storage * | open (const std::string &proto, const std::string &path, int mode, const std::string &tmpdir) |
Definition at line 5 of file GsiFTPStorageMaker.cc.
virtual Storage* GsiFTPStorageMaker::open | ( | const std::string & | proto, | |
const std::string & | path, | |||
int | mode, | |||
const std::string & | tmpdir | |||
) | [inline, virtual] |
Implements StorageMaker.
Definition at line 8 of file GsiFTPStorageMaker.cc.
References RemoteFile::get(), RemoteFile::local(), and pyDBSRunClass::temp.
00012 { 00013 std::string temp; 00014 int localfd = RemoteFile::local (tmpdir, temp); 00015 std::string lurl = "file://" + temp; 00016 std::string newurl ((proto == "sfn" ? "gsiftp" : proto) + ":" + path); 00017 const char *ftpopts [] = { "globus-url-copy", newurl.c_str (), lurl.c_str (), 0 }; 00018 return RemoteFile::get (localfd, temp, (char **) ftpopts, mode); 00019 }