9.7.2 Topic类型信息(Topic Type Information)
设备应添加9.5.4节中定义的MessageDescription的类型MessageDescriptionType元素,下面的所有元素代表设备所支持的Topic集。此外,设备应当按照通知规范,找出所有元素代表包括wstop的Topic:Topic属性值为“true”。
下面的例子演示了如何增强消息描述中TopicSet的Topic集:
<wstop:TopicSet xmlns=""><tns1:RuleEngine><LineDetector><Crossed wstop:topic="true"><tt:MessageDescription><tt:Source><tt:SimpleItemDescription Name="VideoSourceConfigurationToken" Type="tt:ReferenceToken"/><tt:SimpleItemDescription Name="VideoAnalyticsConfigurationToken" Type="tt:ReferenceToken"/><tt:SimpleItemDescription Name="Rule" Type="xs:string"/></tt:Source><tt:Data><tt:SimpleItemDescription Name="ObjectId" Type=" xs:integer"/></tt:Data></tt:MessageDescription></Crossed></LineDetector><FieldDetector><ObjectsInside wstop:topic="true"><tt:MessageDescription IsProperty="true"><tt:Source><tt:SimpleItemDescription Name="VideoSourceConfigurationToken" Type="tt:ReferenceToken"/><tt:SimpleItemDescription Name="VideoAnalyticsConfigurationToken" Type="tt:ReferenceToken"/><tt:SimpleItemDescription Name="Rule" Type="xs:string"/></tt:Source><tt:Key><tt:SimpleItemDescription Name="ObjectId" Type="xs:integer"/></tt;Key><tt:Data><tt:SimpleItemDescription Name="IsInside" Type="xs:boolean"/></tt:Data></tt:MessageDescription></ObjectsInside></FieldDetector></tns1:RuleEngine></wstop:TopicSet>
注意,xmlns=””被包含在这个例子中,以确保任何后代TopicSet元素没有默认命名空间,请参阅[WS-Topic]规范更多信息
