I try to explain in other words what other people already wrote to you. Your question contain too less information to be answered. Why?
In my opinion the main problem in your question is that you give us too less information about the subject where you want use XML. XML is a metalanguage and not a language. XML defines only some simple basis rules. For example XHTML, XML Schema or XQuery are XML-based languages. How we can compare there?. It's much more easy to give you recommendation about the usage of some language construction of one language as to give you any recommendation in a very general case.
One can give you general restrictions which have XML elements and which have XML attributes. Some good links you can find in the comment of jasso to your question. But the information along will not solve your problem.
The answer like "elements are seems better in your case" solve your problem also not really. For example, you can write the information, that "Y
is extended to Y1
, Y2
, Y3
" in different ways. For example like
<Y1 base="Y" />
<Y2 base="Y" />
<Y3 base="Y" />
or
<class name="Y1" base="Y" />
<class name="Y2" base="Y" />
<class name="Y3" base="Y" />
or some other ways and not like you wrote in your question. All these XML documents are different XML languages. The problem is not only the information which you have, but also from which side you want look at the information. How we can compare different "XML languages" which can contain the same information? If you write some information in XML file you want probably to read the information sometime later. Depend on what information you need later and in which situation, in which order and so on are required to compare different suggestion XML languages which you can use.
So a general question about the metalanguage XML can not be good answered.