File: DBIndexPage.mesa
Copyright © 1985 by Xerox Corporation. All rights reserved.
Willie-Sue, February 15, 1985 3:41:24 pm PST
Widom, September 4, 1985 9:07:35 pm PDT
Donahue, November 13, 1985 11:42:12 am PST
Purpose: Maintains DBIndex.Page records for database pages. Keeps a list of currently
active DBIndex.Pages, which acts as a cache for frequently accessed pages.
Last edited by:
Suzuki: 2-Apr-81 16:09:21
Cattell: September 21, 1982 9:23 pm
DIRECTORY
DBCommon USING[DBPage, Segment],
DBIndex USING [Core, Page, RealIndexHandle];
DBIndexPage: CEDAR DEFINITIONS =
BEGIN
BadPage: SIGNAL; -- if page is not a B-Tree page
DestroyPageList: PROC [s: DBCommon.Segment];
Frees the list of page records (DBIndex.Pages) that DBIndexPage maintains
DestroyPage: PROC [segment: DBCommon.DBPage, p: DBIndex.Page, db: DBCommon.DBPage];
Unlock the page and de-allocate the page in the database for re-use.
UnlockPage: PROC [p: DBIndex.Page];
Should be called when the client no longer has pointers into page and p thrown away
WritePage: PROC [p: DBIndex.Page];
Mark page p as having been modified, but keep locked.
WriteAndUnlockPage: PROC [p: DBIndex.Page];
Call when page no longer in use, and page has been modified.
CreateEmptyPage: PROC [tree: DBIndex.RealIndexHandle, level: CARDINAL, s: DBCommon.DBPage]
RETURNS [DBIndex.Page];
Allocates a new DBCommon.DBPage with associated DBIndex.Page, level = 1 if it is a leaf
GetPage: PROC [
tree: DBIndex.RealIndexHandle, db: DBCommon.DBPage, level: CARDINAL] RETURNS [DBIndex.Page];
Makes DBIndex.Page pointing to given DBCommon.DBPage.
CheckTag: PROC[LONG POINTER TO DBIndex.Core];
END.
Change Log
By Cattell September 22, 1982 12:57 pm: Changed names to be clearer. Use UnlockPage instead of FreePage, GetPage instead of CreateOldPage, etc.
Changed by Willie-Sue on February 15, 1985
made Cedar, added tioga formatting