]> git.ipfire.org Git - thirdparty/squid.git/blobdiff - src/tests/stub_MemObject.cc
Source Format Enforcement (#532)
[thirdparty/squid.git] / src / tests / stub_MemObject.cc
index 7d2600bf70293165a7d0a70c3b30015736f9017c..ed276878b40e8b6e7001bec01255e72ac88ca329 100644 (file)
@@ -1,7 +1,15 @@
+/*
+ * Copyright (C) 1996-2020 The Squid Software Foundation and contributors
+ *
+ * Squid software is distributed under GPLv2+ license and includes
+ * contributions from numerous individuals and organizations.
+ * Please see the COPYING and CONTRIBUTORS files for details.
+ */
+
 #include "squid.h"
 #include "comm/Connection.h"
-#include "MemObject.h"
 #include "HttpReply.h"
+#include "MemObject.h"
 #if USE_DELAY_POOLS
 #include "DelayPools.h"
 #endif
@@ -21,30 +29,30 @@ MemObject::endOffset() const
 void MemObject::trimSwappable() STUB
 void MemObject::trimUnSwappable() STUB
 int64_t MemObject::policyLowestOffsetToKeep(bool swap) const STUB_RETVAL(-1)
-MemObject::MemObject(char const *, char const *) {} // NOP due to Store
-HttpReply const * MemObject::getReply() const
-{
-    // XXX: required by testStore
-    return NULL;
-}
+MemObject::MemObject() {
+    ping_reply_callback = nullptr;
+    memset(&start_ping, 0, sizeof(start_ping));
+} // NOP instead of elided due to Store
+
+const char *MemObject::storeId() const STUB_RETVAL(NULL)
+const char *MemObject::logUri() const STUB_RETVAL(NULL)
+void MemObject::setUris(char const *aStoreId, char const *aLogUri, const HttpRequestMethod &aMethod) STUB
 void MemObject::reset() STUB
 void MemObject::delayRead(DeferredRead const &aRead) STUB
 bool MemObject::readAheadPolicyCanRead() const STUB_RETVAL(false)
 void MemObject::setNoDelay(bool const newValue) STUB
 MemObject::~MemObject() STUB
-int MemObject::mostBytesWanted(int max) const STUB_RETVAL(-1)
+int MemObject::mostBytesWanted(int max, bool ignoreDelayPools) const STUB_RETVAL(-1)
 #if USE_DELAY_POOLS
 DelayId MemObject::mostBytesAllowed() const STUB_RETVAL(DelayId())
 #endif
-void MemObject::unlinkRequest() STUB
-void MemObject::write(StoreIOBuffer writeBuffer, STMCB *callback, void *callbackData) STUB
-void MemObject::replaceHttpReply(HttpReply *newrep) STUB
+void MemObject::write(const StoreIOBuffer &writeBuffer) STUB
 int64_t MemObject::lowestMemReaderOffset() const STUB_RETVAL(0)
 void MemObject::kickReads() STUB
 int64_t MemObject::objectBytesOnDisk() const STUB_RETVAL(0)
 bool MemObject::isContiguous() const STUB_RETVAL(false)
 int64_t MemObject::expectedReplySize() const STUB_RETVAL(0)
-void MemObject::resetUrls(char const*, char const*) STUB
 void MemObject::markEndOfReplyHeaders() STUB
 size_t MemObject::inUseCount() STUB_RETVAL(0)
 int64_t MemObject::availableForSwapOut() const STUB_RETVAL(0)
+