コード例 #1
0
        internal void Write(byte[] source, int offsetInBytes, int numberOfBytes)
        {
            if (source == null)
            {
                throw new ArgumentNullException("source");
            }
            int bits = numberOfBytes * 8;

            InternalEnsureBufferSize(m_bitLength + bits);
            NetBitWriter.WriteBytes(source, offsetInBytes, numberOfBytes, m_data, m_bitLength);
            m_bitLength += bits;
        }
コード例 #2
0
        internal void Write(byte[] source)
        {
            if (source == null)
            {
                throw new ArgumentNullException("source");
            }
            int bits = source.Length * 8;

            InternalEnsureBufferSize(m_bitLength + bits);
            NetBitWriter.WriteBytes(source, 0, source.Length, m_data, m_bitLength);
            m_bitLength += bits;
        }