DIRECTORY AlpineEnvironment USING[FileID, LockMode, PageCount, VolumeID], AlpineInternal USING[FileHandle, FileInstanceHandle, TransHandle]; FileInstance: CEDAR DEFINITIONS = BEGIN Handle: TYPE = AlpineInternal.FileInstanceHandle; Register: PROCEDURE [trans: AlpineInternal.TransHandle, volumeID: AlpineEnvironment.VolumeID, fileID: AlpineEnvironment.FileID] RETURNS [handle: Handle]; Unregister: PROCEDURE [handle: Handle]; FlushTransState: PROCEDURE [trans: AlpineInternal.TransHandle]; GetFileHandle: PROCEDURE [handle: Handle] RETURNS [fileHandle: AlpineInternal.FileHandle]; GetTransHandle: PROCEDURE [handle: Handle] RETURNS [trans: AlpineInternal.TransHandle]; GetVolumeID: PROCEDURE [handle: Handle] RETURNS [volumeID: AlpineEnvironment.VolumeID]; GetFileID: PROCEDURE [handle: Handle] RETURNS [fileID: AlpineEnvironment.FileID]; GetVolumeIDAndFileID: PROCEDURE [handle: Handle] RETURNS [volumeID: AlpineEnvironment.VolumeID, fileID: AlpineEnvironment.FileID]; GetDeltaVersion: PROCEDURE [handle: Handle] RETURNS [delta: LONG INTEGER]; SetMaxDeltaVersion: PROCEDURE [handle: Handle, increment: LONG INTEGER _ 1]; GetHighWaterMark: PROCEDURE [handle: Handle] RETURNS [highWaterMark: AlpineEnvironment.PageCount]; SetHighWaterMark: PROCEDURE [handle: Handle, highWaterMark: AlpineEnvironment.PageCount] RETURNS [oldHighWaterMark: AlpineEnvironment.PageCount]; GetLockMode: PROCEDURE [handle: Handle] RETURNS [lock: AlpineEnvironment.LockMode]; SetLockMode: PROCEDURE [handle: Handle, lock: AlpineEnvironment.LockMode]; GetNextHandleForTrans: PROCEDURE [trans: AlpineInternal.TransHandle, handle: Handle _ NIL] RETURNS [nextHandle: Handle]; END. ΤFileInstance.mesa Copyright c 1985 by Xerox Corporation. All rights reserved. Last edited by Taft on October 25, 1982 11:01 am Kolling on November 12, 1982 4:35 pm Hauser, March 7, 1985 2:52:06 pm PST errors defined in this interface: none. Finds or creates a handle for the supplied trans, volume, and file, and increments use count on the returned handle. If the handle is created, it is also entered in the FileInstance list for its transaction and FileMap.Register is called. errors defined in this interface: none. Decrements use count on handle. If the use count becomes zero and delta version is 0 (i.e., if the file has not been updated), deletes it from the FileInstance list for its transaction and calls FileMap.Unregister. (Updated files are taken care of by FlushTransState.) errors defined in this interface: none. When this is called, it is a fatal error if any handle in this transaction's FileInstance list has useCount # 0 or delta version = 0. Otherwise, FileMap.Unregister is called for each handle. Access to immutable attributes. errors defined in this interface: none. errors defined in this interface: none. errors defined in this interface: none. errors defined in this interface: none. errors defined in this interface: none. Access to read/write attributes. errors defined in this interface: none. Returns the most recent value set by SetMaxDeltaVersion, or zero if SetMaxDeltaVersion hasn't been called. A nonzero value means that the file has been updated by this transaction. errors defined in this interface: none. Sets the delta version to the MAX of increment and its existing value. errors defined in this interface: none. returns the uncommitted highWaterMark, for this transaction. Initialize value is LAST[PageCount]. errors defined in this interface: none. errors defined in this interface: none. errors defined in this interface: none. Enumeration. errors defined in this interface: none. handle = NIL starts a new enumeration, and nextHandle = NIL is returned when the enumeration is exhausted. The FileInstance list is assumed to not be being modified during this enumeration. When handle is non-NIL, not finding it is a fatal error. Hauser, March 7, 1985 2:51:46 pm PST Nodified, added copyright. Κ˜šœ™Icodešœ Οmœ1™<—šœ™Jšœ!™!Jšœ$™$K™$—J˜J˜šΟk ˜ ˜Jšžœ(˜-—˜Jšžœ.˜3J˜J˜——Jšœžœž œ˜!J˜Jšž˜J˜J˜Jšœžœ%˜1J˜J˜šΟnœž œ.˜AJšœ>žœ˜W—Jšœ'™'Jšœο™οJ˜JšŸ œž œ˜'Jšœ'™'JšœŽ™ŽJ˜JšŸœž œ%˜?Jšœ'™'JšœΏ™ΏJ˜J˜J˜Jšœ™J˜JšŸ œž œžœ)˜ZJšœ'™'J˜JšŸœž œžœ%˜WJšœ(™(J˜šŸ œž œžœ ˜:J˜—Jšœ'™'J˜JšŸ œž œžœ$˜QJšœ'™'J˜šŸœž œžœ ˜CJ˜>—Jšœ'™'J˜J˜J˜Jšœ ™ J˜Jš Ÿœž œžœ žœžœ˜JJšœ'™'JšœV™VJšœ^™^J˜JšŸœž œžœžœ˜LJšœ'™'JšœF™FJ˜šŸœž œžœ˜DJ˜—Jšœ(™(JšœQ™QJšœ™J˜šŸœž œ ˜;Jšœžœ1˜U—Jšœ(™(J˜JšŸ œž œžœ$˜SJšœ(™(J˜JšŸ œž œ4˜JJšœ(™(J˜J˜J˜Jšœ ™ J˜šŸœž œ5˜UJšžœžœ˜"—Jšœ'™'JšœP™PJšœK™KJšœ[™[J˜J˜J˜J˜Jšžœ˜™$K™—K™—…—˜q