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

FileLocator.h

Go to the documentation of this file.
00001 #ifndef Impala_Persistency_FileLocator_h
00002 #define Impala_Persistency_FileLocator_h
00003 
00004 #include "Persistency/Locator.h"
00005 
00006 namespace Impala
00007 {
00008 namespace Persistency
00009 {
00010 
00011 
00015 class FileLocator : public Locator
00016 {
00017 public:
00018 
00019     FileLocator(CString name)
00020         : Locator("file:", "dot")
00021     {
00022         mName = name;
00023     }
00024 
00025     FileLocator(CString name, CmdOptions& options)
00026         : Locator("dot", options)
00027     {
00028         mName = name;
00029     }
00030 
00031     FileLocator(const Locator& base, CString name)
00032         : Locator(base.GetProtocol(), base.GetHost(), base.GetDataSet())
00033     {
00034         mName = name;
00035     }
00036 
00037     virtual
00038     ~FileLocator()
00039     {
00040     }
00041 
00042     String
00043     GetName() const
00044     {
00045         return mName;
00046     }
00047 
00048     String
00049     ToString() const
00050     {
00051         return "FileLocator(" + GetProtocol() + "," + GetHost()
00052             + "," + GetDataSet() + "," + GetName() + ")";
00053     }
00054 
00055 private:
00056 
00057     String mName;
00058 
00059     ILOG_VAR_DEC;
00060 };
00061 
00062 ILOG_VAR_INIT(FileLocator, Impala.Persistency);
00063 
00064 std::ostream&
00065 operator<< (std::ostream& os, const FileLocator& loc)
00066 {
00067     os << loc.ToString();
00068     return os;
00069 }
00070 
00071 } // namespace Persistency
00072 } // namespace Impala
00073 
00074 #endif

Generated on Fri Mar 19 09:31:43 2010 for ImpalaSrc by  doxygen 1.5.1