(FILECREATED "18-Dec-86 17:36:48" {QV}<NOTECARDS>1.3K>NEXT>RGPATCH006.;1 2208   

      changes to:  (VARS RGPATCH006COMS))


(* Copyright (c) 1986 by Xerox Corporation. All rights reserved.)

(PRETTYCOMPRINT RGPATCH006COMS)

(RPAQQ RGPATCH006COMS ((* * New functionality: link labels w/ FilingLinkTypeFlg property T are 
			    considered "filing links" when deciding if a card needs filing. Immediate 
			    reason for this is to support Container cards.)
			 (* * changes to NCCARDS)
			 (FNS NC.CardNeedsFilingP)))
(* * New functionality: link labels w/ FilingLinkTypeFlg property T are considered 
"filing links" when deciding if a card needs filing. Immediate reason for this is to support 
Container cards.)

(* * changes to NCCARDS)

(DEFINEQ

(NC.CardNeedsFilingP
  [LAMBDA (Card)                                             (* Randy.Gobbel "18-Dec-86 17:28")

          (* * Returns non-nil if this card is filed in some not currently filed anywhere unless it's a top level card.
	  Assumes card is active.)



          (* * fgh 11/12/85 Updated to handle Card objects.)



          (* * rht 10/6/86: Now checks for card types that don't have to be filed. Also makes sure that there's at least one 
	  filing link that's within this notefile.)



          (* * rht 12/8/86: Now checks for individual cards that don't require filing.)



          (* * rg 12/18/86: Added check of FilingLinkTypeFlg prop.)


    (LET ((NoteFile (fetch (Card NoteFile) of Card)))
         (AND (NOT (NC.TopLevelCardP Card))
		(NC.ForceFilingForCardTypeP (NC.FetchType Card))
		(NOT (NCP.CardProp Card (QUOTE Don'tRequireFilingFlg)))
		(for Link in (NC.FetchFromLinks Card)
		   never (AND (OR (FMEMB (fetch (Link Label) of Link)
						 (QUOTE (FiledCard SubBox)))
					(GETPROP (fetch (Link Label) of Link)
						   (QUOTE FilingLinkTypeFlg)))
				  (NC.SameNoteFileP NoteFile (fetch (Card NoteFile)
								  of (fetch (Link SourceCard)
									  of Link])
)
(PUTPROPS RGPATCH006 COPYRIGHT ("Xerox Corporation" 1986))
(DECLARE: DONTCOPY
  (FILEMAP (NIL (763 2127 (NC.CardNeedsFilingP 773 . 2125)))))
STOP