Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: third_party/WebKit/Source/platform/exported/WebURLResponse.cpp

Issue 2105713002: Render process changes for ResourceTiming sizes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@resource_timing_sizes_browser_process
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after
487 unsigned short WebURLResponse::remotePort() const 487 unsigned short WebURLResponse::remotePort() const
488 { 488 {
489 return m_private->m_resourceResponse->remotePort(); 489 return m_private->m_resourceResponse->remotePort();
490 } 490 }
491 491
492 void WebURLResponse::setRemotePort(unsigned short remotePort) 492 void WebURLResponse::setRemotePort(unsigned short remotePort)
493 { 493 {
494 m_private->m_resourceResponse->setRemotePort(remotePort); 494 m_private->m_resourceResponse->setRemotePort(remotePort);
495 } 495 }
496 496
497 long long WebURLResponse::encodedBodyLength() const
498 {
499 return m_private->m_resourceResponse->encodedBodyLength();
500 }
501
502 void WebURLResponse::addToEncodedBodyLength(long long length)
503 {
504 m_private->m_resourceResponse->addToEncodedBodyLength(length);
505 }
506
507 void WebURLResponse::addToResponseBodySize(long long bytes)
508 {
509 m_private->m_resourceResponse->addToResponseBodySize(bytes);
510 }
511
497 WebURLResponse::ExtraData* WebURLResponse::getExtraData() const 512 WebURLResponse::ExtraData* WebURLResponse::getExtraData() const
498 { 513 {
499 RefPtr<ResourceResponse::ExtraData> data = m_private->m_resourceResponse->ge tExtraData(); 514 RefPtr<ResourceResponse::ExtraData> data = m_private->m_resourceResponse->ge tExtraData();
500 if (!data) 515 if (!data)
501 return 0; 516 return 0;
502 return static_cast<ExtraDataContainer*>(data.get())->getExtraData(); 517 return static_cast<ExtraDataContainer*>(data.get())->getExtraData();
503 } 518 }
504 519
505 void WebURLResponse::setExtraData(WebURLResponse::ExtraData* extraData) 520 void WebURLResponse::setExtraData(WebURLResponse::ExtraData* extraData)
506 { 521 {
507 m_private->m_resourceResponse->setExtraData(ExtraDataContainer::create(extra Data)); 522 m_private->m_resourceResponse->setExtraData(ExtraDataContainer::create(extra Data));
508 } 523 }
509 524
510 void WebURLResponse::assign(WebURLResponsePrivate* p) 525 void WebURLResponse::assign(WebURLResponsePrivate* p)
511 { 526 {
512 // Subclasses may call this directly so a self-assignment check is needed 527 // Subclasses may call this directly so a self-assignment check is needed
513 // here as well as in the public assign method. 528 // here as well as in the public assign method.
514 if (m_private == p) 529 if (m_private == p)
515 return; 530 return;
516 if (m_private) 531 if (m_private)
517 m_private->dispose(); 532 m_private->dispose();
518 m_private = p; 533 m_private = p;
519 } 534 }
520 535
521 } // namespace blink 536 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698