public static void SerializeStreamData(IStreamWriter stream, StreamDataCommand command) { ChannelIdSerializer.SerializeChannelId(stream, command.Channel); StreamOffsetSerializer.SerializeStreamOffset(stream, command.Offset); stream.WriteBool(command.IsAtEndPosition); stream.WriteLength((ushort)command.Payload.Length); stream.WriteOctets(command.Payload); }
public static void SerializePublishStream(IStreamWriter stream, PublishStreamCommand command) { ChannelIdSerializer.SerializeChannelId(stream, command.Channel); stream.WriteOctets(command.Payload); }