comp.lang.ada
 help / color / mirror / Atom feed
* Newbie: Clarification of non-determinsitcis selection in Ada rendevous Mechanism
@ 2000-05-17  0:00 nootah
  2000-05-17  0:00 ` Robert A Duff
  0 siblings, 1 reply; 3+ messages in thread
From: nootah @ 2000-05-17  0:00 UTC (permalink / raw)


Hi people,

Currently studying a course where Ada is referred to but not taught and have
a brief section on Active Objects using the Ada rendevous mechanism as an
example.

Question is: if the selection of action from a select clause is
non-deterministic, then does the active object pause at the select statement
or does it elect one of the processes to wait for - the altter is what I
have been told. My problem with this - if multiple guard conditions are
simultaneously true, and one is selected prior to any call, then what occurs
when one of the client processes calls another guarded func.

e.g. where a=5

    select
        when a>0 =>
            accept(FirstFunc)
        when a<10 =>
            accept(SecondFunc)
        end select
    end select

If object halts at select and waits for request from client
    what happens if func called and guard condition not fulfilled ? -
presumably client blocks until condition met and task can respond - queues
the request and blocks client

On the other hand, if object elects FirstFunc, but client SecondFunc is
first call received - what happens ? presumably .. I have no idea!

Any help gratefully  appeciated .
Cheers
Andy






^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2000-05-17  0:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-05-17  0:00 Newbie: Clarification of non-determinsitcis selection in Ada rendevous Mechanism nootah
2000-05-17  0:00 ` Robert A Duff
2000-05-17  0:00   ` Ted Dennison

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox