Notes for XML Schema 20081226

本文详细解析了XML Schema中数据类型的定义方式,包括简单类型和复杂类型的派生方法,介绍了基本数据类型及其分组,探讨了字符串、数字等类型的特性,并深入解释了约束属性的应用范围及限制元素。

1.The anySimpleType are quite special as all primitive type is considered as derived by restriction from anySimpleType, but they are call "primitive" (normally, primitive types don't derive from other). The anySimpleType is the base type for anySimpleType, also for those complex types, note that complex type may be derived by restriction or extension.

2.There are 3 approaches to derive a simple type, by restriction, by list and by union.

3.Finally it says that constraining facet can apply to lexical space.

4.Built-in datatypes contain built-in primitive and built-in derived datatype. Datatypes defined by schema author is call user-derived datatype.

5.Built-in datatypes are put together with other xml schema definitions inside namespace "http://www.w3.org/2001/XMLSchema", also, they are separated and put in namespace "http://www.w3.org/2001/XMLSchema-datatypes".

6.String is consider to have the following aspect:
    normalized - contains return, line feed or tab (preserve or replace)?
    tokenized - is normalized, contains leading or trialing spaces, contains internal sequences of two or more spaces (collapse)?
    contains only name characters (not whitespace) - Name and NMTOKEN
    name characters fall into the following groups: letter, number, other character(. : _ -)
    the first character of a string, : Name(:, _ and letters), NCName (non-colonized name, so only _ and letters), NMTOKEN(any name character is ok)
    string may have external constrains, like ID should be unique, IDREF should refer to an existing ID, ENTITY should refer to an external unparsed entity, QName(qualified name, should has a prefix and a postfix separated by a colon, both prefix and postfix should be NCName, also prefix should be declared as a namespace prefix before)

7.Numbers are falled into 2 groups: finite (float, double, and [unsigned](long|int|short|byte) ), infinite (decimal and [[non]positive|negative]integer). Note that decimal can be any number, why float and double are not derived from decimal?

8.Datatype base64Binary and hexBinary are the same in value space (they are both byte array), but different in lexical space (one is base64 coded, another is hexadecimal coded).

9.For datatypes regarding to time, dateTime, time, date, gYearMonth and gYear represent a exact period, duration represent the length of some period, gMonthDay, gDay and gMonth represents some period that will recur.

10.The built-in datatype hierachy.


11.Fundamental facets describe some properties of a datatype which is readonly, that means each datatype has such properties but you can not modify them, I believe is only useful for describing those built-in datatypes so that they can be mapped to other languages. Here's the fundamental facets: equal, ordered, bounded, cardinality, numeric.

12.Restriction facets are placed inside the <restriction> tag, several facets can be used together. All facets except pattern and enumeration facet have a fixed attribute which denote whether derived datatype can override this attribute. All facets have a value attribute to specify the value. All facets's content text are ignored and used as annotation. Some facets can appear more than once, like pattern and enumeration.
<restriction base="xxx">
    <facet_xxx fix="true|false" value="xxx">annotation</facet_xxx>
</restriction>

13.The whitespace, enumeration and pattern facets apply to all datatypes. The maxExclusive, maxInclusive, minExclusive, minInclusive, totalDigits and fractionDigits apply to number. The length, maxLength, minLength apply to string, list and byte array.

14.Notice the phase base type (for derived by XXX).

For "XML Schema Part 2: Datatypes Second Edition", started at "2.5.2 Primitive vs. derived datatypes", ended before "5 Conformance"

内容概要:本文介绍了一套针对智能穿戴设备的跑步/骑行轨迹记录系统实战方案,旨在解决传统运动APP存在的定位漂移、数据断层和路径分析单一等问题。系统基于北斗+GPS双模定位、惯性测量单元(IMU)和海拔传感器,实现高精度轨迹采集,并通过卡尔曼滤波算法修正定位误差,在信号弱环境下利用惯性导航补位,确保轨迹连续性。系统支持跑步与骑行两种场景的差异化功能,包括实时轨迹记录、多维度路径分析(如配速、坡度、能耗)、数据可视化(地图标注、曲线图、3D回放)、异常提醒及智能优化建议,并可通过蓝牙/Wi-Fi同步数据至手机APP,支持社交分享与专业软件导出。技术架构涵盖硬件层、设备端与手机端软件层以及云端数据存储,强调低功耗设计与用户体验优化。经过实测验证,系统在定位精度、续航能力和场景识别准确率方面均达到预期指标,具备良好的实用性和扩展性。; 适合人群:具备一定嵌入式开发或移动应用开发经验,熟悉物联网、传感器融合与数据可视化的技术人员,尤其是从事智能穿戴设备、运动健康类产品研发的工程师和产品经理;也适合高校相关专业学生作为项目实践参考。; 使用场景及目标:① 开发高精度运动轨迹记录功能,解决GPS漂移与断点问题;② 实现跑步与骑行场景下的差异化数据分析与个性化反馈;③ 构建完整的“终端采集-手机展示-云端存储”系统闭环,支持社交互动与商业拓展;④ 掌握低功耗优化、多源数据融合、动态功耗调节等关键技术在穿戴设备中的落地应用。; 阅读建议:此资源以真实项目为导向,不仅提供详细的技术实现路径,还包含硬件选型、测试验证与商业扩展思路,建议读者结合自身开发环境,逐步实现各模块功能,重点关注定位优化算法、功耗控制策略与跨平台数据同步机制的设计与调优。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值