- From: Phenix Shieh <phenix_shieh@hotmail.com>
- Date: Sat, 6 Apr 2002 23:09:51 +0800
- To: <www-xml-query-comments@w3.org>
- Message-ID: <OE28LACT3bMZJOe5OW70001c98e@hotmail.com>
When I tried to go-through the FS document,a strange occured. What I used was founded in UseCase Doc.: <book year={$b/@year}>...</book> As the FS said,this element constructor should be normalized into computed element construtor.So,it should be rewriten like this: element book{ attribute year {$b/@year}, ... } I focused this line:attribute year {$b/@year}. As the rule says: ///////////////////////////////////////////////////////////////// statEnvs |- expand(QName) = qname statEnvs |- ExprSequence : Type1 Type1 <: xs:AnySimpleType --------------------------------- statEnvs |- attribute QName { ExprSequence } : attribute qname { Type1 } +++ RULE 1+++ ///////////////////////////////////////////////////////////////// The ExprSequence is "$b/@year" and the QName is year. I had set a statEnvs that $b has the type: element book{ attribute year {xsd:integer}, ... } After some caculate(do as the FS told me),the type of "$b/@year" is : attribute year{ xsd:integer} So,Type1 in RULE1 is : Type1=attribute year{ xsd:integer} Using all these in RULE1,I either got the result: attribute year { attribute year {xsd:integer} } or the RULE1 must not be used because Type1 was not the subtype of xs:AnySimpleType(how should i do in this case?). The wannted result is: attribute year { xsd:integer} Here the wrong was! Perhaps we need another rule to solve this problem. May I'm wrong since I only read the new FS only one time.But i will be appreciated if someone can explain this strange thing. PS:I cannot visit the mail listing archive,so email reply is warmly welcomed.:-P从网站得到更多信息。MSN Explorer 免费下载:http://explorer.msn.com/lccn
Received on Saturday, 6 April 2002 10:06:39 UTC