private void ResetStreamTrail(byte[] data)
        {
            if (data.Length > 0)
            {
                // If this stream can seek then revert it back
                if (_stm.CanSeek)
                {
                    _stm.Position = _stm.Length - data.Length;
                }
                else
                {
                    _stm = new CountedStream(new MemoryStream(data));
                }

                _eof = false;
            }
        }
 /// <summary>
 /// Default constructor
 /// </summary>
 /// <param name="stm"></param>
 public DataWriter(Stream stm)
 {
     _stm = new CountedStream(stm);
 }
 /// <summary>
 /// Default constructor
 /// </summary>
 /// <param name="stm"></param>
 public DataReader(Stream stm)
 {
     _stm = new CountedStream(stm);
 }