On 29/11/06, Geoffrey Winn <[EMAIL PROTECTED]> wrote:

On 28/11/06, Caroline Maynard <[EMAIL PROTECTED]> wrote:
>
> I've recently started seeing the value Type::OpenDataObjectType returned
> from a getTypeEnum(). I was a bit surprised to see this - I know it was
> introduced some months back internally to Tuscany, but my understanding
> was that it is not part of the API, or indeed of the specification.
>
> The circumstance is when an element which is not a known type is created
> in the graph. An attempt to introspect the model then results in this
> type being returned. For example, a schema like:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <schema xmlns="http://www.w3.org/2001/XMLSchema";
>         targetNamespace="http://www.example.org/test";
>         xmlns:tns="http://www.example.org/test";>
>
>     <complexType name="TestType" mixed="true">
>         <sequence>
>             <element name="jim" type="string"/>
>             <any namespace="##any" processContents="lax"/>
>         </sequence>
>     </complexType>
>
>     <element name="test" type="tns:TestType"/>
> </schema>
>
> and a document like:
> <?xml version="1.0" encoding="UTF-8"?>
> <tns:test xmlns:tns="http://www.example.org/test";
>           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>           xsi:schemaLocation="http://www.example.org/test cdata2.xsd ">
>   <jim>jim_value</jim>
>   <entry>entry_value</entry>
> </tns:test>
>
> will provoke this problem when I try to get the type of <entry>.
>
> Unfortunately for me, the SDO for PHP code is littered with big switches
> whose discriminator is the TypeEnum, and the valid cases end with
> TextType :-( . I can go and revisit them all to add OpenDataObjectType,
> but first I'd like to understand whether it was your intention to expose
> this type to the user of the API, or if it is showing through where it
> shouldn't.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]



Caroline,

It is not part of the specification and, as far as I know, there is no
likelihood that it will be.

As bst I can tell the change was introduced in May in revision 405735
althoughthere isn't much explanation of what drove it. Does that help?

Regards,

Geoff.



This was introduced when opentype support was added. Is it needed? Don't
know. What do you expect to be returned when you try to get the type of
<entry>??

--
Pete

Reply via email to