Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » ServerTools (WTP) » How to get a schema parent?
How to get a schema parent? [message #536198] Thu, 27 May 2010 11:16
Walter Brunauer is currently offline Walter BrunauerFriend
Messages: 6
Registered: July 2009
Junior Member
Hi there,

please ignore my ignorance, but I can't find an obvious way to get the schema parent of a given schema node. I would like to have something similar to org.w3c.dom.Node.getParentNode() in org.eclipse.wst.xml.core.internal.contentmodel.CMNode. I can't believe I am the first one needing this API.

My best choice currently is to look up the parent top down starting from the schema root, and if I find the given schema node, I take the schema parent I just came from in the recursion. This of course is cumbersome and expensive. Another way would be to cache all child-parent relations, but again, this is way off being ideal.

Is this really the best approach?

Any help highly appreciated!

Thanks a lot in advance,

Walter Brunauer
Previous Topic:How to get hold of appropriate Document object for XML Content Assist ?
Next Topic:How to ignore a symlinked folder in a validator
Goto Forum:

Current Time: Sat Mar 06 14:12:42 GMT 2021

Powered by FUDForum. Page generated in 0.01963 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top