Gabriel and I had a discussion about this before and I have run across it recently as well, the question of wether a type can be anonymous.

The javadoc on ComplexTypeBuilder says name *must* be set before calling build(). I think we need to relax this restriction and allow people to have types will no names. I guess my only example of such a case is an xml schema element which defines its type inline.

If agreed, the question is how do we represent it in our model. With our TypeName / AttributeName system we can do it in a couple of ways. We could:

1. Just set the name to null
2. Create a name object in which both the local name and namespace uri are noth null.

I like one better, I think it makes it simple for client code to check.

-Justin


--
Justin Deoliveira
[EMAIL PROTECTED]
The Open Planning Project
http://topp.openplans.org


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to