public class StreamMessageBuilder

Summary

Constructs AMQP Basic-class messages binary-compatible with QPid's "StreamMessage" wire encoding.

Field Summary

Flags Type Name Summary
public const string MimeType

MIME type associated with QPid StreamMessages.

Constructor Summary

Flags Name Summary
public StreamMessageBuilder(IModel model)

Construct an instance for writing. See .

public StreamMessageBuilder(IModel model, int initialAccumulatorSize)

Construct an instance for writing. See .

Method Summary

Flags Name Summary
public virtual string GetDefaultContentType()

Returns the default MIME content type for messages this instance constructs, or null if none is available or relevant.

public virtual final IStreamMessageBuilder WriteBool(bool value)

Writes a value into the message body being assembled.

public virtual final IStreamMessageBuilder WriteByte(byte value)

Writes a value into the message body being assembled.

public virtual final IStreamMessageBuilder WriteBytes(byte[] source, int offset, int count)

Writes a section of a byte array into the message body being assembled.

public virtual final IStreamMessageBuilder WriteBytes(byte[] source)

Writes a array into the message body being assembled.

public virtual final IStreamMessageBuilder WriteChar(char value)

Writes a value into the message body being assembled.

public virtual final IStreamMessageBuilder WriteDouble(double value)

Writes a value into the message body being assembled.

public virtual final IStreamMessageBuilder WriteInt16(short value)

Writes a value into the message body being assembled.

public virtual final IStreamMessageBuilder WriteInt32(int value)

Writes an value into the message body being assembled.

public virtual final IStreamMessageBuilder WriteInt64(long value)

Writes a value into the message body being assembled.

public virtual final IStreamMessageBuilder WriteObject(object value)

Writes an value into the message body being assembled.

public virtual final IStreamMessageBuilder WriteObjects(object[] values)

Writes objects using WriteObject(), one after the other. No length indicator is written. See also .

public virtual final IStreamMessageBuilder WriteSingle(single value)

Writes a value into the message body being assembled.

public virtual final IStreamMessageBuilder WriteString(string value)

Writes a string value into the message body being assembled.

Field Detail

public const string MimeType

Summary

MIME type associated with QPid StreamMessages.

Constructor Detail

StreamMessageBuilder

public StreamMessageBuilder(IModel model)

Parameters
Name Type
model IModel

Summary

Construct an instance for writing. See .

StreamMessageBuilder

public StreamMessageBuilder(IModel model, int initialAccumulatorSize)

Parameters
Name Type
model IModel
initialAccumulatorSize int

Summary

Construct an instance for writing. See .

Method Detail

GetDefaultContentType

public virtual string GetDefaultContentType()

Flags public virtual
Return type string

Summary

Returns the default MIME content type for messages this instance constructs, or null if none is available or relevant.

WriteBool

public virtual final IStreamMessageBuilder WriteBool(bool value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value bool

Summary

Writes a value into the message body being assembled.

WriteByte

public virtual final IStreamMessageBuilder WriteByte(byte value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value byte

Summary

Writes a value into the message body being assembled.

WriteBytes

public virtual final IStreamMessageBuilder WriteBytes(byte[] source, int offset, int count)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
source byte[]
offset int
count int

Summary

Writes a section of a byte array into the message body being assembled.

WriteBytes

public virtual final IStreamMessageBuilder WriteBytes(byte[] source)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
source byte[]

Summary

Writes a array into the message body being assembled.

WriteChar

public virtual final IStreamMessageBuilder WriteChar(char value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value char

Summary

Writes a value into the message body being assembled.

WriteDouble

public virtual final IStreamMessageBuilder WriteDouble(double value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value double

Summary

Writes a value into the message body being assembled.

WriteInt16

public virtual final IStreamMessageBuilder WriteInt16(short value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value short

Summary

Writes a value into the message body being assembled.

WriteInt32

public virtual final IStreamMessageBuilder WriteInt32(int value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value int

Summary

Writes an value into the message body being assembled.

WriteInt64

public virtual final IStreamMessageBuilder WriteInt64(long value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value long

Summary

Writes a value into the message body being assembled.

WriteObject

public virtual final IStreamMessageBuilder WriteObject(object value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value object

Summary

Writes an value into the message body being assembled.

Remarks

The only permitted types are bool, int, short, byte, char, long, float, double, byte[] and string.

WriteObjects

public virtual final IStreamMessageBuilder WriteObjects(object[] values)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
values object[]

Summary

Writes objects using WriteObject(), one after the other. No length indicator is written. See also .

WriteSingle

public virtual final IStreamMessageBuilder WriteSingle(single value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value single

Summary

Writes a value into the message body being assembled.

WriteString

public virtual final IStreamMessageBuilder WriteString(string value)

Flags public virtual final
Return type IStreamMessageBuilder
Parameters
Name Type
value string

Summary

Writes a string value into the message body being assembled.