#include "third_party/blink/renderer/platform/loader/fetch/raw_resource.h"
#include <memory>
#include "base/compiler_specific.h"
#include "base/containers/span.h"
#include "base/task/single_thread_task_runner.h"
#include "third_party/blink/public/mojom/fetch/fetch_api_request.mojom-blink.h"
#include "third_party/blink/public/mojom/loader/request_context_frame_type.mojom-blink.h"
#include "third_party/blink/public/platform/platform.h"
#include "third_party/blink/renderer/platform/loader/fetch/buffering_bytes_consumer.h"
#include "third_party/blink/renderer/platform/loader/fetch/fetch_parameters.h"
#include "third_party/blink/renderer/platform/loader/fetch/memory_cache.h"
#include "third_party/blink/renderer/platform/loader/fetch/resource_client_walker.h"
#include "third_party/blink/renderer/platform/loader/fetch/resource_fetcher.h"
#include "third_party/blink/renderer/platform/loader/fetch/response_body_loader.h"
#include "third_party/blink/renderer/platform/network/http_names.h"
#include "third_party/blink/renderer/platform/scheduler/public/thread.h"
#include "third_party/blink/renderer/platform/scheduler/public/thread_scheduler.h"
#include "third_party/blink/renderer/platform/wtf/std_lib_extras.h"
namespace blink {
RawResource* RawResource::FetchSynchronously(FetchParameters& params,
ResourceFetcher* fetcher,
RawResourceClient* client) { … }
RawResource* RawResource::Fetch(FetchParameters& params,
ResourceFetcher* fetcher,
RawResourceClient* client) { … }
RawResource* RawResource::FetchMedia(FetchParameters& params,
ResourceFetcher* fetcher,
RawResourceClient* client) { … }
RawResource* RawResource::FetchTextTrack(FetchParameters& params,
ResourceFetcher* fetcher,
RawResourceClient* client) { … }
RawResource* RawResource::FetchManifest(FetchParameters& params,
ResourceFetcher* fetcher,
RawResourceClient* client) { … }
RawResource::RawResource(const ResourceRequest& resource_request,
ResourceType type,
const ResourceLoaderOptions& options)
: … { … }
void RawResource::AppendData(
absl::variant<SegmentedBuffer, base::span<const char>> data) { … }
class RawResource::PreloadBytesConsumerClient final
: public GarbageCollected<PreloadBytesConsumerClient>,
public BytesConsumer::Client { … };
void RawResource::DidAddClient(ResourceClient* c) { … }
bool RawResource::WillFollowRedirect(
const ResourceRequest& new_request,
const ResourceResponse& redirect_response) { … }
void RawResource::WillNotFollowRedirect() { … }
scoped_refptr<BlobDataHandle> RawResource::DownloadedBlob() const { … }
void RawResource::Trace(Visitor* visitor) const { … }
void RawResource::ResponseReceived(const ResourceResponse& response) { … }
void RawResource::ResponseBodyReceived(
ResponseBodyLoaderDrainableInterface& body_loader,
scoped_refptr<base::SingleThreadTaskRunner> loader_task_runner) { … }
void RawResource::SetSerializedCachedMetadata(mojo_base::BigBuffer data) { … }
void RawResource::DidSendData(uint64_t bytes_sent,
uint64_t total_bytes_to_be_sent) { … }
void RawResource::DidDownloadData(uint64_t data_length) { … }
void RawResource::DidDownloadToBlob(scoped_refptr<BlobDataHandle> blob) { … }
void RawResource::MatchPreload(const FetchParameters& params) { … }
void RawResourceClient::DidDownloadToBlob(Resource*,
scoped_refptr<BlobDataHandle>) { … }
RawResourceClientStateChecker::RawResourceClientStateChecker() = default;
NOINLINE void RawResourceClientStateChecker::WillAddClient() { … }
NOINLINE void RawResourceClientStateChecker::WillRemoveClient() { … }
NOINLINE void RawResourceClientStateChecker::RedirectReceived() { … }
NOINLINE void RawResourceClientStateChecker::RedirectBlocked() { … }
NOINLINE void RawResourceClientStateChecker::DataSent() { … }
NOINLINE void RawResourceClientStateChecker::ResponseReceived() { … }
NOINLINE void RawResourceClientStateChecker::SetSerializedCachedMetadata() { … }
NOINLINE void RawResourceClientStateChecker::ResponseBodyReceived() { … }
NOINLINE void RawResourceClientStateChecker::DataReceived() { … }
NOINLINE void RawResourceClientStateChecker::DataDownloaded() { … }
NOINLINE void RawResourceClientStateChecker::DidDownloadToBlob() { … }
NOINLINE void RawResourceClientStateChecker::NotifyFinished(
Resource* resource) { … }
}