Diffusion .NET API  5.9.24
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Properties Events Pages
PushTechnology.ClientInterface.Client.Topics.IProtocolBufferTopicDetails Interface Reference

Details of a Google Protocol Buffer topic. More...

Inheritance diagram for PushTechnology.ClientInterface.Client.Topics.IProtocolBufferTopicDetails:
PushTechnology.ClientInterface.Client.Topics.ITopicDetails

Public Member Functions

IProtocolBufferTopicDetailsBuilder CreateBuilder ()
 Creates a new protocol buffer topic details builder. More...
 

Additional Inherited Members

- Properties inherited from PushTechnology.ClientInterface.Client.Topics.ITopicDetails
TopicDetailsLevel Level [get]
 Returns the level of detail available. More...
 
TopicType Type [get]
 Returns the topic type. More...
 
ITopicDetailsSchema Schema [get]
 Returns the topic schema. More...
 
ITopicDetailsAttributes Attributes [get]
 Returns the topic attributes. More...
 

Detailed Description

Details of a Google Protocol Buffer topic.

The format of the data is described by a single Google Protocol Buffers message description which is specified when the topic is created.

Updates to such a topic will be from content that contains a Google Protocol Buffer message which will be parsed using the description known to the topic.

The data that is input on an update is checked against the current data state and a delta protocol buffer with only those fields that are different will be generated. If there are no differences then no delta would be required.

The way in which content provided for update is interpreted depends upon the UpdateMode. In partial mode the content is assumed to contain only those optional fields that are being changed, whereas in full mode the content is assumed to contain the full topic state.

When operating in full mode then deletions of optional fields are notified to the clients using a deletion value (see IProtocolBufferTopicDetailsBuilder.DeletionValue(string)).

When operating in partial mode then deletions of optional fields can only be supported using deletion values. The deletion value can be used in update messages to explicitly specify a deletion and then such deletions will be notified to clients using the value.

Deletion of optional fields is only supported for fields of type 'string'. For any other types field deletion is not supported.

It should be noted that 'required' fields will always be sent in deltas and therefore to minimise message size their use is discouraged. Also, if an entry of a 'repeated' field or message is changed then all of the occurrences will be retransmitted in the delta.

Because of the limitations this type of topic will work best if the following recommendations regarding buffer definitions are observed:-

  1. All fields should be 'optional' as 'required' fields cannot be excluded from deltas.
  2. All optional fields should be of type 'string' as other types will not support the notification of deletions.
  3. 'repeated' fields or messages should not be used as all occurrences must always be set in deltas.

When a topic of this type is created it is necessary to provide the full class name of a compiled Protocol Buffers class that is present at the server and also the name of a message defined within that class that represents the topic content.

To create an instance of such details use a builder obtained from the ITopicControl feature as follows:

var control = session.GetTopicControlFeature(); var builder = control.CreateDetailsBuilder<IProtocolBufferTopicDetailsBuilder>();

The minimum that must be provided to the builder is the message details made up of a protocol buffers class and a message name.

Member Function Documentation

IProtocolBufferTopicDetailsBuilder PushTechnology.ClientInterface.Client.Topics.IProtocolBufferTopicDetails.CreateBuilder ( )

Creates a new protocol buffer topic details builder.

Returns
The builder.

The documentation for this interface was generated from the following file: