KaliVeda
Toolkit for HIC analysis
|
Manages access to one or more data repositories.
The data repository manager is set up and initialised in the following way:
new KVDataRepositoryManager; gDataRepositoryManager->Init();
<p<blockquote>
The available data repositories are defined in the user's $HOME/.kvrootrc file (see KVDataRepository for details of configuration).
If more than one repository is defined, which one will be "active" (gDataRepository) after initialisation of the data repository manager ? You can define the default repository by setting the variable
DataRepository.Default: [name]
in your .kvrootrc file. If you don't, the default repository "by default" will be either: the data repository named "default" if there is one; or the last one defined in your .kvrootrc.
Definition at line 47 of file KVDataRepositoryManager.h.
#include <KVDataRepositoryManager.h>
Public Member Functions | |
KVDataRepositoryManager () | |
Default constructor. | |
virtual | ~KVDataRepositoryManager () |
Destructor. | |
KVDataSet * | GetDataSet (const Char_t *repository, const Char_t *dataset) const |
Return pointer to named dataset in the given repository. | |
const TList * | GetListOfRepositories () const |
KVDataRepository * | GetRepository (const Char_t *name) const |
void | Init () |
void | Print (Option_t *opt="") const |
Private Attributes | |
TList | fRepositories |
list of available repositories | |
KVDataRepositoryManager::KVDataRepositoryManager | ( | ) |
Default constructor.
Definition at line 31 of file KVDataRepositoryManager.cpp.
|
virtual |
Destructor.
Definition at line 43 of file KVDataRepositoryManager.cpp.
KVDataSet * KVDataRepositoryManager::GetDataSet | ( | const Char_t * | repository, |
const Char_t * | dataset | ||
) | const |
Return pointer to named dataset in the given repository.
Definition at line 200 of file KVDataRepositoryManager.cpp.
|
inline |
Definition at line 59 of file KVDataRepositoryManager.h.
KVDataRepository * KVDataRepositoryManager::GetRepository | ( | const Char_t * | name | ) | const |
Return pointer to data repository with given name. Data repository names are defined in .kvrootrc file by lines such as
DataRepository: default +DataRepository: ccali
Definition at line 149 of file KVDataRepositoryManager.cpp.
void KVDataRepositoryManager::Init | ( | ) |
Read .kvrootrc and set up all data repositories it defines.
The default data repository (gDataRepository) is defined by the environment variable DataRepository.Default (default value = "default").
For this repository, KVDataRepository::cd() will be called and gDataRepository and gDataSetManager will point, respectively, to the repository and to its data set manager.
If the repository corresponding to DataRepository.Default is not found, the last repository defined in the .kvrootrc file will be made default. make sure KaliVeda environment is initialised
Definition at line 67 of file KVDataRepositoryManager.cpp.
Print list of repositories opt = "all" : print full configuration information for each repository
Definition at line 168 of file KVDataRepositoryManager.cpp.
|
private |
list of available repositories
Definition at line 49 of file KVDataRepositoryManager.h.