Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Watsh Rajneesh notes mistake???

 
Ranch Hand
Posts: 71
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't understand the follow citation in pag. 51 of Watsh Rajneesh notes in SCDJWS links.


"If you need
to import an XML schema element, you should do so in the XML schema definition contained in the
WSDL types element, using the standard XML schema import statement. You cannot use the XML
schema import statement to import an XML schema directly from the types element of some other
WSDL document."


The first sentence is ambiguos with the next. Can somebody help me?
Thanks
 
Author & Gold Digger
Posts: 7617
6
IntelliJ IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think the second sentence should read:
"You cannot use the WSDL schema import statement to import an XML schema directly from the types element of some other WSDL document."
 
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I can understand your confusion but here's my clarification:

Statement 1 states that you can use xml schema import statement to import an xml schema definition to be used in WSDL types element.

Statement 2 states that in the above mentioned (Statement 1's use of xml schema import) you cannot import an xml schema definition from types element of some other WSDL document that is to say, the xml schema definition import has to come from some other xml schema file (.xsd) and not another .wsdl file's types element (where you could have defined some xml schema simple/complex type).

Also excerpts from the WSI-BP 1.0 document: (See this).


5.1.2 WSDL and Schema Import

Some examples in WSDL 1.1 incorrectly show the WSDL import statement being used to import XML Schema definitions. The Profile clarifies use of the import mechanisms to keep them consistent and confined to their respective domains. Imported schema documents are also constrained by XML version and encoding requirements consistent to those of the importing WSDL documents.

R2001 A DESCRIPTION MUST only use the WSDL "import" statement to import another WSDL description.

R2002 To import XML Schema Definitions, a DESCRIPTION MUST use the XML Schema "import" statement.

R2003 A DESCRIPTION MUST use the XML Schema "import" statement only within the xsd:schema element of the types section.

R2004 A DESCRIPTION MUST NOT use the XML Schema "import" statement to import a Schema from any document whose root element is not "schema" from the namespace "http://www.w3.org/2001/XMLSchema". This is exactly what the second statement means in my notes. The xml schema import statement can only import from another XSD and should NOT import type definitions from another WSDL's type element.



I hope now it should be clear .
[ October 20, 2006: Message edited by: Watsh Rajneesh ]
 
Valentin Crettaz
Author & Gold Digger
Posts: 7617
6
IntelliJ IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here is an example that further illustrates Watsh's point:

LEGAL



NOT LEGAL


[ October 24, 2006: Message edited by: Valentin Crettaz ]
[ October 24, 2006: Message edited by: Valentin Crettaz ]
 
Watsh Rajneesh
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you Val for the illustrative example.
 
If you settle for what they are giving you, you deserve what you get. Fight for this tiny ad!
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic