2002 2003 2004 <2005> 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 | Index | 2002 2003 2004 <2005> 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: Network Accessable Types |
From: | Marty Kraimer <[email protected]> |
To: | [email protected] |
Date: | Mon, 18 Jul 2005 06:27:22 -0500 |
Benjamin Franksen wrote:
On Friday 15 July 2005 14:51, Marty Kraimer wrote:The set of well defined types is: enum NadType { nadTypeUnknown, nadTypeBoolean, nadTypeOctet, nadTypeInt16, nadTypeUInt16, nadTypeInt32, nadTypeUInt32, nadTypeInt64, nadTypeUInt64, nadTypeFloat32, nadTypeFloat64, nadTypeString, nadTypeArray, nadTypeMDArray, nadTypePropertyCatalog, // Following are usefull common types nadTypeTimeStamp, nadTypeEnum, nadTypeMap };We can write down enumerations like that all day long and it won't bring us any further. The real question is:Q: How is a client supposed to find out how to store the data it wants, so that no information is lost?Knowing that something is an array obviously isn't enough, you need to know how large it is and what the element type is. And then you must recursively ask how to describe the element types, and so on.We want to send /structured/ data over the network and we don't want to have a fixed number of data types, that is what we have today in CA. We need a way to describe the structure and send it along with the data (yes, not each time, only whenever necessary). So why stick to this useless enumeration of 'types', of which only some really are types and the others are type /constructors/. A mere enumeration cannot specify what the arguments to the type constructors are.
This does not invalidate the above set of enums. It just means that if the type is nadTypeArray, it must be possible to ask for the element type and number of elements. If the type is nadTypeMDArray, it must be possible to ask for number dimensions, the element type and number of elements. If the type is nadPropertyCatalog, then it must be possible to ask for the number of fields and the type of each element.
Marty