|
EPICS ARCHIVER V4
|
Index based on list of sub-archives. More...
#include <ListIndex.h>
Public Member Functions | |
| ~ListIndex () | |
| Destructor. | |
| virtual void | open (const std::string &filename, ReadWrite readwrite=ReadOnly) |
| Open the index. More... | |
| virtual void | close () |
| Closes the index. | |
| virtual Result * | addChannel (const std::string &channel) |
| Adds channel. | |
| virtual Result * | findChannel (const std::string &channel) |
| Returns result of the specified channel. | |
| virtual NameIterator * | iterator () |
| Returns iterator. | |
Public Member Functions inherited from Index | |
| Index () | |
| Constructor. | |
| virtual | ~Index () |
| Destructor. | |
| virtual void | open (const stdString &filename, ReadWrite readwrite=ReadOnly)=0 |
| Open an index. More... | |
| const std::string & | getFilename () |
| Get the basename. More... | |
| const std::string & | getDirectory () |
| Get the directory. More... | |
| const stdString & | getFullName () |
| virtual Result * | addChannel (const stdString &channel)=0 |
| Add a channel to the index. More... | |
| virtual Result * | findChannel (const stdString &channel)=0 |
| Obtain the RTree for a channel. More... | |
Additional Inherited Members | |
Public Types inherited from Index | |
| enum | ReadWrite { ReadOnly, ReadAndWrite } |
| Modes used for open. | |
Index based on list of sub-archives.
Ideally, an index configuration conforming to indexfile.dtd is used to create a master index via the ArchiveIndexTool. Alternatively, that list of sub-archives can be used with a ListIndex, which then acts like a master index by simply querying the sub-archives one by one:
It is important to remember that the samples are not "merged" in any way. When data for a channel is requested, the very first sub-archive which includes that channel is used. Assume the following sub-archive: 1) Channels A, B, X 2) Channels C, D, X (but different time range for X)
We can now request data for channels A, B, C and D as if they were all in one combined archive. For channel X, however, will will mostly get data from sub-archive 1, EXCEPT(!!) when we were just looking at channels C or D from archive 2, because for efficiency reasons, any channel lookup will first try the currently open sub-archive.
Conclusion: You will often not able to predict what sub-archive you are using when channels are in more than one sub-archive. You should only use the ListIndex for non-overlapping sub-archives. This makes some sense, because why would you want to archive channels in more than one sub-archive in the first place?
|
virtual |
Open the index.
| filename,: | Name of a file that lists sub-archives. |
| readwrite,: | Must be 'true', because ListIndex doesn't support writing. |
| GenericException | On error, including readonly==false. |
1.8.5