chromium/net/spdy/bidirectional_stream_spdy_impl.cc

// Copyright 2015 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifdef UNSAFE_BUFFERS_BUILD
// TODO(crbug.com/40284755): Remove this and spanify to fix the errors.
#pragma allow_unsafe_buffers
#endif

#include "net/spdy/bidirectional_stream_spdy_impl.h"

#include <utility>

#include "base/functional/bind.h"
#include "base/location.h"
#include "base/logging.h"
#include "base/task/single_thread_task_runner.h"
#include "base/time/time.h"
#include "base/timer/timer.h"
#include "net/http/bidirectional_stream_request_info.h"
#include "net/spdy/spdy_buffer.h"
#include "net/spdy/spdy_http_utils.h"
#include "net/spdy/spdy_stream.h"

namespace net {

namespace {

// Time to wait in millisecond to notify |delegate_| of data received.
// Handing small chunks of data to the caller creates measurable overhead.
// So buffer data in short time-spans and send a single read notification.
const int kBufferTimeMs =;

}  // namespace

BidirectionalStreamSpdyImpl::BidirectionalStreamSpdyImpl(
    const base::WeakPtr<SpdySession>& spdy_session,
    NetLogSource source_dependency)
    :{}

BidirectionalStreamSpdyImpl::~BidirectionalStreamSpdyImpl() {}

void BidirectionalStreamSpdyImpl::Start(
    const BidirectionalStreamRequestInfo* request_info,
    const NetLogWithSource& net_log,
    bool /*send_request_headers_automatically*/,
    BidirectionalStreamImpl::Delegate* delegate,
    std::unique_ptr<base::OneShotTimer> timer,
    const NetworkTrafficAnnotationTag& traffic_annotation) {}

void BidirectionalStreamSpdyImpl::SendRequestHeaders() {}

int BidirectionalStreamSpdyImpl::ReadData(IOBuffer* buf, int buf_len) {}

void BidirectionalStreamSpdyImpl::SendvData(
    const std::vector<scoped_refptr<IOBuffer>>& buffers,
    const std::vector<int>& lengths,
    bool end_stream) {}

NextProto BidirectionalStreamSpdyImpl::GetProtocol() const {}

int64_t BidirectionalStreamSpdyImpl::GetTotalReceivedBytes() const {}

int64_t BidirectionalStreamSpdyImpl::GetTotalSentBytes() const {}

bool BidirectionalStreamSpdyImpl::GetLoadTimingInfo(
    LoadTimingInfo* load_timing_info) const {}

void BidirectionalStreamSpdyImpl::PopulateNetErrorDetails(
    NetErrorDetails* details) {}

void BidirectionalStreamSpdyImpl::OnHeadersSent() {}

void BidirectionalStreamSpdyImpl::OnEarlyHintsReceived(
    const quiche::HttpHeaderBlock& headers) {}

void BidirectionalStreamSpdyImpl::OnHeadersReceived(
    const quiche::HttpHeaderBlock& response_headers) {}

void BidirectionalStreamSpdyImpl::OnDataReceived(
    std::unique_ptr<SpdyBuffer> buffer) {}

void BidirectionalStreamSpdyImpl::OnDataSent() {}

void BidirectionalStreamSpdyImpl::OnTrailers(
    const quiche::HttpHeaderBlock& trailers) {}

void BidirectionalStreamSpdyImpl::OnClose(int status) {}

bool BidirectionalStreamSpdyImpl::CanGreaseFrameType() const {}

NetLogSource BidirectionalStreamSpdyImpl::source_dependency() const {}

int BidirectionalStreamSpdyImpl::SendRequestHeadersHelper() {}

void BidirectionalStreamSpdyImpl::OnStreamInitialized(int rv) {}

void BidirectionalStreamSpdyImpl::NotifyError(int rv) {}

void BidirectionalStreamSpdyImpl::ResetStream() {}

void BidirectionalStreamSpdyImpl::ScheduleBufferedRead() {}

void BidirectionalStreamSpdyImpl::DoBufferedRead() {}

bool BidirectionalStreamSpdyImpl::ShouldWaitForMoreBufferedData() const {}

bool BidirectionalStreamSpdyImpl::MaybeHandleStreamClosedInSendData() {}

}  // namespace net