<<>> <> <> <> <> <> <> <> <> (cedar-directory "Rope") (define-ref-type "Scheme" "Symbol") ROPE: TYPE ~ Rope.ROPE; <> (cedar-imports "CedarProcess") (define-enum-type "CedarProcess" "Priority" (background normal foreground excited real-time)) (define-proc (set-priority priority) "sets priority (background normal foreground excited real-time), returns old priority level" result _ SymbolForPriority[CedarProcess.GetPriority[]]; CedarProcess.SetPriority[ThePriority[priority]]; ) <> (cedar-imports "ThisMachine" "ProcessorFace") (define-proc (This-Machine-Name (namespace)) "Returns a string; namespace is 'arpa, 'xns, 'pup, ..." result _ StringFromRope[ThisMachine.Name[SELECT namespace FROM $arpa => $Arpa, $xns => $XNS, $pup => $Pup, undefined => NIL, ENDCASE => TheSymbol[namespace]]]; ) (define-proc (This-Machine-Address (namespace)) "Returns a string; namespace is 'arpa, 'xns, 'pup, ..." result _ StringFromRope[ThisMachine.Address[SELECT namespace FROM $arpa => $Arpa, $xns => $XNS, $pup => $Pup, undefined => NIL, ENDCASE => TheSymbol[namespace]]]; ) (define-proc (This-Machine-ID) "Returns a string like \"1-435-140-188\"" result _ StringFromRope[ThisMachine.ProcessorID[$Decimal]]; ) (define-proc (This-Machine-Type) "Returns 'sun3, 'sun4, ..." result ¬ ProcessorFace.GetProcessorTypeName[ProcessorFace.GetProcessorType[]]; ) <> (cedar-imports "SafeStorage") (define-proc (bytes-allocated) "number of words allocated since the beginning" RETURN [MakeFixnum[SafeStorage.CurrentByteCount[]]]; ) (define-proc (gc (trace-and-sweep?)) "call the garbage collector" SafeStorage.ReclaimCollectibleObjects[suspendMe: TRUE, traceAndSweep: traceAndSweepP=true]; ) <> (cedar-imports "ViewerTools") (define-proc (get-selection-contents) "Return the contents of the Tioga selection as a string." result _ StringFromRope[ViewerTools.GetSelectionContents[]]; )