MODULE ZoomBundle;
Generated by m3bundle; see its manpage.
IMPORT Bundle, BundleRep, Text;
IMPORT Thread, Wr, TextWr;
TYPE T = Bundle.T OBJECT OVERRIDES
get := LookUp;
getNames := GetNames;
END;
TYPE Texts = REF ARRAY OF TEXT;
VAR
bundle: T := NIL;
names : Texts := NIL;
PROCEDURE Get(): Bundle.T =
BEGIN
IF (bundle = NIL) THEN bundle := NEW (T) END;
RETURN bundle;
END Get;
PROCEDURE GetNames (<*UNUSED*> self: T): Texts =
BEGIN
IF names = NIL THEN
names := NEW (Texts, NUMBER (Names));
names^ := Names;
END;
RETURN names;
END GetNames;
PROCEDURE LookUp (<*UNUSED*> self: T; element: TEXT): TEXT =
BEGIN
FOR i := 0 TO LAST (Names)-1 DO
IF Text.Equal (Names[i], element) THEN
IF Elements[i] = NIL THEN Elements[i] := GetElt (i) END;
RETURN Elements[i];
END;
END;
RETURN NIL;
END LookUp;
CONST Names = ARRAY [0..24] OF TEXT {
"ViewClass.i3",
"EventData.fv",
"ViewClass3D.m3",
"TranscriptView.fv",
"Obliq3DView.i3",
"AlgClass.m3",
"IE3D.i3",
"GEFView.m3",
"JunoView.m3",
"TranscriptView.m3",
"DataView.m3",
"ViewClass3D.i3",
"IE.m3",
"ObliqView.m3",
"AlgClass.i3",
"ViewClass.m3",
"GEFView.i3",
"JunoView.i3",
"TranscriptView.i3",
"Obliq3DView.m3",
"DataView.i3",
"IE3D.m3",
"IE.i3",
"ObliqView.i3",
NIL
};
VAR Elements := ARRAY [0..24] OF TEXT {
E0,
E1,
E2,
E3,
E4,
NIL (* E5 .. E5_2 *),
E6,
NIL (* E7 .. E7_0 *),
NIL (* E8 .. E8_1 *),
NIL (* E9 .. E9_1 *),
E10,
E11,
NIL (* E12 .. E12_0 *),
NIL (* E13 .. E13_2 *),
E14,
E15,
E16,
E17,
E18,
NIL (* E19 .. E19_1 *),
E20,
NIL (* E21 .. E21_1 *),
E22,
E23,
NIL
};
PROCEDURE GetElt (n: INTEGER): TEXT =
<*FATAL Thread.Alerted, Wr.Failure *>
VAR wr := TextWr.New ();
BEGIN
CASE n OF
| 5 =>
Wr.PutText (wr, E5);
Wr.PutText (wr, E5_0);
Wr.PutText (wr, E5_1);
Wr.PutText (wr, E5_2);
| 7 =>
Wr.PutText (wr, E7);
Wr.PutText (wr, E7_0);
| 8 =>
Wr.PutText (wr, E8);
Wr.PutText (wr, E8_0);
Wr.PutText (wr, E8_1);
| 9 =>
Wr.PutText (wr, E9);
Wr.PutText (wr, E9_0);
Wr.PutText (wr, E9_1);
| 12 =>
Wr.PutText (wr, E12);
Wr.PutText (wr, E12_0);
| 13 =>
Wr.PutText (wr, E13);
Wr.PutText (wr, E13_0);
Wr.PutText (wr, E13_1);
Wr.PutText (wr, E13_2);
| 19 =>
Wr.PutText (wr, E19);
Wr.PutText (wr, E19_0);
Wr.PutText (wr, E19_1);
| 21 =>
Wr.PutText (wr, E21);
Wr.PutText (wr, E21_0);
Wr.PutText (wr, E21_1);
ELSE (*skip*)
END;
RETURN TextWr.ToText (wr);
END GetElt;
CONST E0 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:56:28 PST 1995 by kalsow *)\n(* modified on Wed Feb 17 17:0"
& "4:21 PST 1993 by johnh *)\n(* modified on Tue Jun 9 00:35:21 19"
& "92 by mhb *)\n\n(**********************************************"
& "***********************\n|* NOTE: This file is generated automatically"
& " from the event\n|* definition file #(_ALGNAME_).evt.\n|********"
& "*************************************************************)\n\n<* PR"
& "AGMA LL *>\n\nINTERFACE #(_ALGNAME_)ViewClass;\n\n$Thread\n$View\n#(_IM"
& "PORTS_)\n\nTYPE\n T <: Public;\n Public = View.T OBJECT\n METHOD"
& "S\n <*LL = {} *>\n#{_OUTPUT\n oe#(_EVENT_) (#(_ARGSTR_)) RA"
& "ISES {Thread.Alerted};\n#}\n <*LL = VBT.mu *>\n#{_UPDATE\n "
& "ue#(_EVENT_) (#(_ARGSTR_)) RAISES {Thread.Alerted};\n#}\n END;\n\n"
& "END #(_ALGNAME_)ViewClass.\n";
CONST E1 =
"; Copyright (C) 1995, Digital Equipment Corporation.\n; All rights rese"
& "rved.\n; See the file COPYRIGHT for a full description.\n;\n; Last modi"
& "fied on Wed Feb 8 15:29:09 PST 1995 by kalsow\n\n;********************"
& "************************************************\n; NOTE: This file is"
& " generated automatically from the event \n; definition file #(_A"
& "LGNAME_).evt.\n;*******************************************************"
& "*************\n\n(VBox\n (Border (Pen 1)\n (Shape\n (Height 75"
& " - 25 + Inf)\n (Viewport\n (HBox\n (Glue 4 + Inf)\n"
& " (VBox\n (Glue 6)\n (Shape (Height 16 + "
& "0)\n (HBox Fill (Shape (Width + 0) (Height + 0) \n "
& " \"Code View events: Stop? \") \n "
& " (Boolean %stopatCodeEvents =TRUE \"\")\n (Glu"
& "e 10)\n (Shape (Width + 0) (Height + 0) \"Weight: \""
& ")\n (Shape (Width 80) (Numeric %waitatCodeEvents =1 "
& "\n (Min 0) (Max 100)))))\n"
& " (Glue 6)\n#{_OUTPUT\n (Shape (Height 16 + 0)\n "
& " (HBox Fill (Shape (Width + 0) (Height + 0) \n "
& " \"#(_EVENT_): Stop? \") \n (Bool"
& "ean %stopAt#(_EVENT_) =TRUE \"\")\n (Glue 10)\n "
& " (Shape (Width + 0) (Height + 0) \"Weight: \")\n "
& " (Shape (Width 80) (Numeric %waitAt#(_EVENT_) =1 \n "
& " (Min 0) (Max 100)))))\n "
& " (Glue 6)\n#}\n )\n (Glue 4)\n (VBox\n "
& " (Glue 5)\n (Shape (Width + 0) (Height 16 + 0) \"Cts:\""
& ")\n (Button %eventCounts\n (VBox\n#{_OUTPUT\n "
& " (Glue 6)\n (HBox Fill (Shape (Width + 0) ("
& "Height 16 + 0) \n (Text %ctOf#(_EVENT_"
& ") \"0\")))\n#}\n (Glue 3))))\n Fill\n "
& "(Glue 4 + Inf)\n )\n )\n )\n )\n)\n";
CONST E2 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:57:32 PST 1995 by kalsow *)\n(* modified on Sun Nov 28 23:0"
& "8:58 PST 1993 by najork *)\n\n(***************************************"
& "******************************\n|* NOTE: This file is generated automa"
& "tically from the event\n|* definition file #(_ALGNAME_).evt.\n|*"
& "********************************************************************)\n"
& "\n<* PRAGMA LL *>\n\nMODULE #(_ALGNAME_)3DViewClass;\n\n$View3D\n$ViewC"
& "lass\n$ZeusClass\n$#(_ALGNAME_)AlgClass\n#(_IMPORTS_)\n\nREVEAL\n T = "
& "Public BRANDED OBJECT\n OVERRIDES\n isCompat := IsCompat;\n "
& " <*LL = {} *>\n#{_OUTPUT\n oe#(_EVENT_) := #(_EVENT_);\n#}\n"
& " <*LL = VBT.mu *>\n#{_UPDATE\n ue#(_EVENT_) := #(_EVENT_);\n"
& "#}\n END;\n\nPROCEDURE IsCompat (v: T; alg: ZeusClass.T): BOOLEAN "
& "=\n BEGIN\n RETURN ISTYPE(alg, #(_ALGNAME_)AlgClass.T) AND View3D.T"
& ".isCompat (v, alg);\n END IsCompat;\n\n#{_OUTPUT\nPROCEDURE #(_EVENT_)"
& " (view: T\n#{\n ; <*UNUSED*> #(_ARGMODE_)#(_ARGNAME_): #(_ARGTYPE_)\n"
& "#}\n) =\n <*LL = {} *>\n BEGIN\n view.evtHandled := FALSE;\n END "
& "#(_EVENT_);\n\n#}\n\n#{_UPDATE\nPROCEDURE #(_EVENT_) (view: T\n#{\n "
& "; <*UNUSED*> #(_ARGMODE_)#(_ARGNAME_): #(_ARGTYPE_)\n#}\n) =\n <*LL = "
& "VBT.mu *>\n BEGIN\n view.evtHandled := FALSE;\n END #(_EVENT_);\n\n"
& "#}\n\nBEGIN\nEND #(_ALGNAME_)3DViewClass.\n";
CONST E3 =
"; Copyright (C) 1995, Digital Equipment Corporation.\n; All rights rese"
& "rved.\n; See the file COPYRIGHT for a full description.\n;\n; Last modi"
& "fied on Wed Feb 8 15:37:06 PST 1995 by kalsow\n\n;********************"
& "************************************************\n; NOTE: This file is"
& " generated automatically from the event \n; definition file #(_A"
& "LGNAME_).evt.\n;*******************************************************"
& "*************\n\n(VBox\n (Rim\n (Pen 2)\n (HBox\n (VBox (Gl"
& "ue 4) (Shape (Height + Inf) (Button %clear \"CLEAR\")) (Glue 4))\n "
& " (Glue 4)\n (VBox\n (Boolean =TRUE %alg (Text LeftAlign \"A"
& "lgorithm events\"))\n (Boolean =FALSE %zeus (Text LeftAlign \"Ze"
& "us events\"))\n (Boolean =TRUE %args (Text LeftAlign \"Display a"
& "rgs to events\")))\n Fill))\n (Bar 1)\n (Shape (ShadowSize 0) (H"
& "eight 200 + INF) (TextEdit ReadOnly %transcript)))\n";
CONST E4 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Wed Feb "
& " 8 15:34:46 PST 1995 by kalsow *)\n(* modified on Mon Jan 24 10:0"
& "0:27 PST 1994 by najork *)\n(* modified on Sat Jul 17 10:55:21 PD"
& "T 1993 by mhb *)\n(* modified on Wed Feb 17 16:47:18 PST 1993 "
& "by johnh *)\n\n(*****************************************************"
& "****************\n|* NOTE: This file is generated automatically from t"
& "he event\n|* definition file #(_ALGNAME_).evt.\n|***************"
& "******************************************************)\n\nINTERFACE #("
& "_ALGNAME_)#(_VIEWNAME_)Obliq3DView;\nEND #(_ALGNAME_)#(_VIEWNAME_)Obliq"
& "3DView.\n\n";
CONST E5 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:48:22 PST 1995 by kalsow *)\n(* modified on Wed Feb 17 16:4"
& "6:18 PST 1993 by johnh *)\n(* modified on Thu Sep 24 10:59:20 PD"
& "T 1992 by mhb *)\n\n(**********************************************"
& "***********************\n|* NOTE: This file is generated automatically"
& " from the event\n|* definition file #(_ALGNAME_).evt.\n|********"
& "*************************************************************)\n\nMODUL"
& "E #(_ALGNAME_)AlgClass;\n\n$Algorithm\n$Fmt\n$FormsVBT\n$Rd\n$Text\n$VB"
& "T\n$Wr\n$ZeusClass\n$ZeusPanel\n$ZeusUtil\n#(_IMPORTS_)\n\n<* PRAGMA LL"
& " *>\n\n(* Fix any FormsVBT errors; don\'t handle exceptions for them. *"
& ")\n<* FATAL FormsVBT.Error, FormsVBT.Unimplemented *>\n\n\nREVEAL\n T "
& "= Public BRANDED OBJECT\n OVERRIDES\n <* LL = VBT.mu *>\n "
& " init := #(_ALGNAME_)DefaultInit;\n snapshot := #(_ALGNAME_"
& ")DefaultSnapshot;\n restore := #(_ALGNAME_)DefaultRestore;\n "
& " updateEventCounts := #(_ALGNAME_)DefaultUpdateCts;\n#{_FEEDBACK\n "
& " fe#(_EVENT_) := #(_EVENT_);\n#}\n END;\n\nPROCEDURE #(_ALGNA"
& "ME_)DefaultInit (v: T): Algorithm.T =\n <* LL = VBT.mu *>\n PROCEDURE"
& " Attach (id: TEXT; proc: FormsVBT.Proc) =\n BEGIN\n FormsVBT.At"
& "tachProc(v.eventData, id, proc, v);\n END Attach;\n BEGIN\n v.ev"
& "entData := ZeusPanel.NewForm(\"#(_ALGNAME_)EventData.fv\");\n Attach"
& "(\"stopatCodeEvents\", #(_ALGNAME_)DoIt);\n Attach(\"waitatCodeEvent"
& "s\", #(_ALGNAME_)DoIt);\n Attach(\"eventCounts\", #(_ALGNAME_)Refres"
& "hCts);\n#{_OUTPUT\n Attach(\"stopAt#(_EVENT_)\", #(_ALGNAME_)DoIt);\n"
& " Attach(\"waitAt#(_EVENT_)\", #(_ALGNAME_)DoIt);\n#}\n FromFV (v."
& "eventData, v); (* Get FV and internal data in sync *)\n RETURN Al"
& "gorithm.T.init(v);\n END #(_ALGNAME_)DefaultInit;\n\nPROCEDURE #(_ALGN"
& "AME_)DoIt ( ";
CONST E5_0 =
" fv : FormsVBT.T;\n e : TEXT;\n "
& " arg: REFANY;\n <*UNUSED*> t : VBT.Time"
& "Stamp) =\n <* LL = VBT.mu *>\n BEGIN\n IF Text.Equal(e, \"stopatCo"
& "deEvents\") THEN\n NARROW(arg, T).stopatCodeEvents :=\n F"
& "ormsVBT.GetBoolean(fv, \"stopatCodeEvents\");\n END;\n IF Text.Eq"
& "ual(e, \"waitatCodeEvents\") THEN\n NARROW(arg, T).waitatCodeEvent"
& "s :=\n FormsVBT.GetInteger(fv, \"waitatCodeEvents\");\n END"
& ";\n#{_OUTPUT\n IF Text.Equal(e, \"stopAt#(_EVENT_)\") THEN\n NA"
& "RROW(arg, T).eventDataRec.stopAt#(_EVENT_) :=\n FormsVBT.GetBo"
& "olean(fv, \"stopAt#(_EVENT_)\");\n END;\n IF Text.Equal(e, \"wait"
& "At#(_EVENT_)\") THEN\n NARROW(arg, T).eventDataRec.waitAt#(_EVENT_"
& ") :=\n FormsVBT.GetInteger(fv, \"waitAt#(_EVENT_)\");\n END"
& ";\n#}\n END #(_ALGNAME_)DoIt;\n\nPROCEDURE #(_ALGNAME_)RefreshCts (\n "
& " <*UNUSED*> fv : FormsVBT.T;\n <*UNUSED*>"
& " e : TEXT;\n arg : REFANY;\n "
& " <*UNUSED*> t : VBT.TimeStamp) =\n <* LL = VBT.mu *>\n BEGIN\n N"
& "ARROW(arg, T).updateEventCounts(FALSE);\n END #(_ALGNAME_)RefreshCts;\n"
& "\nPROCEDURE FromFV (fv : FormsVBT.T; alg: T) =\n <* LL = VBT.mu *>\n "
& "BEGIN\n alg.stopatCodeEvents :=\n FormsVBT.GetBoolean(fv, \"s"
& "topatCodeEvents\");\n alg.waitatCodeEvents :=\n FormsVBT.GetI"
& "nteger(fv, \"waitatCodeEvents\");\n#{_OUTPUT\n alg.eventDataRec.stop"
& "At#(_EVENT_) :=\n FormsVBT.GetBoolean(fv, \"stopAt#(_EVENT_)\");"
& "\n alg.eventDataRec.waitAt#(_EVENT_) :=\n FormsVBT.GetInteger"
& "(fv, \"waitAt#(_EVENT_)\");\n#}\n END FromFV;\n\n<*UNUSED*>\nPROCEDURE"
& " ToFV (fv : FormsVBT.T; alg: T) =\n <* LL = VBT.mu *>\n BEGIN\n Fo"
& "rmsVBT.PutBoolean(fv, \"stopatCodeEvents\", alg.stopatCodeEvents);\n "
& " FormsVBT.PutInteger(fv, \"waitatCodeEvents\", alg.waitatCodeEvents);\n"
& "#{_OUTPUT\n FormsVBT.PutBoolean(fv, \"stopAt#(_EVENT_)\",\n "
& " alg.eventDataRec.stopAt#(_EVENT_));\n FormsVBT.PutInt"
& "eger(fv, \"waitAt#(_EVENT_)\",\n ";
CONST E5_1 =
" alg.eventDataRec.waitAt#(_EVENT_));\n#}\n Cou"
& "ntsToFV (fv, alg);\n END ToFV;\n\nPROCEDURE CountsToFV (fv : FormsVBT."
& "T; alg: T) =\n <* LL = VBT.mu *>\n BEGIN\n#{_OUTPUT\n FormsVBT.Put"
& "Text(fv, \"ctOf#(_EVENT_)\",\n Fmt.Int(alg.event"
& "DataRec.ctOf#(_EVENT_)));\n#}\n END CountsToFV;\n\nPROCEDURE #(_ALGNAM"
& "E_)DefaultUpdateCts ( v: T; reset: BOOLEAN) =\n <* LL = VBT.mu *>\n B"
& "EGIN\n IF reset THEN\n#{_OUTPUT\n v.eventDataRec.ctOf#(_EVENT_)"
& " := 0;\n#}\n END;\n CountsToFV (v.eventData, v);\n END #(_ALGNAM"
& "E_)DefaultUpdateCts;\n\n\nPROCEDURE #(_ALGNAME_)DefaultSnapshot (v: T; "
& "wr: Wr.T)\n RAISES {ZeusClass.Error} =\n <* LL = VBT.mu *>\n BEGIN\n"
& " TRY\n Wr.PutChar(wr, \'(\')\n EXCEPT\n ELSE\n RAISE"
& " ZeusClass.Error(\n \"#(_ALGNAME_)AlgClass.#(_ALGNAME_)Default"
& "Snapshot write error\");\n END;\n IF v.eventData = NIL THEN\n "
& " RAISE ZeusClass.Error(\n \"#(_ALGNAME_)AlgClass.#(_ALGNAME_)"
& "DefaultSnapshot: \" &\n \"eventData not set!\");\n END;\n "
& " TRY\n v.eventData.snapshot(wr)\n EXCEPT\n FormsVBT.Error"
& " (msg) =>\n RAISE ZeusClass.Error(\n \"#(_ALGNAME_)AlgC"
& "lass.#(_ALGNAME_)DefaultSnapshot FV error: \"\n & msg);\n E"
& "LSE\n RAISE ZeusClass.Error(\n \"#(_ALGNAME_)AlgClass.#(_AL"
& "GNAME_)DefaultSnapshot error\");\n END;\n Algorithm.T.snapshot(v,"
& " wr);\n TRY\n Wr.PutChar(wr, \')\')\n EXCEPT\n ELSE\n "
& " RAISE ZeusClass.Error(\n \"#(_ALGNAME_)AlgClass.#(_ALGNAME_)"
& "DefaultSnapshot write error\");\n END;\n END #(_ALGNAME_)DefaultSna"
& "pshot;\n\n\nPROCEDURE #(_ALGNAME_)DefaultRestore (v: T; rd: Rd.T)\n RA"
& "ISES {ZeusClass.Error} =\n <* LL = VBT.mu *>\n BEGIN\n IF rd = NIL"
& " THEN RETURN END;\n IF NOT ZeusUtil.EatChar(rd, \'(\') THEN\n R"
& "AISE ZeusClass.Error(\n \"#(_ALGNAME_)AlgClass.#(_ALGNAME_)Def"
& "aultRestore read error\");\n END;\n IF v.eventData = NIL THEN\n "
& " RAISE ZeusClass.Error(\n \"#(_ALGNAME_)AlgClass.#(_ALGNAME"
& "_)DefaultRestore: \" &\n \"eventD";
CONST E5_2 =
"ata not set!\");\n END;\n TRY\n v.eventData.restore(rd);\n "
& " v.updateEventCounts(FALSE);\n FromFV(v.eventData, v);\n EXC"
& "EPT\n ELSE\n RAISE ZeusClass.Error(\n \"#(_ALGNAME_)Al"
& "gClass.#(_ALGNAME_)DefaultRestore error\");\n END;\n Algorithm.T."
& "restore(v, rd);\n IF NOT ZeusUtil.EatChar(rd, \')\') THEN\n RAI"
& "SE ZeusClass.Error(\n \"#(_ALGNAME_)AlgClass.#(_ALGNAME_)Defau"
& "ltRestore read error\");\n END;\n END #(_ALGNAME_)DefaultRestore;\n"
& "\n#{_FEEDBACK\nPROCEDURE #(_EVENT_) (self: T\n#{\n ; <*UNUSED*> #(_A"
& "RGMODE_)#(_ARGNAME_): #(_ARGTYPE_)\n#}\n) =\n <* LL = VBT.mu *>\n BEG"
& "IN\n self.evtHandled := FALSE;\n END #(_EVENT_);\n\n#}\n\nBEGIN\nEN"
& "D #(_ALGNAME_)AlgClass.\n";
CONST E6 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:51:16 PST 1995 by kalsow *)\n(* Last modified on Wed Feb 17 16:4"
& "6:35 PST 1993 by johnh *)\n\n(***************************************"
& "******************************\n|* NOTE: This file is generated automa"
& "tically from the event\n|* definition file #(_ALGNAME_).evt.\n|*"
& "********************************************************************)\n"
& "\n<* PRAGMA LL *>\n\nINTERFACE #(_ALGNAME_)IE;\n\n$Algorithm\n$Thread\n"
& "$View\n#(_IMPORTS_)\n\n(* call the following to generate an event: *)\n"
& "\n#{_OUTPUT\nPROCEDURE #(_EVENT_) (\n initiator: Algorithm.T;\n "
& " #(_ARGSTR_)\n ) RAISES {Thread.Alerted};\n <* LL = {} *>\n\n#}"
& "\n#{_FEEDBACK\nPROCEDURE #(_EVENT_) (\n initiator: View.T;\n "
& "#(_ARGSTR_)\n ) RAISES {Thread.Alerted};\n <* LL = VBT.mu *>\n\n#"
& "}\n#{_UPDATE\nPROCEDURE #(_EVENT_) (\n initiator: Algorithm.T;\n "
& " #(_ARGSTR_)\n ) RAISES {Thread.Alerted};\n <* LL = VBT.mu *>\n"
& "\n#}\n\nEND #(_ALGNAME_)IE.\n";
CONST E7 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 09:01:09 PST 1995 by kalsow *)\n(* Last modified on Sat Jul 17 14:2"
& "8:37 PDT 1993 by mhb *)\n(* modified on Thu Jul 15 14:12:41 PD"
& "T 1993 by steveg *)\n(* modified on Tue Feb 16 16:31:40 PST 1993 "
& "by johnh *)\n\n(*****************************************************"
& "****************\n|* NOTE: This file is generated automatically from t"
& "he event\n|* definition file #(_ALGNAME_).evt.\n|***************"
& "******************************************************)\n\n<* PRAGMA LL"
& " *>\n\nMODULE #(_ALGNAME_)#(_VIEWNAME_)GEFView;\n\n$Filter\n$Fmt\n$GEF\n"
& "$GEFError\n$GEFViewClass\n$GraphVBT\n$Rd\n$Rsrc\n$SLisp\n$Thread\n$VBT\n"
& "$View\n$ViewClass\n$ZeusClass\n$ZeusPanel\n$#(_ALGNAME_)AlgClass\n$#(_A"
& "LGNAME_)ViewClass\n#(_IMPORTS_)\n\nTYPE\n T = #(_ALGNAME_)ViewClass.T "
& "BRANDED OBJECT\n name := \"#(_VIEWNAME_).gef\";\n OVERRIDES"
& "\n <* LL = VBT.mu *>\n install := Install;\n star"
& "trun := Startrun;\n <* LL = 0 *>\n#{_OUTPUT\n oe#(_EVENT_"
& ") := #(_EVENT_);\n#}\n END;\n\nPROCEDURE Install (v: T) =\n <* FA"
& "TAL SLisp.Error *>\n VAR\n interp := NEW(GEFViewClass.Interp).init("
& ");\n gef := NEW(GEF.T).init(interp);\n BEGIN\n EVAL Filter.Re"
& "place (v, gef);\n #(_ALGNAME_)ViewClass.T.install(v)\n END Install;"
& "\n\nPROCEDURE Startrun(v: T) =\n BEGIN\n TRY\n GEF.InitFromRsr"
& "c(Filter.Child(v), v.name, ZeusPanel.GetPath());\n EXCEPT\n | Thr"
& "ead.Alerted =>\n | Rsrc.NotFound =>\n ZeusPanel.ReportError(\n"
& " Fmt.F(\"GEF View error: Could not find file: %s\", v.name));\n"
& " | Rd.Failure =>\n ZeusPanel.ReportError(\n Fmt.F(\""
& "GEF View error finding or parsing file: %s\", v.name));\n | GEFError"
& ".T (msg) =>\n ZeusPanel.ReportError(\n Fmt.F(\"GEF View"
& " error (%s) parsin";
CONST E7_0 =
"g file: %s\", msg, v.name));\n END;\n END Startrun;\n\nPROCEDURE Ne"
& "w (): View.T =\n VAR g := NEW(GraphVBT.T).init();\n BEGIN\n RETURN"
& " NEW(T).init(g)\n END New;\n\n(* event handling methods: *)\n\n#{_OUTP"
& "UT\nPROCEDURE #(_EVENT_) (view: T; #(_ARGSTR_)) =\n <* LL = {} *>\n V"
& "AR gef: GEF.T := Filter.Child(view);\n BEGIN\n TRY\n GEF.Invok"
& "eEvent (gef, \"#(_EVENT_)\", GEF.EventData(\n#{\n #(_ARGFMT_)(#(_A"
& "RGNAME_))\n#|\n ,\n#}\n ));\n gef.redisplay();\n ge"
& "f.animate(0.0, 1.0);\n EXCEPT\n | Thread.Alerted =>\n | GEFErr"
& "or.T (msg) =>\n ZeusPanel.ReportError(\n Fmt.F(\"GEF Vi"
& "ew error (%s) parsing file: %s\", msg, view.name));\n END;\n END #("
& "_EVENT_);\n\n#}\n\nBEGIN\n ZeusPanel.RegisterView(New, \"#(_VIEWNAME_)"
& ".gef\", \"#(_ALGNAME_)\");\nEND #(_ALGNAME_)#(_VIEWNAME_)GEFView.\n";
CONST E8 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:59:04 PST 1995 by kalsow *)\n(* modified on Mon Jun 6 03:1"
& "6:18 PDT 1994 by mhb *)\n(* modified on Sun Jun 5 16:47:33 PD"
& "T 1994 by heydon *)\n\n(**********************************************"
& "***********************\n|* NOTE: This file is generated automatically"
& " from the event\n|* definition file #(_ALGNAME_).evt.\n|********"
& "*************************************************************)\n\n<* PR"
& "AGMA LL *>\n\nMODULE #(_ALGNAME_)#(_VIEWNAME_)JunoView;\n\n$Atom\n$Atom"
& "List\n$Fmt\n$NetObj\n$Thread\n$VBT\n$Wr\n$Rd\n$ZFmt\n$ZeusPanel\n$Remot"
& "eView\n$View\n$#(_ALGNAME_)ViewClass\n#(_IMPORTS_)\n\nTYPE\n T = #(_AL"
& "GNAME_)ViewClass.T BRANDED OBJECT\n jz: RemoteView.T := NIL;\n "
& " OVERRIDES\n <* LL.sup < VBT.mu *>\n startrun := Star"
& "trun;\n endrun := Endrun;\n <* LL.sup < VBT.mu *>\n#{_OUT"
& "PUT\n oe#(_EVENT_) := #(_EVENT_);\n#}\n <* LL.sup = VBT.m"
& "u *>\n#{_UPDATE\n ue#(_EVENT_) := #(_EVENT_);\n#}\n <* LL"
& ".sup = VBT.mu *>\n install := NoargNoop;\n delete := Noar"
& "gNoop;\n snapshot := SnapshotNoop;\n restore := RestoreNo"
& "op;\n reactivity := ReactivityNoop\n END;\n\n(* STARTRUN an"
& "d ENDRUN methods: *)\n\nPROCEDURE Startrun(view: T) =\n <* LL.sup < VB"
& "T.mu *>\n BEGIN\n IF view.jz = NIL THEN RETURN END;\n TRY view.j"
& "z.startrun() EXCEPT\n NetObj.Error (err) => ZeusPanel.ReportError("
& "NetObjError(err))\n | Thread.Alerted => ZeusPanel.ReportError(\"NetO"
& "bj call alerted\")\n END\n END Startrun;\n\nPROCEDURE Endrun(view: "
& "T) =\n <* LL.sup < VBT.mu *>\n BEGIN\n IF view.jz = NIL THEN RETUR"
& "N END;\n TRY view.jz.endrun() EXCEPT\n NetObj.Error (err) => Ze"
& "usPanel.ReportError(NetObjError(err))\n | Thread.Alerted => ZeusPane"
& "l.ReportError(\"N";
CONST E8_0 =
"etObj call alerted\")\n END\n END Endrun;\n\n(* OUTPUT and UPDATE e"
& "vent handling methods: *)\n\n#{_OUTPUT\nPROCEDURE #(_EVENT_) (view: T; "
& "#(_ARGSTR_)) =\n <* LL.sup < VBT.mu *>\n CONST EventName = \"#(_EVENT"
& "_)\";\n VAR tfactor: REAL; BEGIN\n IF view.jz = NIL THEN RETURN END"
& ";\n LOCK VBT.mu DO\n tfactor := ZeusPanel.GetAnimationTime()\n "
& " END;\n TRY\n view.jz.event (tfactor, EventName, \"(\"\n#{\n "
& " & #(_ARGFMT_)(#(_ARGNAME_))\n#|\n & \" \"\n#}\n & \")\")"
& "\n EXCEPT\n RemoteView.Error (txt) => ReportError(EventName, tx"
& "t)\n | NetObj.Error (err) => ReportError(EventName, NetObjError(err)"
& ")\n | Thread.Alerted => ReportError(EventName, \"NetObj call alerted"
& "\")\n END\n END #(_EVENT_);\n\n#}\n#{_UPDATE\nPROCEDURE #(_EVENT_) "
& "(view: T; #(_ARGSTR_)) =\n <* LL.sup = VBT.mu *>\n CONST EventName = "
& "\"#(_EVENT_)\";\n VAR tfactor: REAL; BEGIN\n IF view.jz = NIL THEN "
& "RETURN END;\n tfactor := ZeusPanel.GetAnimationTime();\n TRY\n "
& " view.jz.event (tfactor, EventName, \"(\"\n#{\n & #(_ARGFMT_)(#("
& "_ARGNAME_))\n#|\n & \" \"\n#}\n & \")\")\n EXCEPT\n R"
& "emoteView.Error (txt) => ReportError(EventName, txt)\n | NetObj.Erro"
& "r (err) => ReportError(EventName, NetObjError(err))\n | Thread.Alert"
& "ed => ReportError(EventName, \"NetObj call alerted\")\n END\n END #"
& "(_EVENT_);\n\n#}\nPROCEDURE NoargNoop(<*UNUSED*> v: T) =\n BEGIN END N"
& "oargNoop;\n\nPROCEDURE SnapshotNoop(<*UNUSED*> v: T; <*UNUSED*> wr: Wr."
& "T) =\n BEGIN END SnapshotNoop;\n\nPROCEDURE RestoreNoop(<*UNUSED*> v: "
& "T; <*UNUSED*> rd: Rd.T) =\n BEGIN END RestoreNoop;\n\nPROCEDURE Reacti"
& "vityNoop(<*UNUSED*> v: T; <*UNUSED*> on: BOOLEAN) =\n BEGIN END Reacti"
& "vityNoop;\n\nPROCEDURE New (): View.T =\n VAR\n res: T := NEW(T).in"
& "it(NIL);\n jz: NetObj.T;\n errMsg: TEXT := NIL;\n BEGIN\n TRY"
& "\n jz := NetObj.Import(\"JunoZeus\");\n IF jz = NIL THEN\n "
& " \terrMsg := \"NetObj Error: Can\'t find JunoZeus object\"\n ELSIF"
& " NOT ISTYPE(jz, RemoteView.T) THEN\n \terrMsg := \"NetObj Error: Typ"
& "e mismatch between Juno and Zeus\"\n ELSE\n ";
CONST E8_1 =
" \tres.jz := jz;\n \tRETURN res\n END\n EXCEPT\n NetOb"
& "j.Error (err) => errMsg := NetObjError(err)\n | Thread.Alerted => "
& " errMsg := \"NetObj Import alerted\"\n END;\n ZeusPanel.ReportEr"
& "ror(errMsg);\n RETURN NIL\n END New;\n\nPROCEDURE NetObjError(err: "
& "AtomList.T): TEXT =\n VAR res := \"NetObj Error: \"; BEGIN\n WHILE "
& "err # NIL DO\n res := res & Atom.ToText(err.head);\n err := e"
& "rr.tail;\n IF err # NIL THEN res := res & \"; \" END\n END;\n "
& " RETURN res\n END NetObjError;\n\nPROCEDURE ReportError(nm, msg: TEXT"
& ") =\n BEGIN\n ZeusPanel.ReportError(\"\\\"\" & nm & \"\\\" event er"
& "ror: \" & msg)\n END ReportError;\n\nPROCEDURE RegisterView () =\n BE"
& "GIN\n ZeusPanel.RegisterView(New, \"#(_VIEWNAME_)\", \"#(_ALGNAME_)\""
& ")\n END RegisterView;\n\nBEGIN\n RegisterView ();\nEND #(_ALGNAME_)#("
& "_VIEWNAME_)JunoView.\n";
CONST E9 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:56:02 PST 1995 by kalsow *)\n(* modified on Mon Jun 6 03:1"
& "8:55 PDT 1994 by mhb *)\n(* modified on Tue Feb 16 16:31:40 PST "
& "1993 by johnh *)\n\n(**************************************************"
& "*******************\n|* NOTE: This file is generated automatically fro"
& "m the event\n|* definition file #(_ALGNAME_).evt.\n|************"
& "*********************************************************)\n\n<* PRAGMA"
& " LL *>\n\nMODULE #(_ALGNAME_)TranscriptView;\n\n$ZFmt\n$Fmt\n$FormsVBT\n"
& "$Rd\n$Filter\n$TextEditVBT\n$TextPort\n$VBT\n$View\n$Wr\n$ZeusClass\n$Z"
& "eusPanel\n$#(_ALGNAME_)ViewClass\n#(_IMPORTS_)\n\n<* FATAL FormsVBT.Err"
& "or, FormsVBT.Unimplemented *>\n\nREVEAL\n T = Public BRANDED OBJECT\n "
& " fv: FormsVBT.T := NIL;\n te: TextEditVBT.T := NIL;\n OVERRIDES\n"
& " init := TViewInit;\n install := TViewInstall;\n dele"
& "te := TViewDelete;\n snapshot := TViewSnapshot;\n restore "
& " := TViewRestore;\n config := TViewConfig;\n reactivity := T"
& "ViewReactivity;\n startrun := TViewStartrun;\n endrun := TV"
& "iewEndrun;\n#{_OUTPUT\n oe#(_EVENT_) := #(_EVENT_);\n#}\n#{_UPDATE\n"
& " ue#(_EVENT_) := #(_EVENT_);\n#}\n END;\n\nPROCEDURE TViewInit (vie"
& "w: T): T =\n <* LL = VBT.mu *>\n BEGIN\n TViewZTrace (view, \"init"
& "\");\n RETURN #(_ALGNAME_)ViewClass.T.init (view, NIL);\n END TView"
& "Init;\n\nPROCEDURE Clear (<* UNUSED *> fv : FormsVBT.T;\n "
& " <* UNUSED *> name: TEXT;\n cl : REFAN"
& "Y;\n <* UNUSED *> time: VBT.TimeStamp) =\n BEGIN\n "
& "TextPort.SetText(NARROW(cl, T).te.tp, \"\")\n END Clear;\n\nPROCEDURE "
& "TViewInstall (view: T) =\n <* LL = VBT.mu *>\n BEGIN\n view.fv := "
& "ZeusPanel.NewForm(\"#(_ALGNAME_)TranscriptView.fv\");\n view.te := F"
& "ormsVBT.GetVBT(view.f";
CONST E9_0 =
"v, \"transcript\");\n TViewZTrace (view, \"install\");\n FormsVBT"
& ".AttachProc(view.fv, \"clear\", Clear, view);\n EVAL Filter.Replace "
& "(view, view.fv);\n #(_ALGNAME_)ViewClass.T.install (view);\n END TV"
& "iewInstall;\n\nPROCEDURE TViewDelete (view: T) =\n <* LL = VBT.mu *>\n"
& " BEGIN\n TViewZTrace (view, \"delete\");\n #(_ALGNAME_)ViewClass"
& ".T.delete (view);\n END TViewDelete;\n\nPROCEDURE TViewSnapshot (view"
& ": T; wr: Wr.T) RAISES {ZeusClass.Error} =\n <* LL = VBT.mu *>\n BEGIN"
& "\n TViewZTrace (view, \"snapshot\");\n #(_ALGNAME_)ViewClass.T.sn"
& "apshot (view, wr);\n END TViewSnapshot;\n\nPROCEDURE TViewRestore (vi"
& "ew: T; rd: Rd.T) RAISES {ZeusClass.Error} =\n <* LL = VBT.mu *>\n BEG"
& "IN\n TViewZTrace (view, \"restore\");\n #(_ALGNAME_)ViewClass.T.r"
& "estore (view, rd);\n END TViewRestore;\n\nPROCEDURE TViewConfig (\n "
& " view: T;\n state: ZeusClass.StateChange;\n o: ZeusClass.T) =\n "
& " <* LL = VBT.mu *>\n BEGIN\n TViewZTrace (view, \"config\");\n #"
& "(_ALGNAME_)ViewClass.T.config (view, state, o);\n END TViewConfig;\n\n"
& "PROCEDURE TViewReactivity (view: T; <*UNUSED*> on: BOOLEAN) =\n <* LL "
& "= VBT.mu *>\n BEGIN\n TViewZTrace(view, \"reactivity\");\n #(_AL"
& "GNAME_)ViewClass.T.reactivity (view, TRUE);\n END TViewReactivity;\n\n"
& "PROCEDURE TViewStartrun (view: T) =\n <* LL = {} *>\n BEGIN\n TVie"
& "wZTrace (view, \"startrun\");\n #(_ALGNAME_)ViewClass.T.startrun (vi"
& "ew);\n END TViewStartrun;\n\nPROCEDURE TViewEndrun (view: T) =\n <* "
& "LL = {} *>\n BEGIN\n TViewZTrace (view, \"endrun\");\n #(_ALGNAM"
& "E_)ViewClass.T.endrun (view);\n END TViewEndrun;\n\n\n(* event handlin"
& "g methods: *)\n\n#{_OUTPUT\nPROCEDURE #(_EVENT_) (view: T; #(_ARGSTR_))"
& " =\n <* LL = {} *>\n BEGIN\n LOCK VBT.mu DO\n IF FormsVBT.GetBo"
& "olean(view.fv, \"alg\") THEN\n IF NOT FormsVBT.GetBoolean(view.fv"
& ", \"args\") THEN\n TViewTrace (view, \"#(_EVENT_) ...\")\n "
& " ELSE\n TViewTrace (view, \"#(_EVENT_) \"\n#{\n & #"
& "(_ARGFMT_)(#(_ARGNAME_))\n#|\n & \" \"\n#}\n )\n "
& " END\n END\n END\n END #(_EVENT_);\n\n#}\n\n\n#{";
CONST E9_1 =
"_UPDATE\nPROCEDURE #(_EVENT_) (view: T; #(_ARGSTR_)) =\n <* LL = VBT.m"
& "u *>\n BEGIN\n IF FormsVBT.GetBoolean(view.fv, \"alg\") THEN\n "
& " IF NOT FormsVBT.GetBoolean(view.fv, \"args\") THEN\n TViewTr"
& "ace (view, \"#(_EVENT_) ...\")\n ELSE\n TViewTrace (view"
& ", \"#(_EVENT_) \"\n#{\n & #(_ARGFMT_)(#(_ARGNAME_))\n#|\n "
& " & \" \"\n#}\n )\n END\n END\n END #(_EVENT"
& "_);\n\n#}\n\n\nPROCEDURE TViewZTrace (view: T; t: TEXT) =\n BEGIN\n "
& " IF view.fv # NIL THEN\n IF FormsVBT.GetBoolean(view.fv, \"zeus\")"
& " THEN\n TextPort.PutText(view.te.tp, \"**zeus: \" & t & \"\\n\""
& ");\n TextPort.Normalize(view.te.tp, LAST(INTEGER))\n END\n "
& " END\n END TViewZTrace;\n\nPROCEDURE TViewTrace (view: T; t: TEXT) ="
& "\n BEGIN\n TextPort.PutText(view.te.tp, \"--event: \" & t & \"\\n\""
& ");\n TextPort.Normalize(view.te.tp, LAST(INTEGER))\n END TViewTrace"
& ";\n\n\nPROCEDURE TViewNew (): View.T =\n BEGIN\n RETURN NEW(T).init"
& "()\n END TViewNew;\n\n\nBEGIN\n ZeusPanel.RegisterView\n (TViewN"
& "ew, \"#(_ALGNAME_) Transcript View\", \"#(_ALGNAME_)\");\nEND #(_ALGNAM"
& "E_)TranscriptView.\n";
CONST E10 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:54:53 PST 1995 by kalsow *)\n(* modified on Tue Jul 13 10:4"
& "0:26 PDT 1993 by mhb *)\n\n(***************************************"
& "******************************\n|* NOTE: This file is generated automa"
& "tically from the event\n|* definition file #(_ALGNAME_).evt.\n|*"
& "********************************************************************)\n"
& "\nMODULE #(_ALGNAME_)DataView;\n\nIMPORT ZeusDataView, ZeusPanel;\n\nBE"
& "GIN\n ZeusPanel.RegisterView (\n ZeusDataView.New,\n \"#(_ALGNAM"
& "E_) Data View\",\n \"#(_ALGNAME_)\");\nEND #(_ALGNAME_)DataView.\n";
CONST E11 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:57:10 PST 1995 by kalsow *)\n(* modified on Sun Nov 28 23:0"
& "9:13 PST 1993 by najork *)\n\n(***************************************"
& "******************************\n|* NOTE: This file is generated automa"
& "tically from the event\n|* definition file #(_ALGNAME_).evt.\n|*"
& "********************************************************************)\n"
& "\n<* PRAGMA LL *>\n\nINTERFACE #(_ALGNAME_)3DViewClass;\n\n$Thread\n$Vi"
& "ew3D\n#(_IMPORTS_)\n\nTYPE\n T <: Public;\n Public = View3D.T OBJECT\n"
& " METHODS\n <*LL = {} *>\n#{_OUTPUT\n oe#(_EVENT_) (#(_"
& "ARGSTR_)) RAISES {Thread.Alerted};\n#}\n <*LL = VBT.mu *>\n#{_UPDA"
& "TE\n ue#(_EVENT_) (#(_ARGSTR_)) RAISES {Thread.Alerted};\n#}\n "
& " END;\n\nEND #(_ALGNAME_)3DViewClass.\n";
CONST E12 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:50:48 PST 1995 by kalsow *)\n(* modified on Sun Jun 5 21:5"
& "9:57 PDT 1994 by mhb *)\n(* modified on Wed Feb 17 16:46:47 PS"
& "T 1993 by johnh *)\n\n(**********************************************"
& "***********************\n|* NOTE: This file is generated automatically"
& " from the event\n|* definition file #(_ALGNAME_).evt.\n|********"
& "*************************************************************)\n\n<* PR"
& "AGMA LL *>\n\nMODULE #(_ALGNAME_)IE;\n\n$Algorithm\n$AlgorithmClass\n$T"
& "hread\n$View\n$Zeus\n$ZeusClass\n$#(_ALGNAME_)AlgClass\n$#(_ALGNAME_)Vi"
& "ewClass\n#(_IMPORTS_)\n\n<* FATAL Zeus.Error, Zeus.Locked *>\n(* If you"
& " get either of these errors, contact a Zeus implementor. *)\n\nTYPE\n#{"
& "\n #(_EVENT_)Args = BRANDED REF RECORD\n#{\n #(_ARGNAME_): #(_ARGTY"
& "PE_);\n#}\n END;\n\n#}\n\n(* Zeus calls the following to invoke vbt v"
& "\'s event handler: *)\n\n<*NOWARN*> PROCEDURE OEDispatcher(v: ZeusClass"
& ".T; evt: REFANY) RAISES {Thread.Alerted} =\n <* LL <= VBT.mu *>\n (* "
& "LL = {} if event style is output, LL = VBT.mu if event style is update."
& " *)\n BEGIN\n TYPECASE v OF\n | #(_ALGNAME_)ViewClass.T (view) ="
& "> <*NOWARN*>\n TYPECASE evt OF\n#{_OUTPUT\n | #(_EVENT_)Args("
& "var#(_EVENT_)Args) => <*NOWARN*>\n view.oe#(_EVENT_) (\n#{\n "
& " var#(_EVENT_)Args.#(_ARGNAME_)\n#|\n ,\n#}\n"
& " )\n#}\n#{_UPDATE\n | #(_EVENT_)Args(var#(_EVENT_)Arg"
& "s) => <*NOWARN*>\n view.ue#(_EVENT_) (\n#{\n var#"
& "(_EVENT_)Args.#(_ARGNAME_)\n#|\n ,\n#}\n )\n"
& "#}\n ELSE <* ASSERT FALSE *>\n END;\n ELSE (* this view is"
& "n\'t a #(_ALGNAME_)ViewClass, so just ignore *)\n END\n END OEDispa"
& "tcher;\n\n<*NOWARN*> PROCEDURE FEDispatcher(v: ZeusClass.T; evt: REFANY"
& ") =\n <* LL = VBT";
CONST E12_0 =
".mu *>\n BEGIN\n TYPECASE v OF\n | #(_ALGNAME_)AlgClass.T (alg) "
& "=> <*NOWARN*>\n TYPECASE evt OF\n#{_FEEDBACK\n | #(_EVENT_)Ar"
& "gs(var#(_EVENT_)Args) => <*NOWARN*>\n alg.fe#(_EVENT_) (\n#{\n"
& " var#(_EVENT_)Args.#(_ARGNAME_)\n#|\n ,\n#}"
& "\n )\n#}\n ELSE <* ASSERT FALSE *>\n END;\n E"
& "LSE (* this alg isn\'t a #(_ALGNAME_)AlgClass, so just ignore *)\n E"
& "ND\n END FEDispatcher;\n\n\n#{_OUTPUT\nPROCEDURE #(_EVENT_) (\n i"
& "nitiator: Algorithm.T;\n #(_ARGSTR_)\n ) RAISES {Thread.Alerted"
& "} =\n <* LL = {} *>\n VAR zumeArgRec := NEW(#(_EVENT_)Args\n#{\n "
& " , #(_ARGNAME_) := #(_ARGNAME_)\n#}\n );\n alg := NA"
& "RROW(initiator, #(_ALGNAME_)AlgClass.T);\n BEGIN\n LOCK alg.evtMu D"
& "O\n INC(alg.eventDataRec.ctOf#(_EVENT_));\n alg.stopAtEvent :"
& "= alg.eventDataRec.stopAt#(_EVENT_);\n alg.waitAtEvent := alg.even"
& "tDataRec.waitAt#(_EVENT_);\n Zeus.Dispatch(initiator, Zeus.EventSt"
& "yle.Output, #(_EVENTPRIO_),\n \"#(_EVENT_)\", OEDisp"
& "atcher, zumeArgRec);\n END;\n END #(_EVENT_);\n\n#}\n#{_UPDATE\nPRO"
& "CEDURE #(_EVENT_) (\n initiator: Algorithm.T;\n #(_ARGSTR_)\n"
& " ) RAISES {Thread.Alerted} =\n <* LL = VBT.mu *>\n VAR zumeArgRec "
& ":= NEW(#(_EVENT_)Args\n#{\n , #(_ARGNAME_) := #(_ARGNAME_"
& ")\n#}\n );\n BEGIN\n Zeus.Dispatch(initiator, Zeus.EventStyle."
& "Update, #(_EVENTPRIO_),\n \"#(_EVENT_)\", OEDispatcher"
& ", zumeArgRec);\n END #(_EVENT_);\n\n#}\n\n#{_FEEDBACK\nPROCEDURE #(_EV"
& "ENT_) (\n initiator: View.T;\n #(_ARGSTR_)\n ) RAISES {Thr"
& "ead.Alerted} =\n <* LL = VBT.mu *>\n VAR zumeArgRec := NEW(#(_EVENT_)"
& "Args\n#{\n , #(_ARGNAME_) := #(_ARGNAME_)\n#}\n );\n"
& " BEGIN\n Zeus.Dispatch(initiator, Zeus.EventStyle.Notify, #(_EVENTP"
& "RIO_),\n \"#(_EVENT_)\", FEDispatcher, zumeArgRec);\n "
& " END #(_EVENT_);\n\n#}\n\nBEGIN\nEND #(_ALGNAME_)IE.\n";
CONST E13 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Fri Sep "
& " 8 15:48:12 PDT 1995 by najork *)\n(* modified on Thu Feb 9 08:5"
& "4:15 PST 1995 by kalsow *)\n(* Last modified on Fri Dec 9 15:00:46 PS"
& "T 1994 by mhb *)\n(* modified on Sat Jun 4 16:24:49 1994 by h"
& "eydon *)\n(* modified on Tue Feb 16 16:31:40 PST 1993 by john"
& "h *)\n\n(************************************************************"
& "*********\n|* NOTE: This file is generated automatically from the even"
& "t\n|* definition file #(_ALGNAME_).evt.\n|**********************"
& "***********************************************)\n\n<* PRAGMA LL *>\n\n"
& "MODULE #(_ALGNAME_)#(_VIEWNAME_)ObliqView;\n\n$Filter\n$Fmt\n$Obliq\n$O"
& "bliqParser\n$ObLibAnim\n$ObLibM3\n$ObLibUI\n$ObValue\n$Rd\n$Rsrc\n$SynW"
& "r\n$TextRd\n$TextWr\n$Thread\n$VBT\n$View\n$ZeusPanel\n$ZFmt\n$#(_ALGNA"
& "ME_)ViewClass\n#(_IMPORTS_)\n\nCONST\n ViewName = \"#(_VIEWNAME_).obl"
& "\";\n\nTYPE\n T = #(_ALGNAME_)ViewClass.T BRANDED OBJECT\n obje"
& "ct : Obliq.Val;\n env : Obliq.Env;\n wr : TextW"
& "r.T;\n swr : SynWr.T;\n parser : ObliqParser.T;\n "
& " OVERRIDES\n <* LL.sup < VBT.mu *>\n startrun := Startr"
& "un;\n <* LL.sup < VBT.mu *>\n#{_OUTPUT\n oe#(_EVENT_) := "
& "#(_EVENT_);\n#}\n <* LL.sup = VBT.mu *>\n#{_UPDATE\n ue#("
& "_EVENT_) := #(_EVENT_);\n#}\n END;\n\n(* OUTPUT and UPDATE event h"
& "andling methods: *)\n\n#{_OUTPUT\nPROCEDURE #(_EVENT_) (view: T; #(_ARG"
& "STR_)) =\n <* LL.sup < VBT.mu *>\n BEGIN\n IF FieldDefined(view.ob"
& "ject, \"#(_EVENT_)\") THEN\n Invoke (view, \"#(_EVENT_)\", \"\"\n#"
& "{\n & #(_ARGFMT_)(#(_ARGNAME_))\n#|\n & \",\"\n#}\n )\n "
& " END\n END #(_EVENT_);\n#}\n\n#{_UPDATE\nPROCEDURE #(_EVENT_) (view:"
& " T; #(_ARGSTR_)) =\n <* LL = VBT.mu *>\n BEGIN\n IF FieldDefined(v"
& "iew.object, \"#(_EVENT_)\") THEN\n ";
CONST E13_0 =
" Invoke (view, \"#(_EVENT_)\", \"\"\n#{\n & #(_ARGFMT_)(#(_ARGNAME"
& "_))\n#|\n & \",\"\n#}\n )\n END\n END #(_EVENT_);\n#}\n\n"
& "PROCEDURE RegisterView () =\n BEGIN\n ZeusPanel.RegisterView(New, \""
& "#(_VIEWNAME_).obl\", \"#(_ALGNAME_)\")\n END RegisterView;\n\nPROCEDUR"
& "E New (): View.T =\n BEGIN\n RETURN NEW(T).init(NIL)\n END New;\n\n"
& "CONST\n ObliqStackSizeMultiplier = 8;\n\nTYPE\n Closure = Thread.Size"
& "dClosure OBJECT\n view: T;\n OVERRIDES\n "
& " apply := ForkedStartrun;\n END;\n\nPROCEDURE Startrun"
& " (view: T) =\n <* LL.sup < VBT.mu *>\n BEGIN\n EVAL\n Thread."
& "Join(\n Thread.Fork(\n NEW(Closure, view := view,\n "
& " stackSize := ObliqStackSizeMultiplier * Thread.GetDefaultStac"
& "kSize())));\n END Startrun;\n\nPROCEDURE ForkedStartrun (cl: Closure):"
& " REFANY =\n VAR rd: Rd.T; view := cl.view;\n BEGIN\n IF view.parse"
& "r = NIL THEN\n view.wr := TextWr.New();\n view.swr := SynWr.N"
& "ew(view.wr);\n view.parser := ObliqParser.New(view.swr);\n END;"
& "\n view.object := NIL;\n TRY\n rd := Rsrc.Open(ViewName, Zeu"
& "sPanel.GetPath());\n view.env := ParseRd(view.parser, ViewName, rd"
& ");\n WITH obj = Obliq.Lookup(\"view\", view.env) DO\n IF NO"
& "T ISTYPE(obj, ObValue.ValObj) THEN\n ZeusPanel.ReportError(\n "
& " \"not an Obliq object in \'\" & ViewName & \"\'\")\n "
& "ELSIF FieldDefined (obj, \"graphvbt\") THEN\n WITH graphvbt =\n"
& " NARROW(Obliq.ObjectSelect(obj, \"graphvbt\"),\n "
& " ObLibAnim.ValGraph).vbt DO\n LOCK VBT.mu DO\n "
& " EVAL Filter.Replace(view, graphvbt)\n END\n E"
& "ND;\n view.object := obj;\n ELSIF FieldDefined (obj, \""
& "rectsvbt\") THEN\n WITH rectsvbt =\n NARROW(Obliq.O"
& "bjectSelect(obj, \"rectsvbt\"),\n ObLibAnim.ValRects)"
& ".vbt DO\n LOCK VBT.mu DO\n EVAL Filter.Replace("
& "view, rectsvbt)\n END\n END;\n view.object"
& " := obj;\n ELSIF FieldDefined (o";
CONST E13_1 =
"bj, \"formsvbt\") THEN\n WITH formsvbt =\n NARROW(O"
& "bliq.ObjectSelect(obj, \"formsvbt\"),\n ObLibUI.ValFo"
& "rm).vbt DO\n LOCK VBT.mu DO\n EVAL Filter.Repla"
& "ce(view, formsvbt)\n END\n END;\n view.obj"
& "ect := obj;\n ELSE\n ZeusPanel.ReportError(\n "
& " \"cannot find \'graphvbt\', \'rectsvbt\', or \'formsvbt\' in \'\" & V"
& "iewName & \"\'\")\n END\n END\n EXCEPT\n | Rsrc.NotFo"
& "und =>\n ZeusPanel.ReportError(\"cannot find \'\" & ViewName & \""
& "\'\")\n | ObValue.Error (packet) => OblError(view, packet)\n | Ob"
& "Value.Exception (packet) => OblException(view, packet)\n END;\n R"
& "ETURN NIL;\n END ForkedStartrun;\n\nPROCEDURE ParseRd (p: ObliqParser."
& "T; name: TEXT; rd: Rd.T):\n Obliq.Env RAISES {ObValue.Error, ObValue.E"
& "xception} =\n VAR env := Obliq.EmptyEnv();\n BEGIN\n ObliqParser.R"
& "eadFrom(p, name, rd, TRUE);\n TRY\n LOOP\n EVAL ObliqPar"
& "ser.EvalPhrase(p, ObliqParser.ParsePhrase(p), env)\n END\n EXCE"
& "PT\n ObliqParser.Eof => (* clean exit of loop *)\n END;\n RE"
& "TURN env\n END ParseRd;\n\nPROCEDURE Invoke (view: T; event, args: TEX"
& "T) =\n VAR\n exp := \"view.\" & event & \"(\" & args & \");\";\n"
& " name := \"Zeus Event <\" & event & \">\";\n BEGIN\n ObliqPars"
& "er.ReadFrom (view.parser, name, TextRd.New(exp), FALSE);\n TRY\n "
& " EVAL Obliq.EvalTerm(ObliqParser.ParseTerm(view.parser), view.env)\n "
& " EXCEPT\n | ObliqParser.Eof => <* ASSERT FALSE *>\n | ObValue.Er"
& "ror (packet) => OblError(view, packet)\n | ObValue.Exception (packet"
& ") => OblException(view, packet)\n END\n END Invoke;\n\nPROCEDURE Fi"
& "eldDefined (object: Obliq.Val; event: TEXT): BOOLEAN =\n BEGIN\n TR"
& "Y\n RETURN object # NIL AND Obliq.ObjectHas(object, event)\n EX"
& "CEPT\n | ObValue.Error =>\n | ObValue.Exception =>\n END;\n "
& " RETURN FALSE\n END FieldDefined;\n\nPROCEDURE OblError (view: T; pack"
& "et: ObValue.ErrorPacket) =\n BEGIN\n Obliq.ReportError(view.swr, pa"
& "cket);\n ZeusPanel.ReportError(\n ";
CONST E13_2 =
" \"Obliq error: \" & TextWr.ToText(view.wr))\n END OblError;\n\nPROCE"
& "DURE OblException (view: T; packet: ObValue.ExceptionPacket) =\n BEGIN"
& "\n Obliq.ReportException(view.swr, packet);\n ZeusPanel.ReportErr"
& "or(\n \"Obliq exception: \" & TextWr.ToText(view.wr))\n END OblEx"
& "ception;\n\nBEGIN\n SynWr.Setup();\n ObliqParser.PackageSetup();\n O"
& "bLibM3.PackageSetup();\n ObLibUI.PackageSetup();\n ObLibAnim.PackageS"
& "etup();\n RegisterView ();\nEND #(_ALGNAME_)#(_VIEWNAME_)ObliqView.\n";
CONST E14 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:47:37 PST 1995 by kalsow *)\n(* Last modified on Wed Feb 17 16:4"
& "4:58 PST 1993 by johnh *)\n(* modified on Tue Jun 9 00:35:07 19"
& "92 by mhb *)\n\n(**********************************************"
& "***********************\n|* NOTE: This file is generated automatically"
& " from the event\n|* definition file #(_ALGNAME_).evt.\n|********"
& "*************************************************************)\n\nINTER"
& "FACE #(_ALGNAME_)AlgClass;\n\n$Algorithm\n$AlgorithmClass\n#(_IMPORTS_)"
& "\n\n<* PRAGMA LL *>\n\nTYPE\n EventDataRec = RECORD\n#{_OUTPUT\n st"
& "opAt#(_EVENT_): BOOLEAN := TRUE;\n waitAt#(_EVENT_): CARDINAL := 1;\n"
& " ctOf#(_EVENT_): CARDINAL := 0;\n#}\n END;\n\n T <: Public;\n Pub"
& "lic = Algorithm.T OBJECT\n eventDataRec: EventDataRec;\n#(_ALGDATA"
& "_)\n METHODS\n#{_FEEDBACK\n fe#(_EVENT_) (#(_ARGSTR_)); "
& "<* LL = VBT.mu *>\n#}\n END;\n\nREVEAL\n Algorithm.T <: Algorithm"
& "Class.T;\n\nEND #(_ALGNAME_)AlgClass.\n";
CONST E15 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:56:54 PST 1995 by kalsow *)\n(* modified on Sat Jun 4 16:2"
& "3:08 1994 by heydon *)\n(* modified on Wed Feb 17 17:04:32 PS"
& "T 1993 by johnh *)\n(* modified on Tue Jun 9 00:35:35 1992 by m"
& "hb *)\n\n(*****************************************************"
& "****************\n|* NOTE: This file is generated automatically from t"
& "he event\n|* definition file #(_ALGNAME_).evt.\n|***************"
& "******************************************************)\n\n<* PRAGMA LL"
& " *>\n\nMODULE #(_ALGNAME_)ViewClass;\n\n$ViewClass\n$ZeusClass\n$#(_ALG"
& "NAME_)AlgClass\n#(_IMPORTS_)\n\nREVEAL\n T = Public BRANDED OBJECT\n "
& " OVERRIDES\n <* LL.sup = VBT.mu *>\n isCompat := IsCom"
& "pat;\n <* LL.sup < VBT.mu *>\n#{_OUTPUT\n oe#(_EVENT_) :="
& " #(_EVENT_);\n#}\n <* LL.sup = VBT.mu *>\n#{_UPDATE\n ue#"
& "(_EVENT_) := #(_EVENT_);\n#}\n END;\n\nPROCEDURE IsCompat(<*UNUSED"
& "*> v: T; alg: ZeusClass.T): BOOLEAN =\n <* LL.sup = VBT.mu *>\n BEGIN"
& "\n RETURN ISTYPE(alg, #(_ALGNAME_)AlgClass.T)\n END IsCompat;\n\n#{"
& "_OUTPUT\nPROCEDURE #(_EVENT_) (view: T\n#{\n ; <*UNUSED*> #(_ARGMODE"
& "_)#(_ARGNAME_): #(_ARGTYPE_)\n#}\n) =\n <* LL.sup < VBT.mu *>\n BEGIN"
& "\n view.evtHandled := FALSE;\n END #(_EVENT_);\n#}\n\n#{_UPDATE\nPR"
& "OCEDURE #(_EVENT_) (view: T\n#{\n ; <*UNUSED*> #(_ARGMODE_)#(_ARGNAM"
& "E_): #(_ARGTYPE_)\n#}\n) =\n <* LL.sup = VBT.mu *>\n BEGIN\n view."
& "evtHandled := FALSE;\n END #(_EVENT_);\n#}\n\nBEGIN\nEND #(_ALGNAME_)V"
& "iewClass.\n";
CONST E16 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Wed Feb "
& " 8 15:29:45 PST 1995 by kalsow *)\n(* modified on Sat Jul 17 10:5"
& "5:43 PDT 1993 by mhb *)\n(* modified on Thu Jul 15 13:53:13 PD"
& "T 1993 by steveg *)\n(* modified on Wed Feb 17 16:47:18 PST 1993 "
& "by johnh *)\n\n(*****************************************************"
& "****************\n|* NOTE: This file is generated automatically from t"
& "he event\n|* definition file #(_ALGNAME_).evt.\n|***************"
& "******************************************************)\n\nINTERFACE #("
& "_ALGNAME_)#(_VIEWNAME_)GEFView;\nEND #(_ALGNAME_)#(_VIEWNAME_)GEFView.\n"
& "\n";
CONST E17 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Wed Feb "
& " 8 15:33:55 PST 1995 by kalsow *)\n(* modified on Wed Jun 1 23:5"
& "8:34 PDT 1994 by mhb *)\n\n(***************************************"
& "******************************\n|* NOTE: This file is generated automa"
& "tically from the event\n|* definition file #(_ALGNAME_).evt.\n|*"
& "********************************************************************)\n"
& "\nINTERFACE #(_ALGNAME_)#(_VIEWNAME_)JunoView;\nEND #(_ALGNAME_)#(_VIEW"
& "NAME_)JunoView.\n\n";
CONST E18 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Wed Feb "
& " 8 15:42:11 PST 1995 by kalsow *)\n(* modified on Wed Feb 17 16:4"
& "7:18 PST 1993 by johnh *)\n(* modified on Tue Jun 9 00:43:17 19"
& "92 by mhb *)\n\n(**********************************************"
& "***********************\n|* NOTE: This file is generated automatically"
& " from the event\n|* definition file #(_ALGNAME_).evt.\n|********"
& "*************************************************************)\n\n<* PR"
& "AGMA LL *>\n\nINTERFACE #(_ALGNAME_)TranscriptView;\n\nIMPORT #(_ALGNAM"
& "E_)ViewClass;\n\nTYPE\n T <: Public;\n Public = #(_ALGNAME_)ViewClass"
& ".T OBJECT\n METHODS\n <* LL = VBT.mu *>\n init(): T;"
& "\n END;\n\nEND #(_ALGNAME_)TranscriptView.\n";
CONST E19 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Mon Jul "
& "10 15:31:57 PDT 1995 by najork *)\n(* modified on Thu Feb 9 08:5"
& "3:09 PST 1995 by kalsow *)\n(* modified on Mon Jun 6 03:20:38 PD"
& "T 1994 by mhb *)\n(* modified on Sat Jun 4 16:22:04 1994 by h"
& "eydon *)\n(* modified on Tue Feb 16 16:31:40 PST 1993 by john"
& "h *)\n\n(************************************************************"
& "*********\n|* NOTE: This file is generated automatically from the even"
& "t\n|* definition file #(_ALGNAME_).evt.\n|**********************"
& "***********************************************)\n\n<* PRAGMA LL *>\n\n"
& "MODULE #(_ALGNAME_)#(_VIEWNAME_)Obliq3DView;\n\n$Fmt\n$ZFmt\n$Obliq\n$O"
& "bliqParser\n$ObLib3D\n$ObLibAnim\n$ObLibM3\n$ObLibUI\n$ObValue\n$ObView"
& "3D\n$ObZeus3D\n$Rd\n$Rsrc\n$SynWr\n$TextRd\n$TextWr\n$Thread\n$View\n$V"
& "iew3DProxy\n$ZeusPanel\n$SynLocation\n$SynParse\n$MetaParser\n$ObliqPri"
& "nter\n$ObLibOnline\n$#(_ALGNAME_)3DViewClass\n#(_IMPORTS_)\n\nCONST\n "
& "ViewName = \"#(_VIEWNAME_).obl\";\n\nTYPE\n T = #(_ALGNAME_)3DViewCla"
& "ss.T BRANDED OBJECT\n env : Obliq.Env;\n wr : Te"
& "xtWr.T;\n swr : SynWr.T;\n parser : ObliqParser.T;\n"
& " OVERRIDES\n <* LL.sup < VBT.mu *>\n startrun := Sta"
& "rtrun;\n <* LL.sup < VBT.mu *>\n#{_OUTPUT\n oe#(_EVENT_) "
& ":= #(_EVENT_);\n#}\n <* LL.sup = VBT.mu *>\n#{_UPDATE\n u"
& "e#(_EVENT_) := #(_EVENT_);\n#}\n END;\n\n(* OUTPUT and UPDATE even"
& "t handling methods: *)\n\n#{_OUTPUT\nPROCEDURE #(_EVENT_) (view: T; #(_"
& "ARGSTR_)) =\n <* LL.sup < VBT.mu *>\n BEGIN\n Invoke (view, \"#("
& "_EVENT_)\", \"\"\n#{\n & #(_ARGFMT_)(#(_ARGNAME_))\n#|\n & \""
& ",\"\n#}\n )\n END #(_EVENT_);\n\n#}\n\n#{_UPDATE\nPROCEDURE #(_EV"
& "ENT_) (view: T; #(_ARGSTR_)) =\n <* LL.sup = VBT.mu *>\n BEGIN\n "
& " Invoke (view, \"#(_EVENT_)\", \"\"\n#{\n ";
CONST E19_0 =
" & #(_ARGFMT_)(#(_ARGNAME_))\n#|\n & \",\"\n#}\n )\n END #("
& "_EVENT_);\n#}\n\nTYPE\n Closure = Thread.SizedClosure BRANDED OBJECT\n"
& " view : T;\n OVERRIDES\n apply := Apply;\n END;\n\n\nPROCEDURE "
& "Apply (self : Closure) : REFANY =\n\n PROCEDURE ParseRd (p: ObliqParse"
& "r.T; name: TEXT; rd: Rd.T) : Obliq.Env\n RAISES {ObValue.Error, Ob"
& "Value.Exception} =\n VAR\n env := Obliq.EmptyEnv ();\n BEGIN"
& "\n ObliqParser.ReadFrom (p, name, rd, TRUE);\n TRY\n L"
& "OOP\n EVAL ObliqParser.EvalPhrase (p, ObliqParser.ParsePhrase "
& "(p), env)\n END\n EXCEPT\n ObliqParser.Eof => (* cle"
& "an exit of loop *)\n END;\n RETURN env\n END ParseRd;\n\n "
& " BEGIN\n WITH view = self.view DO\n (*** Parse the .obl file **"
& "*)\n TRY\n WITH rd = Rsrc.Open (ViewName, ZeusPanel.GetPath"
& " ()) DO\n view.env := ParseRd (view.parser, ViewName, rd);\n "
& " END;\n WITH obj = Obliq.Lookup (\"view\", view.env) DO\n "
& " ObView3D.PairUp (view, obj);\n END;\n EXCEPT\n "
& " | Rsrc.NotFound =>\n ZeusPanel.ReportError(\"cannot find \'\" &"
& " ViewName & \"\'\");\n | ObValue.Error (packet) =>\n OblErr"
& "or(view, packet);\n | ObValue.Exception (packet) =>\n OblEx"
& "ception(view, packet);\n END;\n\n RETURN NIL;\n END;\n EN"
& "D Apply;\n\n\nPROCEDURE New (): View.T =\n VAR\n view : T;\n BEGIN"
& "\n (*** Create a View3D.T ***)\n view := NEW (T).init (\"Obliq3D "
& "View\");\n\n (*** Create a new Obliq parser ***)\n view.wr :="
& " TextWr.New ();\n view.swr := SynWr.New (view.wr);\n view.pars"
& "er := ObliqParser.New (view.swr);\n\n (*** Load the .obl file ***)\n"
& " WITH thread = Thread.Fork (NEW (Closure, view := view)) DO\n E"
& "VAL Thread.Join (thread);\n END;\n\n (*** invoke the New method o"
& "f the Obliq object \"view\" ***)\n Invoke (view, \"New\", \"\");\n\n"
& " (*** Return the new view ***)\n RETURN view;\n END New;\n\n\nPR"
& "OCEDURE Startrun (view: T) =\n <* LL.sup < VBT.mu *>\n BEGIN\n (**"
& "* Reload the .obl file ***)\n WITH thread =";
CONST E19_1 =
" Thread.Fork (\n NEW (Closure,\n "
& " stackSize := 2 * Thread.GetDefaultStackSize (),\n "
& " view := view)) DO\n EVAL Thread.Join (thread);\n "
& "END;\n END Startrun;\n\n\nPROCEDURE Invoke (view: T; event, args: TEXT"
& ") =\n VAR\n exp := \"view.\" & event & \"(\" & args & \");\";\n "
& " name := \"Zeus Event <\" & event & \">\";\n proxy := ObView3D."
& "M3ToObliq (view);\n BEGIN\n TRY\n IF proxy # NIL AND Obliq.Obj"
& "ectHas (proxy, event) THEN\n ObliqParser.ReadFrom (view.parser, "
& "name, TextRd.New(exp), FALSE);\n EVAL Obliq.EvalTerm (ObliqParse"
& "r.ParseTerm (view.parser), view.env);\n END;\n EXCEPT\n | Ob"
& "liqParser.Eof => <* ASSERT FALSE *>\n | ObValue.Error (packet) => Ob"
& "lError(view, packet)\n | ObValue.Exception (packet) => OblException("
& "view, packet)\n END;\n END Invoke;\n\n\nPROCEDURE OblError (view: T"
& "; packet: ObValue.ErrorPacket) =\n BEGIN\n Obliq.ReportError(view.s"
& "wr, packet);\n ZeusPanel.ReportError(\"Obliq error: \" & TextWr.ToTe"
& "xt(view.wr))\n END OblError;\n\n\nPROCEDURE OblException (view: T; pac"
& "ket: ObValue.ExceptionPacket) =\n BEGIN\n Obliq.ReportException(vie"
& "w.swr, packet);\n ZeusPanel.ReportError(\n \"Obliq exception: \""
& " & TextWr.ToText(view.wr))\n END OblException;\n\n\nBEGIN\n SynWr.Set"
& "up();\n SynLocation.PackageSetup();\n SynParse.PackageSetup();\n Met"
& "aParser.PackageSetup(); <* NOWARN *>\n Obliq.PackageSetup();\n ObliqP"
& "arser.PackageSetup();\n ObliqPrinter.PackageSetup();\n ObLibOnline.Se"
& "tup(); (* really needed! *)\n\n ObLibM3.PackageSetup();\n "
& " ObLibUI.PackageSetup();\n ObLibAnim.PackageSetup();\n ObLib3D.Packag"
& "eSetup();\n ObZeus3D.PackageSetup();\n\n ZeusPanel.RegisterView (New,"
& "\n \"#(_VIEWNAME_).obl\",\n "
& " \"#(_ALGNAME_)\",\n sample := NEW(T));\n"
& "END #(_ALGNAME_)#(_VIEWNAME_)Obliq3DView.\n";
CONST E20 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Wed Feb "
& " 8 15:27:36 PST 1995 by kalsow *)\n(* modified on Mon Jul 12 22:"
& "36:53 PDT 1993 by mhb *)\n\nINTERFACE #(_ALGNAME_)DataView;\n\nEND #"
& "(_ALGNAME_)DataView.\n";
CONST E21 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 09:00:07 PST 1995 by kalsow *)\n(* modified on Mon Nov 29 08:0"
& "7:34 PST 1993 by najork *)\n(* modified on Wed Feb 17 16:46:47 PS"
& "T 1993 by johnh *)\n(* modified on Tue Jun 9 00:41:25 1992 by m"
& "hb *)\n\n(*****************************************************"
& "****************\n|* NOTE: This file is generated automatically from t"
& "he event\n|* definition file #(_ALGNAME_).evt.\n|***************"
& "******************************************************)\n\n<* PRAGMA LL"
& " *>\n\nMODULE #(_ALGNAME_)IE;\n\n$Algorithm\n$AlgorithmClass\n$Thread\n"
& "$View\n$Zeus\n$ZeusClass\n$#(_ALGNAME_)AlgClass\n$#(_ALGNAME_)ViewClass"
& "\n$#(_ALGNAME_)3DViewClass\n#(_IMPORTS_)\n\n<* FATAL Zeus.Error, Zeus.L"
& "ocked *>\n(* If you get either of these errors, contact a Zeus implemen"
& "tor. *)\n\nTYPE\n#{\n #(_EVENT_)Args = BRANDED REF RECORD\n#{\n #(_"
& "ARGNAME_): #(_ARGTYPE_);\n#}\n END;\n\n#}\n\n(* Zeus calls the follow"
& "ing to invoke vbt v\'s event handler: *)\n\nPROCEDURE OEDispatcher(v: Z"
& "eusClass.T; evt: REFANY) RAISES {Thread.Alerted} =\n <* LL <= VBT.mu *"
& ">\n (* LL = {} if event style is output, LL = VBT.mu if event style is"
& " update. *)\n BEGIN\n TYPECASE v OF\n | #(_ALGNAME_)ViewClass.T "
& "(view) =>\n TYPECASE evt OF\n#{_OUTPUT\n | #(_EVENT_)Args(var"
& "#(_EVENT_)Args) =>\n view.oe#(_EVENT_) (\n#{\n va"
& "r#(_EVENT_)Args.#(_ARGNAME_)\n#|\n ,\n#}\n "
& ")\n#}\n#{_UPDATE\n | #(_EVENT_)Args(var#(_EVENT_)Args) =>\n "
& " view.ue#(_EVENT_) (\n#{\n var#(_EVENT_)Args.#(_ARGNAME_"
& ")\n#|\n ,\n#}\n )\n#}\n ELSE <* ASSERT"
& " FALSE *>\n END;\n | #(_ALGNAME_)3DViewClass.T (view) =>\n "
& " TYPECASE evt OF\n#{_OUTPUT\n | #(_EVENT_)Args(var#(_EVENT_)Args) "
& "=>\n view.";
CONST E21_0 =
"oe#(_EVENT_) (\n#{\n var#(_EVENT_)Args.#(_ARGNAME_)\n#|\n "
& " ,\n#}\n )\n#}\n#{_UPDATE\n | #(_EVENT_"
& ")Args(var#(_EVENT_)Args) =>\n view.ue#(_EVENT_) (\n#{\n "
& " var#(_EVENT_)Args.#(_ARGNAME_)\n#|\n ,\n#}\n "
& " )\n#}\n ELSE <* ASSERT FALSE *>\n END;\n ELSE (* "
& "this view isn\'t a #(_ALGNAME_)3DViewClass or\n a #(_ALGNAME"
& "_)3DViewClass, so just ignore *)\n END\n END OEDispatcher;\n\nPROCE"
& "DURE FEDispatcher(v: ZeusClass.T; evt: REFANY) =\n <* LL = VBT.mu *>\n"
& " BEGIN\n TYPECASE v OF\n | #(_ALGNAME_)AlgClass.T (alg) =>\n "
& " TYPECASE evt OF\n#{_FEEDBACK\n | #(_EVENT_)Args(var#(_EVENT_)Arg"
& "s) =>\n alg.fe#(_EVENT_) (\n#{\n var#(_EVENT_)Arg"
& "s.#(_ARGNAME_)\n#|\n ,\n#}\n )\n#}\n E"
& "LSE <* ASSERT FALSE *>\n END;\n ELSE (* this alg isn\'t a #(_AL"
& "GNAME_)AlgClass, so just ignore *)\n END\n END FEDispatcher;\n\n\n#"
& "{_OUTPUT\nPROCEDURE #(_EVENT_) (\n initiator: Algorithm.T;\n "
& "#(_ARGSTR_)\n ) RAISES {Thread.Alerted} =\n <* LL = {} *>\n VAR zu"
& "meArgRec := NEW(#(_EVENT_)Args\n#{\n , #(_ARGNAME_) := #("
& "_ARGNAME_)\n#}\n );\n alg := NARROW(initiator, #(_ALGNAME_)Al"
& "gClass.T);\n BEGIN\n LOCK alg.evtMu DO\n INC(alg.eventDataRec."
& "ctOf#(_EVENT_));\n alg.stopAtEvent := alg.eventDataRec.stopAt#(_EV"
& "ENT_);\n alg.waitAtEvent := alg.eventDataRec.waitAt#(_EVENT_);\n "
& " Zeus.Dispatch(initiator, Zeus.EventStyle.Output, #(_EVENTPRIO_),\n "
& " \"#(_EVENT_)\", OEDispatcher, zumeArgRec);\n END;"
& "\n END #(_EVENT_);\n\n#}\n#{_UPDATE\nPROCEDURE #(_EVENT_) (\n ini"
& "tiator: Algorithm.T;\n #(_ARGSTR_)\n ) RAISES {Thread.Alerted} "
& "=\n <* LL = VBT.mu *>\n VAR zumeArgRec := NEW(#(_EVENT_)Args\n#{\n "
& " , #(_ARGNAME_) := #(_ARGNAME_)\n#}\n );\n BEGIN\n "
& "Zeus.Dispatch(initiator, Zeus.EventStyle.Update, #(_EVENTPRIO_),\n "
& " \"#(_EVENT_)\", OEDispatcher, zumeArgRec);\n END #(_EVENT"
& "_);\n\n#}\n\n#{_FEEDBACK\nPROCEDURE #";
CONST E21_1 =
"(_EVENT_) (\n initiator: View.T;\n #(_ARGSTR_)\n ) RAISES "
& "{Thread.Alerted} =\n <* LL = VBT.mu *>\n VAR zumeArgRec := NEW(#(_EVE"
& "NT_)Args\n#{\n , #(_ARGNAME_) := #(_ARGNAME_)\n#}\n "
& ");\n BEGIN\n Zeus.Dispatch(initiator, Zeus.EventStyle.Notify, #(_EV"
& "ENTPRIO_),\n \"#(_EVENT_)\", FEDispatcher, zumeArgRec)"
& ";\n END #(_EVENT_);\n\n#}\n\nBEGIN\nEND #(_ALGNAME_)IE.\n";
CONST E22 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Thu Feb "
& " 9 08:50:12 PST 1995 by kalsow *)\n(* modified on Sun Jun 5 21:5"
& "8:07 PDT 1994 by mhb *)\n(* modified on Wed Feb 17 16:46:35 PS"
& "T 1993 by johnh *)\n\n(**********************************************"
& "***********************\n|* NOTE: This file is generated automatically"
& " from the event\n|* definition file #(_ALGNAME_).evt.\n|********"
& "*************************************************************)\n\n<* PR"
& "AGMA LL *>\n\nINTERFACE #(_ALGNAME_)IE;\n\n$Algorithm\n$Thread\n$View\n"
& "#(_IMPORTS_)\n\n\n(* call the following to generate an event: *)\n\n#{_"
& "OUTPUT\nPROCEDURE #(_EVENT_) (\n initiator: Algorithm.T;\n #("
& "_ARGSTR_)\n ) RAISES {Thread.Alerted};\n <* LL = {} *>\n\n#}\n#{_"
& "FEEDBACK\nPROCEDURE #(_EVENT_) (\n initiator: View.T;\n #(_AR"
& "GSTR_)\n ) RAISES {Thread.Alerted};\n <* LL = VBT.mu *>\n\n#}\n#{"
& "_UPDATE\nPROCEDURE #(_EVENT_) (\n initiator: Algorithm.T;\n #"
& "(_ARGSTR_)\n ) RAISES {Thread.Alerted};\n <* LL = VBT.mu *>\n\n#}"
& "\n\nEND #(_ALGNAME_)IE.\n";
CONST E23 =
"(* Copyright (C) 1995, Digital Equipment Corporation. *)\n(* All "
& "rights reserved. *)\n(* See the fil"
& "e COPYRIGHT for a full description. *)\n(* "
& " *)\n(* Last modified on Wed Feb "
& " 8 15:36:04 PST 1995 by kalsow *)\n(* modified on Sat Jul 17 10:5"
& "5:21 PDT 1993 by mhb *)\n(* modified on Wed Feb 17 16:47:18 PS"
& "T 1993 by johnh *)\n\n(**********************************************"
& "***********************\n|* NOTE: This file is generated automatically"
& " from the event\n|* definition file #(_ALGNAME_).evt.\n|********"
& "*************************************************************)\n\nINTER"
& "FACE #(_ALGNAME_)#(_VIEWNAME_)ObliqView;\nEND #(_ALGNAME_)#(_VIEWNAME_)"
& "ObliqView.\n\n";
BEGIN
END ZoomBundle.