--------------------- PatchSet 5880 Date: 2007/10/05 06:32:54 Author: amosjeffries Branch: docs Tag: (none) Log: Various doc comments and whitespace formatting. Some stor/diskio parameters fixes. Members: src/DiskIO/Blocking/BlockingFile.cc:1.4->1.4.2.1 src/DiskIO/Blocking/BlockingFile.h:1.2->1.2.14.1 Index: squid3/src/DiskIO/Blocking/BlockingFile.cc =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/DiskIO/Blocking/BlockingFile.cc,v retrieving revision 1.4 retrieving revision 1.4.2.1 diff -u -r1.4 -r1.4.2.1 --- squid3/src/DiskIO/Blocking/BlockingFile.cc 30 Apr 2007 17:51:42 -0000 1.4 +++ squid3/src/DiskIO/Blocking/BlockingFile.cc 5 Oct 2007 06:32:54 -0000 1.4.2.1 @@ -1,6 +1,6 @@ /* - * $Id: BlockingFile.cc,v 1.4 2007/04/30 17:51:42 squidadm Exp $ + * $Id: BlockingFile.cc,v 1.4.2.1 2007/10/05 06:32:54 amosjeffries Exp $ * * DEBUG: section 47 Store Directory Routines * AUTHOR: Robert Collins @@ -40,8 +40,9 @@ #include "DiskIO/WriteRequest.h" CBDATA_CLASS_INIT(BlockingFile); + void * -BlockingFile::operator new (size_t) +BlockingFile::operator new(size_t sz) { CBDATA_INIT_TYPE(BlockingFile); BlockingFile *result = cbdataAlloc(BlockingFile); @@ -51,15 +52,15 @@ } void -BlockingFile::operator delete (void *address) +BlockingFile::operator delete(void *address) { BlockingFile *t = static_cast(address); cbdataFree(t); } -BlockingFile::BlockingFile (char const *aPath) : fd (-1), closed (true), error_(false) +BlockingFile::BlockingFile(char const *aPath) : fd (-1), closed (true), error_(false) { - assert (aPath); + assert(aPath); debugs(79, 3, "BlockingFile::BlockingFile: " << aPath); path_ = xstrdup (aPath); } @@ -71,7 +72,7 @@ } void -BlockingFile::open (int flags, mode_t mode, IORequestor::Pointer callback) +BlockingFile::open(int flags, mode_t mode, IORequestor::Pointer callback) { /* Simulate async calls */ fd = file_open(path_ , flags); @@ -89,8 +90,12 @@ callback->ioCompletedNotification(); } +/** + * Alias for BlockingFile::open(...) + \copydoc BlockingFile::open(int flags, mode_t mode, IORequestor::Pointer callback) + */ void -BlockingFile::create (int flags, mode_t mode, IORequestor::Pointer callback) +BlockingFile::create(int flags, mode_t mode, IORequestor::Pointer callback) { /* We use the same logic path for open */ open(flags, mode, callback); Index: squid3/src/DiskIO/Blocking/BlockingFile.h =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/DiskIO/Blocking/BlockingFile.h,v retrieving revision 1.2 retrieving revision 1.2.14.1 diff -u -r1.2 -r1.2.14.1 --- squid3/src/DiskIO/Blocking/BlockingFile.h 21 Aug 2006 01:51:50 -0000 1.2 +++ squid3/src/DiskIO/Blocking/BlockingFile.h 5 Oct 2007 06:32:54 -0000 1.2.14.1 @@ -1,6 +1,5 @@ - /* - * $Id: BlockingFile.h,v 1.2 2006/08/21 01:51:50 squidadm Exp $ + * $Id: BlockingFile.h,v 1.2.14.1 2007/10/05 06:32:54 amosjeffries Exp $ * * DEBUG: section 47 Store Directory Routines * AUTHOR: Robert Collins @@ -46,18 +45,18 @@ public: void *operator new(size_t); void operator delete(void *); - BlockingFile (char const *path); + BlockingFile(char const *path); ~BlockingFile(); - virtual void open (int, mode_t, RefCount); - virtual void create (int, mode_t, RefCount); + virtual void open(int flags, mode_t mode, RefCount callback); + virtual void create(int fags, mode_t mode, RefCount callback); virtual void read(ReadRequest *); virtual void write(WriteRequest *); - virtual void close (); + virtual void close(); virtual bool error() const; virtual int getFD() const { return fd;} virtual bool canRead() const; - virtual bool ioInProgress()const; + virtual bool ioInProgress() const; private: static DRCB ReadDone;