Exemplo n.º 1
0
 /// <summary>
 /// Writes a value to the underlying buffer.
 /// </summary>
 /// <param name="value">The value to write.</param>
 protected void Write(Parameter[] value)
 {
     Write(value.Length);
     foreach (var element in value)
     Write(element);
 }
Exemplo n.º 2
0
 /// <summary>
 /// Reads a value from the underlying buffer.
 /// </summary>
 /// <returns>The value read from the buffer.</returns>
 public Parameter ReadParameter()
 {
     var value = new Parameter();
     value.Key = this.ReadString();
     value.Value = this.ReadDynamicType();
     return value;
 }
Exemplo n.º 3
0
 /// <summary>
 /// Writes a value to the underlying buffer.
 /// </summary>
 /// <param name="value">The value to write.</param>
 protected void Write(Parameter value)
 {
     Write(value.Key);
     Write(value.Value);
 }
Exemplo n.º 4
0
 /// <summary>
 /// Reads a value from the underlying buffer.
 /// </summary>
 /// <returns>The value read from the buffer.</returns>
 public Parameter[] ReadListOfParameter()
 {
     var value = new Parameter[this.ReadInt32()];
     for (int index = 0; index < value.Length; index++)
     value[index] = this.ReadParameter();
     return value;
 }