From bb3475e8eb379ee18f3d8f37caa8040b852a6213 Mon Sep 17 00:00:00 2001 From: "Anna (navi) Figueiredo Gomes" Date: Sat, 23 Mar 2024 01:21:46 +0100 Subject: all: rename redis -> redict symbols and comments Signed-off-by: Anna (navi) Figueiredo Gomes --- adapters/qt.h | 64 +++++++++++++++++++++++++++++------------------------------ 1 file changed, 32 insertions(+), 32 deletions(-) (limited to 'adapters/qt.h') diff --git a/adapters/qt.h b/adapters/qt.h index a75cf31..de8d191 100644 --- a/adapters/qt.h +++ b/adapters/qt.h @@ -9,73 +9,73 @@ * */ -#ifndef __HIREDIS_QT_H__ -#define __HIREDIS_QT_H__ +#ifndef __HIREDICT_QT_H__ +#define __HIREDICT_QT_H__ #include #include "../async.h" -static void RedisQtAddRead(void *); -static void RedisQtDelRead(void *); -static void RedisQtAddWrite(void *); -static void RedisQtDelWrite(void *); -static void RedisQtCleanup(void *); +static void RedictQtAddRead(void *); +static void RedictQtDelRead(void *); +static void RedictQtAddWrite(void *); +static void RedictQtDelWrite(void *); +static void RedictQtCleanup(void *); -class RedisQtAdapter : public QObject { +class RedictQtAdapter : public QObject { Q_OBJECT friend - void RedisQtAddRead(void * adapter) { - RedisQtAdapter * a = static_cast(adapter); + void RedictQtAddRead(void * adapter) { + RedictQtAdapter * a = static_cast(adapter); a->addRead(); } friend - void RedisQtDelRead(void * adapter) { - RedisQtAdapter * a = static_cast(adapter); + void RedictQtDelRead(void * adapter) { + RedictQtAdapter * a = static_cast(adapter); a->delRead(); } friend - void RedisQtAddWrite(void * adapter) { - RedisQtAdapter * a = static_cast(adapter); + void RedictQtAddWrite(void * adapter) { + RedictQtAdapter * a = static_cast(adapter); a->addWrite(); } friend - void RedisQtDelWrite(void * adapter) { - RedisQtAdapter * a = static_cast(adapter); + void RedictQtDelWrite(void * adapter) { + RedictQtAdapter * a = static_cast(adapter); a->delWrite(); } friend - void RedisQtCleanup(void * adapter) { - RedisQtAdapter * a = static_cast(adapter); + void RedictQtCleanup(void * adapter) { + RedictQtAdapter * a = static_cast(adapter); a->cleanup(); } public: - RedisQtAdapter(QObject * parent = 0) + RedictQtAdapter(QObject * parent = 0) : QObject(parent), m_ctx(0), m_read(0), m_write(0) { } - ~RedisQtAdapter() { + ~RedictQtAdapter() { if (m_ctx != 0) { m_ctx->ev.data = NULL; } } - int setContext(redisAsyncContext * ac) { + int setContext(redictAsyncContext * ac) { if (ac->ev.data != NULL) { - return REDIS_ERR; + return REDICT_ERR; } m_ctx = ac; m_ctx->ev.data = this; - m_ctx->ev.addRead = RedisQtAddRead; - m_ctx->ev.delRead = RedisQtDelRead; - m_ctx->ev.addWrite = RedisQtAddWrite; - m_ctx->ev.delWrite = RedisQtDelWrite; - m_ctx->ev.cleanup = RedisQtCleanup; - return REDIS_OK; + m_ctx->ev.addRead = RedictQtAddRead; + m_ctx->ev.delRead = RedictQtDelRead; + m_ctx->ev.addWrite = RedictQtAddWrite; + m_ctx->ev.delWrite = RedictQtDelWrite; + m_ctx->ev.cleanup = RedictQtCleanup; + return REDICT_OK; } private: @@ -109,13 +109,13 @@ class RedisQtAdapter : public QObject { } private slots: - void read() { redisAsyncHandleRead(m_ctx); } - void write() { redisAsyncHandleWrite(m_ctx); } + void read() { redictAsyncHandleRead(m_ctx); } + void write() { redictAsyncHandleWrite(m_ctx); } private: - redisAsyncContext * m_ctx; + redictAsyncContext * m_ctx; QSocketNotifier * m_read; QSocketNotifier * m_write; }; -#endif /* !__HIREDIS_QT_H__ */ +#endif /* !__HIREDICT_QT_H__ */ -- cgit v1.2.3