示例#1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Yarhl.IO.DataWriter"/> class.
 /// </summary>
 /// <param name="stream">Stream to write to.</param>
 /// <remarks>
 /// <para>By default the endianess is LittleEndian and
 /// the encoding is UTF-8.</para>
 /// </remarks>
 public DataWriter(DataStream stream)
 {
     Stream          = stream;
     Endianness      = EndiannessMode.LittleEndian;
     DefaultEncoding = Encoding.UTF8;
 }
示例#2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Yarhl.IO.DataReader"/> class.
 /// </summary>
 /// <param name="stream">Stream to read from.</param>
 /// <remarks>
 /// <para>By default the endianness is LittleEndian and
 /// the encoding is UTF-8.</para>
 /// </remarks>
 public DataReader(DataStream stream)
 {
     Stream          = stream;
     Endianness      = EndiannessMode.LittleEndian;
     DefaultEncoding = new UTF8Encoding(false, true);
 }
示例#3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BinaryFormat"/> class.
 /// Creates a stream in memory.
 /// </summary>
 public BinaryFormat()
 {
     Stream = new DataStream();
 }