From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,6516065ab7b5a533 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!nntp.club.cc.cmu.edu!feeder.erje.net!news2.arglkargh.de!news.mixmin.net!aioe.org!not-for-mail From: tmoran@acm.org Newsgroups: comp.lang.ada Subject: Re: Q: Stopping a task running a long simulation Date: Fri, 12 Mar 2010 00:24:41 +0000 (UTC) Organization: Aioe.org NNTP Server Message-ID: References: NNTP-Posting-Host: J4HSNf9Eqj44wTz1J3b8lQ.user.speranza.aioe.org X-Complaints-To: abuse@aioe.org X-Notice: Filtered by postfilter v. 0.8.2 X-Newsreader: Tom's custom newsreader Xref: g2news2.google.com comp.lang.ada:10503 Date: 2010-03-12T00:24:41+00:00 List-Id: > 'Compute' has a generic 'Feedback' procedure for showing progress. > I could with that way give a Boolean, user_abort, to 'Feedback', and > 'Compute' would stop when an ad-hoc exception is raised, and return > normally on its own. Think of a motor and its control panel. The panel does read-only access to certain information in the motor, its speed for instance, which the panel displays. The panel can also write certain information, like Stop, to a switch that the motor periodically (every rotation?) checks. Compute is your motor and the GUI is the control panel. Progress information is regularly written by Compute to a record, which is periodically read by the GUI, and control information is written as needed by the GUI and regularly read by Compute.