style/whitespace

This commit is contained in:
Günter Obiltschnig
2021-06-26 06:30:49 +02:00
parent 9155121866
commit 70da508a79
9 changed files with 80 additions and 80 deletions

View File

@@ -19,7 +19,7 @@
#include "Poco/KeyValueArgs.h"
#include "Poco/ValidArgs.h"
#include "Poco/ValidArgs.h"
#include "Poco/Mutex.h"
#include "Poco/Exception.h"
#include "Poco/FIFOEvent.h"
@@ -34,9 +34,9 @@
namespace Poco {
template <class TKey, class TValue, class TStrategy, class TMutex = FastMutex, class TEventMutex = FastMutex>
template <class TKey, class TValue, class TStrategy, class TMutex = FastMutex, class TEventMutex = FastMutex>
class AbstractCache
/// An AbstractCache is the interface of all caches.
/// An AbstractCache is the interface of all caches.
{
public:
FIFOEvent<const KeyValueArgs<TKey, TValue>, TEventMutex> Add;
@@ -83,7 +83,7 @@ public:
void update(const TKey& key, const TValue& val)
/// Adds the key value pair to the cache. Note that adding a NULL SharedPtr will fail!
/// If for the key already an entry exists, it will be overwritten.
/// The difference to add is that no remove or add events are thrown in this case,
/// The difference to add is that no remove or add events are thrown in this case,
/// just a simply silent update is performed
/// If the key does not exist the behavior is equal to add, ie. an add event is thrown
{
@@ -103,7 +103,7 @@ public:
void update(const TKey& key, SharedPtr<TValue > val)
/// Adds the key value pair to the cache. Note that adding a NULL SharedPtr will fail!
/// If for the key already an entry exists, it will be overwritten.
/// The difference to add is that no remove or add events are thrown in this case,
/// The difference to add is that no remove or add events are thrown in this case,
/// just an Update is thrown
/// If the key does not exist the behavior is equal to add, ie. an add event is thrown
{
@@ -231,7 +231,7 @@ protected:
KeyValueArgs<TKey, TValue> args(key, val);
Add.notify(this, args);
_data.insert(std::make_pair(key, SharedPtr<TValue>(new TValue(val))));
doReplace();
}
@@ -245,7 +245,7 @@ protected:
KeyValueArgs<TKey, TValue> args(key, *val);
Add.notify(this, args);
_data.insert(std::make_pair(key, val));
doReplace();
}
@@ -265,7 +265,7 @@ protected:
Update.notify(this, args);
it->second = SharedPtr<TValue>(new TValue(val));
}
doReplace();
}
@@ -285,11 +285,11 @@ protected:
Update.notify(this, args);
it->second = val;
}
doReplace();
}
void doRemove(Iterator it)
void doRemove(Iterator it)
/// Removes an entry from the cache. If the entry is not found
/// the remove is ignored.
{
@@ -317,7 +317,7 @@ protected:
return result;
}
SharedPtr<TValue> doGet(const TKey& key)
SharedPtr<TValue> doGet(const TKey& key)
/// Returns a SharedPtr of the cache entry, returns 0 if for
/// the key no value was found
{
@@ -325,7 +325,7 @@ protected:
SharedPtr<TValue> result;
if (it != _data.end())
{
{
// inform all strategies that a read-access to an element happens
Get.notify(this, key);
// ask all strategies if the key is valid