Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [wtp-dev] Translator that handles "ANY" content as specified by DTD?

Thanks for the response, Michael. After wandering through Translator code for a few hours, I had a feeling there was going to be no out-of-the-box solution. Ah, well - now the fun begins!
 - Ian
-----Original Message-----
From: Michael Elder [mailto:mdelder@xxxxxxxxxx]
Sent: Friday, May 19, 2006 1:29 PM
To: ian.trimble@xxxxxxxxxx; General discussion of project-wide or architectural issues.
Cc: wtp-dev@xxxxxxxxxxx; wtp-dev-bounces@xxxxxxxxxxx
Subject: Re: [wtp-dev] Translator that handles "ANY" content as specified by DTD?

Hi Ian,

        The Translators are designed for static XML models. At the time they were designed and implemented, things like "any" groups and XML substitution groups were not in heavy use and were not required for the Translator use cases. I'm not currently aware of cases where Translators were used to solve this problem. You're very likely going to have implement your own custom Translator to handle this case.

Kind Regards,

Michael D. Elder
Rational Studio / Services Tools Development    
Ext: (919) 543-8356
T/L:  441-8356

"Ian Trimble" <ian.trimble@xxxxxxxxxx>
Sent by: wtp-dev-bounces@xxxxxxxxxxx

05/19/2006 04:09 PM

Please respond to
"ian.trimble@xxxxxxxxxx" <ian.trimble@xxxxxxxxxx>; Please respond to
"General discussion of project-wide or architectural issues." <wtp-dev@xxxxxxxxxxx>

"wtp-dev@xxxxxxxxxxx" <wtp-dev@xxxxxxxxxxx>
[wtp-dev] Translator that handles "ANY" content as specified by DTD?

The JSF Tools Project team is wrestling with an issue with the faces-config DTD, and I'm hoping that someone can shed some light or offer some advice on how we might address our issue.
The faces-config DTD defines several elements that allow a content type of "ANY", and typically these elements will contain XML structures that should not be parsed (not initially, anyway), but rather should be set as the value of an attribute of the parent element. We're obviously not configuring our Translator correctly for this case, as we get an IllegalStateException when the parent Translator attempts to find a Translator that matches an undefined child element. The case we're currently looking at is where there is embedded JSR-276 format metadata, but we cannot assume that JSR-276 will always be the format of the metadata.
Is there a way for us to configure an existing Translator to not attempt to parse the content (even when it is XML), but rather to assign it all, unparsed, to an attribute of the parent element? Or should we be looking at writing our own Translator subclass to handle such a case?
Is anyone willing to step forward to offer some assistance, so perhaps we can take this discussion off the wtp-dev list so as not to further disturb the masses?
Any tips, tricks, hints, etc. greatly appreciated,
 - Ian
Ian Trimble
JDeveloper Group
Oracle Corporation Canada Inc.
Office: (250) 954-0837
Email: ian.trimble@xxxxxxxxxx
This email may contain confidential and privileged material for the sole use of the intended recipient. Any review or distribution by others is strictly prohibited. If you are not the intended recipient please contact the sender and delete all copies.
wtp-dev mailing list

Back to the top