24 writes to _offset
System.Formats.Asn1 (24)
System\Formats\Asn1\AsnWriter.BitString.cs (6)
92_offset++; 94_offset += bitString.Length; 171_offset++; 177_offset += MaxCERContentSize; 184_offset++; 188_offset += remainingData.Length;
System\Formats\Asn1\AsnWriter.Boolean.cs (1)
37_offset++;
System\Formats\Asn1\AsnWriter.cs (1)
95_offset = 0;
System\Formats\Asn1\AsnWriter.GeneralizedTime.cs (3)
136_offset += IntegerPortionLength; 138_offset += fraction.Length; 141_offset++;
System\Formats\Asn1\AsnWriter.Integer.cs (6)
164_offset += valueLength; 216_offset += valueLength; 239_offset++; 247_offset += value.Length; 275_offset += value.Length; 288_offset += bytesWritten;
System\Formats\Asn1\AsnWriter.OctetString.cs (3)
99_offset += octetString.Length; 153_offset += MaxCERSegmentSize; 161_offset += remainingData.Length;
System\Formats\Asn1\AsnWriter.Oid.cs (2)
70_offset += wellKnownContents.Length; 142_offset += tmpOffset;
System\Formats\Asn1\AsnWriter.Text.cs (1)
113_offset += size;
System\Formats\Asn1\AsnWriter.UtcTime.cs (1)
114_offset += UtcTimeValueLength;
46 references to _offset
System.Formats.Asn1 (46)
System\Formats\Asn1\AsnWriter.BitString.cs (9)
91_buffer[_offset] = (byte)unusedBitCount; 93bitString.CopyTo(_buffer.AsSpan(_offset)); 151int savedOffset = _offset; 170_buffer[_offset] = 0; 173dest = _buffer.AsSpan(_offset); 183_buffer[_offset] = (byte)unusedBitCount; 186dest = _buffer.AsSpan(_offset); 192Debug.Assert(_offset - savedOffset == expectedSize, $"expected size was {expectedSize}, actual was {_offset - savedOffset}");
System\Formats\Asn1\AsnWriter.Boolean.cs (2)
35Debug.Assert(_offset < _buffer.Length); 36_buffer[_offset] = (byte)(value ? 0xFF : 0x00);
System\Formats\Asn1\AsnWriter.cs (10)
91if (_offset > 0) 94Array.Clear(_buffer, 0, _offset); 119return _offset; 144if (destination.Length < _offset) 150if (_offset == 0) 156bytesWritten = _offset; 157_buffer.AsSpan(0, _offset).CopyTo(destination); 181Debug.Assert(bytesWritten == _offset); 202if (_offset == 0) 209return _buffer.AsSpan(0, _offset).ToArray();
System\Formats\Asn1\AsnWriter.GeneralizedTime.cs (2)
121Span<byte> baseSpan = _buffer.AsSpan(_offset); 140_buffer[_offset] = (byte)'Z';
System\Formats\Asn1\AsnWriter.Integer.cs (12)
146int idx = _offset + valueLength - 1; 153} while (idx >= _offset); 160Debug.Assert(_buffer[_offset] != 0xFF || _buffer[_offset + 1] < 0x80); 198int idx = _offset + valueLength - 1; 205} while (idx >= _offset); 212Debug.Assert(_buffer[_offset] != 0 || _buffer[_offset + 1] > 0x7F); 238_buffer[_offset] = 0; 246value.CopyTo(_buffer.AsSpan(_offset)); 274value.CopyTo(_buffer.AsSpan(_offset)); 287value.TryWriteBytes(_buffer.AsSpan(_offset), out int bytesWritten, isBigEndian: true);
System\Formats\Asn1\AsnWriter.OctetString.cs (6)
98octetString.CopyTo(_buffer.AsSpan(_offset)); 138int savedOffset = _offset; 150dest = _buffer.AsSpan(_offset); 159dest = _buffer.AsSpan(_offset); 165Debug.Assert(_offset - savedOffset == expectedSize, $"expected size was {expectedSize}, actual was {_offset - savedOffset}");
System\Formats\Asn1\AsnWriter.Oid.cs (2)
69wellKnownContents.CopyTo(_buffer.AsSpan(_offset)); 141Buffer.BlockCopy(tmp, 0, _buffer, _offset, tmpOffset);
System\Formats\Asn1\AsnWriter.Text.cs (1)
102Span<byte> dest = _buffer.AsSpan(_offset, size);
System\Formats\Asn1\AsnWriter.UtcTime.cs (2)
98Span<byte> baseSpan = _buffer.AsSpan(_offset); 112_buffer[_offset + 12] = (byte)'Z';