Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!ukma!tut.cis.ohio-state.edu!att!cbnewsl!dog From: dog@cbnewsl.ATT.COM (edward.n.schiebel) Newsgroups: comp.lang.c++ Subject: Re: Objectifying incoming messages? Message-ID: <1273@cbnewsl.ATT.COM> Date: 27 Jul 89 13:57:45 GMT References: <444@cimshop.UUCP> Organization: AT&T Bell Laboratories Lines: 15 From article <444@cimshop.UUCP>, by davidm@cimshop.UUCP (David Masterson): > The fundamental question hinges around the lack of context of the incoming > message. Therefore, the message user must look at the data in order to > determine what to coerce (definition?) the message into. Is this appropriate > or is there a better way? > The same problem arises reading objects from disk. Until you look at the data, you don't know what class of object to instance so it can read itself. It seems to me, this is one place you still need a header/type field and a switch statement. Ed Schiebel AT&T Bell Labs att!vilya!dog