next up previous contents index
Next: Operations Up: Window Class Previous: Accessors

Constructors

There are two constructors for the Window class. One takes the name of the storage file to be mapped as the only parameter. This constructor is for the instantiation of the member variable masterWindow in the Arena class.

The other takes eight parameters - window, offset, length, object, before, after, arena, and minimumChunkSize. The object inherits the storage file from the parent window. The range of the mapping is specified by the offset and the length. The before and the after are the Windows before and after the Window to be instantiated. The arena is the caller of the constructor. The minimumChunkSize is literally the minimum size of chunks in the parent Arena, and used when determining the size of the objectTable. The remaining parameter object is used as the hint offset for the initialization of the objectTable, which is implemented in the operation initializeObjectTable().

The constructor maps the specified region of the storage file and constructs the objectTable by tracing the mapped region from the offset object.

The destructor unmaps the mapped region and implicitly releases the objectTable.



Mori Tetsuya / t2y3141592@gmail.com