Lines Matching refs:_index
48 private int _index; field in Google.Protobuf.Buffers.ArrayBufferWriter
59 _index = 0; in ArrayBufferWriter()
82 _index = 0; in ArrayBufferWriter()
88 public ReadOnlyMemory<T> WrittenMemory => _buffer.AsMemory(0, _index);
93 public ReadOnlySpan<T> WrittenSpan => _buffer.AsSpan(0, _index);
98 public int WrittenCount => _index;
108 public int FreeCapacity => _buffer.Length - _index;
118 Debug.Assert(_buffer.Length >= _index); in Clear()
119 _buffer.AsSpan(0, _index).Clear(); in Clear()
120 _index = 0; in Clear()
140 if (_index > _buffer.Length - count) in Advance()
143 _index += count; in Advance()
165 Debug.Assert(_buffer.Length > _index); in GetMemory()
166 return _buffer.AsMemory(_index); in GetMemory()
188 Debug.Assert(_buffer.Length > _index); in GetSpan()
189 return _buffer.AsSpan(_index); in GetSpan()