Author: scabanovich
Date: 2007-10-04 08:49:10 -0400 (Thu, 04 Oct 2007)
New Revision: 3998
Modified:
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/XModelObjectLoaderUtil.java
Log:
JBIDE-668
Modified:
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/XModelObjectLoaderUtil.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/XModelObjectLoaderUtil.java 2007-10-04
11:46:18 UTC (rev 3997)
+++
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/util/XModelObjectLoaderUtil.java 2007-10-04
12:49:10 UTC (rev 3998)
@@ -113,9 +113,19 @@
for (int i = 0; i < as.length; i++) {
String xml = as[i].getXMLName();
if(xml == null) continue;
- int k = xml.indexOf('.');
- if(k < 0) continue;
- children.add(xml.substring(0, k));
+ int s = xml.indexOf('|');
+ if(s > 0) {
+ StringTokenizer st = new StringTokenizer(xml, "|");
+ while(st.hasMoreTokens()) {
+ String dxml = st.nextToken();
+ int k = dxml.indexOf('.');
+ if(k >= 0) children.add(dxml.substring(0, k));
+ }
+ } else {
+ int k = xml.indexOf('.');
+ if(k < 0) continue;
+ children.add(xml.substring(0, k));
+ }
}
XChild[] cs = entity.getChildren();
for (int i = 0; i < cs.length; i++) {
@@ -145,9 +155,19 @@
for (int i = 0; i < as.length; i++) {
String xml = as[i].getXMLName();
if(xml == null) continue;
- int k = xml.indexOf('.');
- if(k >= 0) continue;
- attributes.add(xml);
+ int s = xml.indexOf('|');
+ if(s > 0) {
+ StringTokenizer st = new StringTokenizer(xml, "|");
+ while(st.hasMoreTokens()) {
+ String dxml = st.nextToken();
+ int k = dxml.indexOf('.');
+ if(k < 0) attributes.add(dxml);
+ }
+ } else {
+ int k = xml.indexOf('.');
+ if(k >= 0) continue;
+ attributes.add(xml);
+ }
}
return attributes;
}
Show replies by date