(FILECREATED "27-Aug-86 19:07:53" {QV}<NOTECARDS>1.3K>NEXT>FGHPATCH103.;1 16393 changes to: (VARS FGHPATCH103COMS) (RECORDS Card)) (* Copyright (c) 1986 by Xerox Corporation. All rights reserved.) (PRETTYCOMPRINT FGHPATCH103COMS) (RPAQQ FGHPATCH103COMS ((* * Fix to race condition with caching process when fetching types.) (* * from NCCARDS -- NOTE entire system needs recompiling to integrate this.) (RECORDS Card))) (* * Fix to race condition with caching process when fetching types.) (* * from NCCARDS -- NOTE entire system needs recompiling to integrate this.) [DECLARE: EVAL@COMPILE (ACCESSFNS Card ( (* * Instance variables of the card object) (UID (fetch (CardObject UID) of DATUM) (replace (CardObject UID) of DATUM with NEWVALUE)) (NoteFile (LET ((\NF (fetch (CardObject NoteFile) of DATUM))) (COND ((type? NoteFile \NF) \NF) (\NF (replace (CardObject NoteFile) of DATUM with (NC.NoteFileFromNoteFileUID \NF))))) (replace (CardObject NoteFile) of DATUM with NEWVALUE)) (Monitor (fetch (CardObject Monitor) of DATUM) (replace (CardObject Monitor) of DATUM with NEWVALUE)) (Status (fetch (CardObject Status) of DATUM) (replace (CardObject Status) of DATUM with NEWVALUE)) (IndexDirtyFlg (fetch (CardObject IndexDirtyFlg) of DATUM) (replace (CardObject IndexDirtyFlg) of DATUM with NEWVALUE)) (IndexLoc (fetch (CardObject IndexLoc) of DATUM) (replace (CardObject IndexLoc) of DATUM with NEWVALUE)) (MainLoc (fetch (CardObject MainLoc) of DATUM) (replace (CardObject MainLoc) of DATUM with NEWVALUE)) (LinksLoc (fetch (CardObject LinksLoc) of DATUM) (replace (CardObject LinksLoc) of DATUM with NEWVALUE)) (PropListLoc (fetch (CardObject PropListLoc) of DATUM) (replace (CardObject PropListLoc) of DATUM with NEWVALUE)) (TitleLoc (fetch (CardObject TitleLoc) of DATUM) (replace (CardObject TitleLoc) of DATUM with NEWVALUE)) (Title (fetch (CardObject Title) of DATUM) (replace (CardObject Title) of DATUM with NEWVALUE)) (TitleDirtyFlg (fetch (CardObject TitleDirtyFlg) of DATUM) (replace (CardObject TitleDirtyFlg) of DATUM with NEWVALUE)) (* Note the use of NC.GetType if CardType is NIL. This is required to force the access to go to the disk for the card type if the card type caching process is not finished before this fetch is being made. Sort of a kludge.) (Type (OR (fetch (CardObject Type) of DATUM) (NC.GetType DATUM)) (replace (CardObject Type) of DATUM with NEWVALUE)) (ActiveFlg (fetch (CardObject ActiveFlg) of DATUM) (replace (CardObject ActiveFlg) of DATUM with NEWVALUE)) (ActiveCardFlg (fetch (CardObject ActiveFlg) of DATUM) (replace (CardObject ActiveFlg) of DATUM with NEWVALUE)) (CardCache (fetch (CardObject CardCache) of DATUM) (replace (CardObject CardCache) of DATUM with NEWVALUE)) (UserData (fetch (CardObject UserData) of DATUM) (replace (CardObject UserData) of DATUM with NEWVALUE)) (Substance (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache Substance) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache Substance) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache Substance ← NEWVALUE)) NEWVALUE)))) (Links (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache Links) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache Links) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache Links ← NEWVALUE)) NEWVALUE)))) (FromLinks (LET ((\Cache (fetch (CardObject CardCache) of DATUM)) \Links) (AND \Cache (SETQ \Links (fetch (CardCache Links) of \Cache)) (fetch (LinksCache FromLinks) of \Links))) (LET ((\Cache (OR (fetch (CardObject CardCache) of DATUM) (replace (CardObject CardCache) of DATUM with (create CardCache)))) \Links) (SETQ \Links (fetch (CardCache Links) of \Cache)) (COND (\Links (replace (LinksCache FromLinks) of \Links with NEWVALUE)) (T (replace (CardCache Links) of \Cache with (create LinksCache FromLinks ← NEWVALUE)) NEWVALUE)))) (ToLinks (LET ((\Cache (fetch (CardObject CardCache) of DATUM)) \Links) (AND \Cache (SETQ \Links (fetch (CardCache Links) of \Cache)) (fetch (LinksCache ToLinks) of \Links))) (LET ((\Cache (OR (fetch (CardObject CardCache) of DATUM) (replace (CardObject CardCache) of DATUM with (create CardCache)))) \Links) (SETQ \Links (fetch (CardCache Links) of \Cache)) (COND (\Links (replace (LinksCache ToLinks) of \Links with NEWVALUE)) (T (replace (CardCache Links) of \Cache with (create LinksCache ToLinks ← NEWVALUE)) NEWVALUE)))) (GlobalLinks (LET ((\Cache (fetch (CardObject CardCache) of DATUM)) \Links) (AND \Cache (SETQ \Links (fetch (CardCache Links) of \Cache)) (fetch (LinksCache GlobalLinks) of \Links))) (LET ((\Cache (OR (fetch (CardObject CardCache) of DATUM) (replace (CardObject CardCache) of DATUM with (create CardCache)))) \Links) (SETQ \Links (fetch (CardCache Links) of \Cache)) (COND (\Links (replace (LinksCache GlobalLinks) of \Links with NEWVALUE)) (T (replace (CardCache Links) of \Cache with (create LinksCache GlobalLinks ← NEWVALUE)) NEWVALUE)))) (PropList (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache PropList) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache PropList) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache PropList ← NEWVALUE)) NEWVALUE)))) (Region (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache Region) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache Region) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache Region ← NEWVALUE)) NEWVALUE)))) (SavedRegion (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache SavedRegion) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache SavedRegion) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache SavedRegion ← NEWVALUE)) NEWVALUE)))) (ItemDate (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache ItemDate) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache ItemDate) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache ItemDate ← NEWVALUE)) NEWVALUE)))) (LinksDate (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache LinksDate) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache LinksDate) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache LinksDate ← NEWVALUE)) NEWVALUE)))) (TitleDate (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache TitleDate) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache TitleDate) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache TitleDate ← NEWVALUE)) NEWVALUE)))) (PropListDate (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache PropListDate) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache PropListDate) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache PropListDate ← NEWVALUE)) NEWVALUE)))) (LinksDirtyFlg (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache LinksDirtyFlg) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache LinksDirtyFlg) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache LinksDirtyFlg ← NEWVALUE)) NEWVALUE)))) (PropListDirtyFlg (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache PropListDirtyFlg) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache PropListDirtyFlg) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache PropListDirtyFlg ← NEWVALUE)) NEWVALUE)))) (SubstanceDirtyFlg (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache SubstanceDirtyFlg) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache SubstanceDirtyFlg) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache SubstanceDirtyFlg ← NEWVALUE)) NEWVALUE)))) (NewCardFlg (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache NewCardFlg) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache NewCardFlg) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache NewCardFlg ← NEWVALUE)) NEWVALUE)))) (BeingDeletedFlg (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (AND \Cache (fetch (CardCache BeingDeletedFlg) of \Cache))) (LET ((\Cache (fetch (CardObject CardCache) of DATUM))) (COND (\Cache (replace (CardCache BeingDeletedFlg) of \Cache with NEWVALUE)) (T (replace (CardObject CardCache) of DATUM with (create CardCache BeingDeletedFlg ← NEWVALUE)) NEWVALUE)))) (* * Class variables of the card object {class == card type}) (SuperType (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField SuperType NoteCardType))) (LinkDisplayMode (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField LinkDisplayMode NoteCardType))) (DefaultWidth (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField DefaultWidth NoteCardType))) (DefaultHeight (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField DefaultHeight NoteCardType))) (LinkAnchorModesSupported (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField LinkAnchorModesSupported NoteCardType))) (LinkIconAttachedBitMap (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField LinkIconAttachedBitMap NoteCardType))) (LeftButtonMenuItems (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField LeftButtonMenuItems NoteCardType))) (MiddleButtonMenuItems (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField MiddleButtonMenuItems NoteCardType))) (* * Methods of the card object {class == card type}) (MakeFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField MakeFn NoteCardType))) (EditFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField EditFn NoteCardType))) (QuitFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField QuitFn NoteCardType))) (GetFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField GetFn NoteCardType))) (PutFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField PutFn NoteCardType))) (CopyFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField CopyFn NoteCardType))) (MarkDirtyFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField MarkDirtyFn NoteCardType))) (DirtyPFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField DirtyPFn NoteCardType))) (CollectLinksFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField CollectLinksFn NoteCardType))) (DeleteLinksFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField DeleteLinksFn NoteCardType))) (UpdateLinkIconsFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField UpdateLinkIconsFn NoteCardType))) (InsertLinkFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField InsertLinkFn NoteCardType))) (TranslateWindowPositionFn (LET ((NoteCardType (fetch (Card Type) of DATUM))) (NC.GetCardTypeField TranslateWindowPositionFn NoteCardType)))) (CREATE (create CardObject)) (TYPE? (TYPE? CardObject DATUM))) ] (PUTPROPS FGHPATCH103 COPYRIGHT ("Xerox Corporation" 1986)) (DECLARE: DONTCOPY (FILEMAP (NIL))) STOP