Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

FileSystem* Impala::Persistency::RepositoryInFileSystem::GetFS ( const Locator loc  )  [inline, private]

Definition at line 84 of file RepositoryInFileSystem.h.

References Impala::FileNameBase(), Impala::Persistency::Locator::GetDataSet(), Impala::Persistency::Locator::GetHost(), Impala::CmdOptions::GetInstance(), Impala::CmdOptions::GetString(), mMap, Impala::StringReplaceAll(), and Impala::Persistency::Locator::ToString().

Referenced by DeleteDir(), and GetFile().

00085     {
00086         FileSystem* fs = 0;
00087         if (mMap.Get(loc.ToString(), fs))
00088             return fs;
00089 
00090         CmdOptions& options = CmdOptions::GetInstance();
00091         String setName = loc.GetDataSet();
00092         String data("");
00093         if ((setName == "dot") || (setName == ".") || (setName == "abs") ||
00094             (setName == "direct")) // direct is the most accurate name
00095         {
00096             data = "";
00097             ILOG_INFO_HEADNODE("'data' for " << setName << " is <empty>");
00098         }
00099         else if (setName == "config")
00100         {
00101             data = options.GetString("config");
00102             ILOG_INFO_HEADNODE("'data' for " << setName << " is " << data);
00103         }
00104         else
00105         {
00106             data = StringReplaceAll(options.GetString("data"), ":", ";", false);
00107             String additionalData = options.GetString("data::"+setName, "");
00108             if (additionalData.empty() && !setName.empty())
00109                 additionalData = "../" + FileNameBase(setName);
00110             if (!additionalData.empty())
00111             {
00112                 data = additionalData + ";" + data;
00113                 ILOG_INFO_HEADNODE("'data' for " << setName << " is " << data);
00114             }
00115         }
00116 
00117         fs = new FileSystem(data, loc.GetHost());
00118         mMap.Add(loc.ToString(), fs);
00119         return fs;
00120     }

Here is the call graph for this function:


Generated on Thu Jan 13 09:23:28 2011 for ImpalaSrc by  doxygen 1.5.1