On Fri, 30 Apr 2004 15:43, Andrew Ho wrote:
> � Just as an example, how would OpenEHR "model" telephone1 and telephone2?
>
> > The reason we and many others have gone to the trouble of doing more
> > than simple-minded modelling is to get out of the numerous problems that
> > such modelling brings with it.
>
> � There are always design trade-offs. Let's investigate this simple
> example a bit more so we can better understand the benefits and risks of
> using simple-minded vs. impractical modelling approaches. :-)
For this concrete simple example:
1.) reality is that people have none to many phone numbers. I, for example,
have 6 that are relevant to my person.
2.) Such telephone numbers usually require an attribute to tell which number
to use for what purpose.
Hence, the ideal mapping to a XML-RPC compatible data type would be a
"dictionary list" (list of key:value pairs) like (simplified for readability)
<phone>
<location = "home"> 1234567 </location>
<location = "work"> 2345678 </location>
<location = "mobile private"> 1234567 </location>
<location = "mobile work"> 1234567 </location>
<location = "fax"> 1234567 </location>
</phone>
A remote procedure call would then be provided to retrieve
all phone numbers belonging to an individual.
Due to the substantial call overhead and inherent redundancy of XML-RPC, you
would always try to anticipate further queries in your return values, hence
you would not just query for "fax number" but simply for all phone numbers
and parse the returned structure on the client side.
Horst