[xsl] global types - controlying repetitions with a temp var?

Subject: [xsl] global types - controlying repetitions with a temp var?
From: "Sr. Miguel" <neptuno2@xxxxxxxxxxx>
Date: Mon, 15 Jun 2009 11:58:15 +0000
Hello,

Im creating an xml schema using xsl 1.0. In this schema I can have, at the
same level, repetition of elements names. At the same time, Im creating
restrictions to this elements. Because of that, Im getting errors saying that
the same elements must be of the same type (the type is the same, but because
it is custom, the parser sees them as different...).

To solve this I am creating global level types, and then refer to them as the
types of my elements. The problem here is that Im looping a xml file looking
for all the restrictions (and thus types) I should create, and while looping I
will be creating the same types more than one time to my final schema.

What I would like would be to create just one type for each restriction. To
accomplish that, I would like to have a sort of temp variable where I would
write the types Im creating, so that before creating each type, I would search
that variable and see if the type was already created.

Is this possible? Is there any other way to accomplish this?

Thank you
_________________________________________________________________
Windows Live: Keep your life in sync. Check it out!
http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t1_allup_explore_012009

Current Thread