System\ServiceModel\Channels\HttpChannelHelpers.cs (6)
207return DecodeBufferedMessage(new ArraySegment<byte>(buffer, 0, offset), inputStream);
575message = this.messageEncoder.ReadMessage(new ArraySegment<byte>(buffer, 0, length), this.bufferManager, this.ContentType);
628return new ArraySegment<byte>(bufferManager.TakeBuffer(bufferSize), 0, bufferSize);
763this.message = this.httpInput.DecodeBufferedMessage(new ArraySegment<byte>(buffer.Array, 0, offset), inputStream);
1564this.content = new ArraySegment<byte>(content, offset, count);
1937return new ArraySegment<byte>(byteArray, 0, byteArray.Length);
System\ServiceModel\Channels\WebSocketTransportDuplexSessionChannel.cs (11)
664new ArraySegment<byte>(internalBuffer, receivedByteCount, internalBuffer.Length - receivedByteCount),
877new ArraySegment<byte>(buffer, 0, this.receiveBufferSize),
976new ArraySegment<byte>(buffer, 0, count),
987ArraySegment<byte> bytes = new ArraySegment<byte>(buffer, 0, count);
1191Task<int> task = this.webSocket.ReceiveAsync(new ArraySegment<byte>(buffer, offset, count), cancellationTokenSource.Token).ContinueWith(t =>
1261Task<WebSocketReceiveResult> task = this.webSocket.ReceiveAsync(new ArraySegment<byte>(buffer, offset, count), CancellationToken.None);
1319Task task = this.webSocket.SendAsync(new ArraySegment<byte>(buffer, offset, count), this.outgoingMessageType, false, CancellationToken.None);
1349Task task = this.webSocket.SendAsync(new ArraySegment<byte>(buffer, offset, count), this.outgoingMessageType, false, cancellationTokenSource.Token).ContinueWith(t =>
1381Task task = this.webSocket.SendAsync(new ArraySegment<byte>(EmptyArray<byte>.Instance, 0, 0), this.outgoingMessageType, true, CancellationToken.None);
1405Task task = this.webSocket.SendAsync(new ArraySegment<byte>(EmptyArray<byte>.Instance, 0, 0), this.outgoingMessageType, true, cancellationTokenSource.Token);
1449this.initialReadBuffer = new ArraySegment<byte>(this.initialReadBuffer.Array, this.initialReadBuffer.Offset + bytesToCopy, this.initialReadBuffer.Count - bytesToCopy);