Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » XML Schema Definition (XSD) » Redefine with extension does not pick up the
Redefine with extension does not pick up the [message #63231] Wed, 14 September 2005 23:08 Go to next message
Eclipse UserFriend
Originally posted by: abanerjee.vitria.com

The main schema attached below points to the 2nd schema which redefines
the 3rd schema. The XSDComplexTypeDefintion corresponding to “ClaimType”
points to the 2rd schema. The content of the CompleType is instanceof
XSDRedefine and I can call redefine.getResolvedSchema() or
redefine.getIncorporatedSchema() to get the 3rd schema. How can I resolve
the ComplexType so that it includes the elements from schema 2 and schema
3.

Thanks,
-Anindita.

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:include schemaLocation="ClaimType.xsd"/>
<xsd:element name="Claim" type="ClaimType"/>
</xsd:schema>

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:redefine schemaLocation="../../../bom/Claim/ClaimType.xsd">
<xsd:complexType name="ClaimType">
<xsd:complexContent>
<xsd:extension base="ClaimType">
<xsd:sequence>
<xsd:element name="EncounterFlag" type="xsd:boolean" minOccurs="0"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:redefine>
</xsd:schema>

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:complexType name="ClaimType">
<xsd:sequence>
<xsd:element name="AccidentCountryCode" type="xsd:string"
minOccurs="0"/>
<xsd:element name="AccidentDateTime" type="xsd:dateTime" minOccurs="0"/>
<xsd:element name="AccidentStateCode" type="xsd:string" minOccurs="0"/>
</xsd:sequence>
</xsd:complexType>
</xsd:schema>
Re: Redefine with extension does not pick up the [message #63308 is a reply to message #63231] Thu, 15 September 2005 10:07 Go to previous message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

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

Anindita,

When I renamed these files to a.xsd, b.xsd, and c.xsd and load them it
seems to be working nicely:


I.e., the complex type does include elements from both schemas.

What are you trying?


Anindita Banerjee wrote:

> The main schema attached below points to the 2nd schema which
> redefines the 3rd schema. The XSDComplexTypeDefintion corresponding to
> ?ClaimType? points to the 2rd schema. The content of the CompleType is
> instanceof XSDRedefine and I can call redefine.getResolvedSchema() or
> redefine.getIncorporatedSchema() to get the 3rd schema. How can I
> resolve the ComplexType so that it includes the elements from schema 2
> and schema 3.
>
> Thanks,
> -Anindita.
>
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <xsd:include schemaLocation="ClaimType.xsd"/>
> <xsd:element name="Claim" type="ClaimType"/>
> </xsd:schema>
>
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <xsd:redefine schemaLocation="../../../bom/Claim/ClaimType.xsd">
> <xsd:complexType name="ClaimType">
> <xsd:complexContent>
> <xsd:extension base="ClaimType">
> <xsd:sequence>
> <xsd:element name="EncounterFlag"
> type="xsd:boolean" minOccurs="0"/>
> </xsd:sequence>
> </xsd:extension>
> </xsd:complexContent>
> </xsd:complexType>
> </xsd:redefine>
> </xsd:schema>
>
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <xsd:complexType name="ClaimType">
> <xsd:sequence>
> <xsd:element name="AccidentCountryCode" type="xsd:string"
> minOccurs="0"/>
> <xsd:element name="AccidentDateTime" type="xsd:dateTime"
> minOccurs="0"/>
> <xsd:element name="AccidentStateCode" type="xsd:string"
> minOccurs="0"/>
> </xsd:sequence>
> </xsd:complexType>
> </xsd:schema>
>
>
>
>


--------------080109090309070800050807
Content-Type: multipart/related;
boundary="------------090806080005020705070400"


--------------090806080005020705070400
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">
Anindita,<br>
<br>
When I renamed these files to a.xsd, b.xsd, and c.xsd and load them it
seems to be working nicely:<br>
<blockquote><img src="cid:part1.04010206.05050606@ca.ibm.com" alt=""><br>
</blockquote>
I.e., the complex type does include elements from both schemas. <br>
<br>
What are you trying?<br>
<br>
<br>
Anindita Banerjee wrote:
<blockquote cite="mid6da0fa1aa487f7d16fecdf9ffb5d13b0$1@www.eclipse.org"
type="cite">The main schema attached below points to the 2nd schema
which redefines the 3rd schema. The XSDComplexTypeDefintion
corresponding to &#65533;ClaimType&#65533; points to the 2rd schema. The content of
the CompleType is instanceof XSDRedefine and I can call
redefine.getResolvedSchema() or redefine.getIncorporatedSchema() to get
the 3rd schema. How can I resolve the ComplexType so that it includes
the elements from schema 2 and schema 3.
<br>
<br>
Thanks,
<br>
-Anindita.
<br>
<br>
&lt;xsd:schema xmlns:xsd=<a class="moz-txt-link-rfc2396E" href="http://www.w3.org/2001/XMLSchema">"http://www.w3.org/2001/XMLSchema"</a>&gt;
<br>
Re: Redefine with extension does not pick up the [message #596388 is a reply to message #63231] Thu, 15 September 2005 10:07 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33141
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------080109090309070800050807
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding: 7bit

Anindita,

When I renamed these files to a.xsd, b.xsd, and c.xsd and load them it
seems to be working nicely:


I.e., the complex type does include elements from both schemas.

What are you trying?


Anindita Banerjee wrote:

> The main schema attached below points to the 2nd schema which
> redefines the 3rd schema. The XSDComplexTypeDefintion corresponding to
> ?ClaimType? points to the 2rd schema. The content of the CompleType is
> instanceof XSDRedefine and I can call redefine.getResolvedSchema() or
> redefine.getIncorporatedSchema() to get the 3rd schema. How can I
> resolve the ComplexType so that it includes the elements from schema 2
> and schema 3.
>
> Thanks,
> -Anindita.
>
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <xsd:include schemaLocation="ClaimType.xsd"/>
> <xsd:element name="Claim" type="ClaimType"/>
> </xsd:schema>
>
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <xsd:redefine schemaLocation="../../../bom/Claim/ClaimType.xsd">
> <xsd:complexType name="ClaimType">
> <xsd:complexContent>
> <xsd:extension base="ClaimType">
> <xsd:sequence>
> <xsd:element name="EncounterFlag"
> type="xsd:boolean" minOccurs="0"/>
> </xsd:sequence>
> </xsd:extension>
> </xsd:complexContent>
> </xsd:complexType>
> </xsd:redefine>
> </xsd:schema>
>
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> <xsd:complexType name="ClaimType">
> <xsd:sequence>
> <xsd:element name="AccidentCountryCode" type="xsd:string"
> minOccurs="0"/>
> <xsd:element name="AccidentDateTime" type="xsd:dateTime"
> minOccurs="0"/>
> <xsd:element name="AccidentStateCode" type="xsd:string"
> minOccurs="0"/>
> </xsd:sequence>
> </xsd:complexType>
> </xsd:schema>
>
>
>
>


--------------080109090309070800050807
Content-Type: multipart/related;
boundary="------------090806080005020705070400"


--------------090806080005020705070400
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">
Anindita,<br>
<br>
When I renamed these files to a.xsd, b.xsd, and c.xsd and load them it
seems to be working nicely:<br>
<blockquote><img src="cid:part1.04010206.05050606@ca.ibm.com" alt=""><br>
</blockquote>
I.e., the complex type does include elements from both schemas. <br>
<br>
What are you trying?<br>
<br>
<br>
Anindita Banerjee wrote:
<blockquote cite="mid6da0fa1aa487f7d16fecdf9ffb5d13b0$1@www.eclipse.org"
type="cite">The main schema attached below points to the 2nd schema
which redefines the 3rd schema. The XSDComplexTypeDefintion
corresponding to &#65533;ClaimType&#65533; points to the 2rd schema. The content of
the CompleType is instanceof XSDRedefine and I can call
redefine.getResolvedSchema() or redefine.getIncorporatedSchema() to get
the 3rd schema. How can I resolve the ComplexType so that it includes
the elements from schema 2 and schema 3.
<br>
<br>
Thanks,
<br>
-Anindita.
<br>
<br>
&lt;xsd:schema xmlns:xsd=<a class="moz-txt-link-rfc2396E" href="http://www.w3.org/2001/XMLSchema">"http://www.w3.org/2001/XMLSchema"</a>&gt;
<br>


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:xs:redefine
Next Topic:Redefine does give the resolved schema
Goto Forum:
  


Current Time: Thu Apr 25 20:44:07 GMT 2024

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

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

Back to the top