Entry Format Type
Two types of Entries exist: Type 1 Entries for Services and Type 2 Entries for Eventgroups.
Type field of the Entry:
- Layout of Type 1 Entries (Entries for Service):
0x00:FindService
0x01:OfferService和StopOfferService - Layout of Type 2 Entries ( Entries for Eventgroups)
0x06:SubscribeEventgroup和StopSubscribeEventgroup
0x07:SubscribeEventgroupAck和SubscribeEventgroupNack
Entry Format
- If the number of options is set to zero, the option run is considered empty.
如果option的数量设置为零,则option run被视为空。 - For empty runs the Index shall be set to zero.
如果option run为空,index也应设置为零。 - Implementations shall accept and process incoming SD messages with option run length set to zero and option index not set to zero.
实施应接受并处理option run length设置为0且option index未设置为0的SD传入消息。
Index 1st options
the index of the first option of the first option run of this entry in the option array
option array中的第一个 option run中的第一个option的索引
Index 2st options
the index of the first option of the second option run of this entry in the option array
option array中的第二个option run中的第一个option的索引
# of opt 1
the “Number of Option 1” shall carry the number of options the first option run uses
“Number of Option 1”应包含first option run使用的选项的数量
#of opt 2
the “Number of Option 2” shall carry the number of options the second option run uses
“Number of Option 2”应包含second option run使用的选项的数量
Service ID and Instance ID
- Service ID 和 instance ID字段应具有固定的16位大小。
Servcie或者Eventgroups的Service ID使用参数SdServerServiceID和SdClientServiceID进行静态配置,具体取决于服务器或客户端entry。
Service或者Eventgroups Service的Instance ID使用参数SdServerServiceInstanceID和SdClientServiceInstanceID进行静态配置,具体取决于服务器还是客户端entry。 - If not a single but all instances are addressed, the Instance ID field of the Type 1 Entry format layout shall be set to 0xFFFF
对于Entries for Service,如果不是单个实例而是所有实例都被寻址,instance ID字段应设置为0xFFFF。
Major version
- The Major Version field shall have a fixed size of 8 bits.
Major Version字段应具有固定的8位大小。 - The Major Version field shall carry the SdServerServiceMajorVersion and SdClientServiceMajorVersion, depending on being a server or client entry.
Major Version字段应包含SdServerServiceMajorVersion和SdClientServiceMajorVersion,具体取决于服务器或客户端entry。
Minor Version
- The Minor Version field of the Type 1 Entry format layout shall have a fixed size of 32 bits.
Type类型1条目格式布局的Minor Version应具有固定的32位大小。 - The Minor Version field of the Type 1 Entry format layout shall carry the SdServerServiceMinorVersion and SdClientServiceMinorVersion.
Type类型1条目格式布局的Minor Version字段应携带SdServerServiceMinorVersion和SdClientServiceMinorVersion。
TTL
- The TTL field shall have a fixed size of 24 bits.
TTL字段应具有固定的24位大小。 - The TTL defines the lifetime of the entry.
TTL字段定义条目的生存期。 - The TTL field defines the lifetime of the entry in seconds configured using the parameter SdServerTimerTTL and SdClientTimerTTL, except for Stop- or Nack-Entries, which use a TTL of 0.
TTL字段使用参数SdServerTimerTTL和SdClientTimerTTL以秒为单位定义生命周期,除了TTL本身为0的Stop-或Nack-Entry外。
Reserved Field
- The Reserved field shall have a fixed size of 16 bits.
保留字段应具有固定的16位大小。 - The Reserved field, which follows the TTL field shall be statically set to 0x0000.
TTL字段后面的保留字段应静态设置为0x0000。
Eventgroup ID
- The Eventgroup ID field shall have a fixed size of 16 bits.
Eventgroup ID字段应具有固定的16位大小。 - The Eventgroup ID field shall carry the ID of an Eventgroup, configured using the parameter SdConsumedEventGroupID.
Eventgroup ID字段应携带使用参数SdConsumedEventGroupID配置的事件组的ID。 - An eventgroup shall be identified using the Eventgroup-ID.
一个事件组需要使用Eventgroup ID。 - Different eventgroups of a service shall have different Eventgroup-IDs.
服务的不同Eventgroup应具有不同的 Eventgroup ID。 - An event shall be part of zero to many eventgroups and an eventgroup shall contain zero to many events. A field shall be part of zero to – many eventgroups and an eventgroup can contain zero to many fields.
一个Event应该是许多Eventgroup的一部分,一个Eventgroup应包含许多Event。一个Field应该是许多Eventgroup的一部分,而Eventgroup可以包含许多Field。 - Currently empty eventgroups are not used and events as well as fields are mapped to at least one eventgroup.
目前没有使用空的Eventgroups ,Event以及Field被映射到至少一个Eventgroup 。