有谁会写xsd。。。。。。。。。。。。帮帮小菜吧!!!。。。。。。。。

kkkkkkmn 2010-09-27 04:13:02
  <xs:element name="OtherService" >
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:minInclusive value="0"/>
<xs:maxInclusive value="1"/>
</xs:restriction>
</xs:simpleType>
</xs:element>

我写的一个节点的架构要求OtherService节点为数字类型且大于等于0小于等于1且可以为空

问题是以上代码可以实现大于等于0小于等于1 但是做不到可以为空

怎么写可以实现那????
...全文
113 13 打赏 收藏 转发到动态 举报
写回复
用AI写文章
13 条回复
切换为时间正序
请发表友善的回复…
发表回复
liweibird 2010-09-28
  • 打赏
  • 举报
回复
xsd不懂。
顶顶
Ryan20082009 2010-09-28
  • 打赏
  • 举报
回复
你可以先写xml xml比较简单 在根据xml自动让它生成xsd文件。
kkkkkkmn 2010-09-28
  • 打赏
  • 举报
回复
谁能帮帮我
kkkkkkmn 2010-09-27
  • 打赏
  • 举报
回复
[Quote=引用 9 楼 logoout1234 的回复:]
绑顶吧
[/Quote]
请细说
logoout1234 2010-09-27
  • 打赏
  • 举报
回复
绑顶吧
SuperGM 2010-09-27
  • 打赏
  • 举报
回复

<xs:element name="OtherService" >
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:pattern value= "^([01])"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
kkkkkkmn 2010-09-27
  • 打赏
  • 举报
回复
[Quote=引用 5 楼 symbol_bc 的回复:]
xsd确实没用过,帮顶一下!
顺便找了一篇文章
http://degree38.javaeye.com/blog/560680
[/Quote]
谢谢
那篇文章 我看过了 呵呵
那个是关于字符类型的
没有关于int类型的
SuperGM 2010-09-27
  • 打赏
  • 举报
回复
<xs:element name="OtherService" >
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:minInclusive value="0"/>
<xs:maxInclusive value="1"/>
<xs:pattern value= "^([01])"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
symbol_bc 2010-09-27
  • 打赏
  • 举报
回复
xsd确实没用过,帮顶一下!
顺便找了一篇文章
http://degree38.javaeye.com/blog/560680
kkkkkkmn 2010-09-27
  • 打赏
  • 举报
回复
在顶。。。
kkkkkkmn 2010-09-27
  • 打赏
  • 举报
回复
自己顶
kongcn 2010-09-27
  • 打赏
  • 举报
回复
顶一下。
kkkkkkmn 2010-09-27
  • 打赏
  • 举报
回复

<xs:element name="ReferralDate" type="xs:dateTime "/>

还有日期类型 也存在这样的问题
请高手做答?????

110,539

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术 C#
社区管理员
  • C#
  • Web++
  • by_封爱
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

让您成为最强悍的C#开发者

试试用AI创作助手写篇文章吧