Gliffy Diagram | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Adding random access to LCIO files.
...
The last criteria is optional, since there is not an urgent requirement for it, but it would be useful to at least consider how this could be supported in future.
...
Proposed implementation
One way to implement this would be to (optionally) include two new types of records in LCIO files.
...
Code Block | ||
---|---|---|
| ||
<record name="LCIOIndex"> <block name="LCIOIndex" major="1" minor="0"> <data type="int" name="controlWord"/> <data type="int" name="runMin"/> <data type="long" name="baseOffset"/> <data type="int" name="size"/> <repeat count="size"> <if condition="(controlWord&1)==0"> <data type="int" name="runOffset"/> </if> <data type="int" name="eventNumber"/> <if condition="(controlWord&2)==1"> <data type="long" name="locationOffset"/> <else/> <data type="int" name="locationOffset"/> </if> </repeat> </block> </record> |
Gliffy Diagram | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
|
If the file is written with support for random access enabled then the first record in the file will be a LCIORandomAccess record which describes the entire file. This block will then point to one or more LCIORandomAccess records elsewhere in the file, each of which will have an associated LCIOIndex record.
...