Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » XML Schema Definition (XSD) » Where it is refernced ?
Where it is refernced ? [message #54797] Fri, 12 November 2004 16:24 Go to next message
Eclipse User
Originally posted by: spandit2.csc.com

Hi

I am using XSD for first time and I apologise if the question is posted in
wrong group.
I have a schema where several elements are defined . These elements are
refernced by some other elements in the same schema.
For Instance Coverage Element is refernced by Policy Something Like this

<xsd:element name="Policy">
<xsd:complexType>
<xsd:sequence>
<xsd:element ref="Coverage" minOccurs="0" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>

I am trying to find out list of elements such as policy that refernces
coverage ? How can I do that using XSD .

Thanks in advance
Sunil
Re: Where it is refernced ? [message #54824 is a reply to message #54797] Fri, 12 November 2004 17:00 Go to previous message
Eclipse User
Originally posted by: merks.ca.ibm.com

This is a multi-part message in MIME format.
--------------080305060106030508060004
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding: 7bit

Sunil,

Check out the cross referencer in org.eclipse.xsd.util.XSDUtil.

This example might help:

http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDPrototypicalSchema.html#crossReferenceTest(java.io.PrintStream)
< http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDPrototypicalSchema.html#crossReferenceTest%28 java.io.PrintStream%29>

If you load a schema into a resource set, as in the org.eclipse.xsd.test
plugin sample, you can use this to get an index of all the components
and where they are referenced:
< http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDUtil.XSDNamedComponentCrossReferencer.html#fi nd%28org.eclipse.emf.ecore.resource.ResourceSet%29>


http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDUtil.XSDNamedComponentCrossReferencer.html#fi nd(org.eclipse.emf.ecore.resource.ResourceSet)
< http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDUtil.XSDNamedComponentCrossReferencer.html#fi nd%28org.eclipse.emf.ecore.resource.ResourceSet%29>


Sunil wrote:

> Hi
>
> I am using XSD for first time and I apologise if the question is
> posted in wrong group. I have a schema where several elements are
> defined . These elements are refernced by some other elements in the
> same schema. For Instance Coverage Element is refernced by Policy
> Something Like this
>
> <xsd:element name="Policy">
> <xsd:complexType>
> <xsd:sequence>
> <xsd:element ref="Coverage" minOccurs="0" /> </xsd:sequence>
> </xsd:complexType>
> </xsd:element>
>
> I am trying to find out list of elements such as policy that refernces
> coverage ? How can I do that using XSD .
>
> Thanks in advance
> Sunil
>


--------------080305060106030508060004
Content-Type: text/html; charset=ISO-8859-15
Content-Transfer-Encoding: 8bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-15"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Sunil,<br>
<br>
Check out the cross referencer in org.eclipse.xsd.util.XSDUtil.
Re: Where it is refernced ? [message #592503 is a reply to message #54797] Fri, 12 November 2004 17:00 Go to previous message
Ed Merks is currently offline Ed Merks
Messages: 26014
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------080305060106030508060004
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding: 7bit

Sunil,

Check out the cross referencer in org.eclipse.xsd.util.XSDUtil.

This example might help:

http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDPrototypicalSchema.html#crossReferenceTest(java.io.PrintStream)
< http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDPrototypicalSchema.html#crossReferenceTest%28 java.io.PrintStream%29>

If you load a schema into a resource set, as in the org.eclipse.xsd.test
plugin sample, you can use this to get an index of all the components
and where they are referenced:
< http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDUtil.XSDNamedComponentCrossReferencer.html#fi nd%28org.eclipse.emf.ecore.resource.ResourceSet%29>


http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDUtil.XSDNamedComponentCrossReferencer.html#fi nd(org.eclipse.emf.ecore.resource.ResourceSet)
< http://download.eclipse.org/technology/xsd/javadoc/org/eclip se/xsd/util/XSDUtil.XSDNamedComponentCrossReferencer.html#fi nd%28org.eclipse.emf.ecore.resource.ResourceSet%29>


Sunil wrote:

> Hi
>
> I am using XSD for first time and I apologise if the question is
> posted in wrong group. I have a schema where several elements are
> defined . These elements are refernced by some other elements in the
> same schema. For Instance Coverage Element is refernced by Policy
> Something Like this
>
> <xsd:element name="Policy">
> <xsd:complexType>
> <xsd:sequence>
> <xsd:element ref="Coverage" minOccurs="0" /> </xsd:sequence>
> </xsd:complexType>
> </xsd:element>
>
> I am trying to find out list of elements such as policy that refernces
> coverage ? How can I do that using XSD .
>
> Thanks in advance
> Sunil
>


--------------080305060106030508060004
Content-Type: text/html; charset=ISO-8859-15
Content-Transfer-Encoding: 8bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-15"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Sunil,<br>
<br>
Check out the cross referencer in org.eclipse.xsd.util.XSDUtil.
Previous Topic:Where it is refernced ?
Next Topic:Analysing Complex Types derived by extension
Goto Forum:
  


Current Time: Tue Sep 02 15:00:53 EDT 2014

Powered by FUDForum. Page generated in 0.12180 seconds