comp.lang.ada
 help / color / mirror / Atom feed
From: Shark8 <onewingedshark@gmail.com>
Subject: What is the best method for transmitting objects/tagged records?
Date: Mon, 6 Jun 2011 17:26:50 -0700 (PDT)
Date: 2011-06-06T17:26:50-07:00	[thread overview]
Message-ID: <b5077222-5c19-40c0-b038-f15cad7f7daa@s9g2000yqm.googlegroups.com> (raw)

I've been stumped for a while trying to consider how to use Streams
and the Distributed Systems Annex (Annex E) together for a parser;
such that a [possibly] remote task can take a stream (parsing text to
tokens could be done on either the client or host-systems and that
division still suffers from this problem) and generate an object from
it.

I'd originally had something like this:
- Entry: Read String
- Entry: Write Object

But this doesn't work for a class-wide object. As the only way to get
an object from a task is via an out parameter (meaning we cannot use
it as an initialization to some class-wide variable); we cannot safely
over-write an existing object of some similar class because we may be
passing out an extended object (which can only be bigger) which would
stamp on the adjacent memory.

So, Dimitry kindly pointed me to the correct way of doing so:
- Entry: Read String
- Entry: Write Tag
- Entry: Write Object over a class-wide variable which had been
initialized to the correct type via the dispatching constructor.

But the package Ada.Tags is of the wrong type/level to be included in
a remote_types or remote_interface package, so I cannot use that
method.

How would you go about transmitting tagged records across partitions
(with the intent that these partitions should be easily separable for
distribution at a later date)?

OR Should I just rewrite my package-hierarchy keeping in mind the
Remote_interface/Remote_Types/etc pragma restrictions?

Further, I concede that perhaps this is the wrong area to try to self-
teach (distributed computing) so any pointers to tutorials for using
the DSA would be welcome.



             reply	other threads:[~2011-06-07  0:26 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-07  0:26 Shark8 [this message]
2011-06-07  1:11 ` What is the best method for transmitting objects/tagged records? Jeffrey Carter
2011-06-07  1:24   ` Shark8
2011-06-07  2:53     ` tmoran
2011-06-07 14:18       ` Shark8
2011-06-07 18:06         ` tmoran
2011-06-08 23:16           ` Shark8
2011-06-09  0:49             ` Randy Brukardt
2011-06-09  1:12               ` Shark8
2011-06-09  5:07               ` Simon Wright
2011-06-09 20:55                 ` Randy Brukardt
2011-06-09 20:57                   ` Randy Brukardt
2011-06-09 23:42                     ` tmoran
2011-06-11 16:52                       ` Marco
2011-06-10  7:16                   ` Simon Wright
2011-06-10  9:40                     ` AdaMagica
2011-06-10 13:32                     ` Robert A Duff
2011-06-10 22:06                       ` Simon Wright
2011-06-10 23:05                         ` Robert A Duff
2011-06-07  3:25     ` Randy Brukardt
2011-06-07 14:19       ` Shark8
replies disabled

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