コード例 #1
0
ファイル: Gauge32.cs プロジェクト: UntilNick/sharpsnmplib
        /// <summary>
        /// Appends the bytes to <see cref="Stream"/>.
        /// </summary>
        /// <param name="stream">The stream.</param>
        public void AppendBytesTo(Stream stream)
        {
            if (stream == null)
            {
                throw new ArgumentNullException(nameof(stream));
            }

            stream.AppendBytes(TypeCode, _count.GetLengthBytes(), _count.GetRaw());
        }
コード例 #2
0
        /// <summary>
        /// Appends the bytes to <see cref="Stream"/>.
        /// </summary>
        /// <param name="stream">The stream.</param>
        public void AppendBytesTo(Stream stream)
        {
            if (stream == null)
            {
                throw new ArgumentNullException("stream");
            }

            ByteTool.AppendBytes(stream, TypeCode, _count.GetRaw());
        }