Anope IRC Services  Version 2.0
Public Member Functions | Data Fields | Private Member Functions
MyRedisService Class Reference
Inheritance diagram for MyRedisService:
Inheritance graph
[legend]
Collaboration diagram for MyRedisService:
Collaboration graph
[legend]

Public Member Functions

 MyRedisService (Module *c, const Anope::string &n, const Anope::string &h, int p, unsigned d)
 
 ~MyRedisService ()
 
void SendCommand (RedisSocket *s, Interface *i, const std::vector< Anope::string > &cmds)
 
void SendCommand (RedisSocket *s, Interface *i, const Anope::string &str)
 
void Send (Interface *i, const std::vector< std::pair< const char *, size_t > > &args)
 
void SendCommand (Interface *i, const std::vector< Anope::string > &cmds) anope_override
 
void SendCommand (Interface *i, const Anope::string &str) anope_override
 
bool BlockAndProcess () anope_override
 
void Subscribe (Interface *i, const Anope::string &pattern) anope_override
 
void Unsubscribe (const Anope::string &pattern) anope_override
 
void StartTransaction () anope_override
 
void CommitTransaction () anope_override
 
- Public Member Functions inherited from Redis::Provider
 Provider (Module *c, const Anope::string &n)
 
- Public Member Functions inherited from Service
 Service (Module *o, const Anope::string &t, const Anope::string &n)
 
virtual ~Service ()
 
void Register ()
 
void Unregister ()
 
- Public Member Functions inherited from Base
 Base ()
 
virtual ~Base ()
 
void AddReference (ReferenceBase *r)
 
void DelReference (ReferenceBase *r)
 

Data Fields

Anope::string host
 
int port
 
unsigned db
 
RedisSocketsock
 
RedisSocketsub
 
Transaction ti
 
bool in_transaction
 
- Data Fields inherited from Service
Moduleowner
 
Anope::string type
 
Anope::string name
 

Private Member Functions

void Pack (std::vector< char > &buffer, const char *buf, size_t sz=0)
 
void Send (RedisSocket *s, Interface *i, const std::vector< std::pair< const char *, size_t > > &args)
 

Additional Inherited Members

- Static Public Member Functions inherited from Service
static ServiceFindService (const Anope::string &t, const Anope::string &n)
 
static std::vector< Anope::stringGetServiceKeys (const Anope::string &t)
 
static void AddAlias (const Anope::string &t, const Anope::string &n, const Anope::string &v)
 
static void DelAlias (const Anope::string &t, const Anope::string &n)
 

Detailed Description

Definition at line 80 of file m_redis.cpp.

Constructor & Destructor Documentation

MyRedisService::MyRedisService ( Module c,
const Anope::string n,
const Anope::string h,
int  p,
unsigned  d 
)
inline
MyRedisService::~MyRedisService ( )
inline

Definition at line 102 of file m_redis.cpp.

References Socket::flags, RedisSocket::provider, and SF_DEAD.

Member Function Documentation

bool MyRedisService::BlockAndProcess ( )
inlinevirtual
void MyRedisService::CommitTransaction ( )
inlinevirtual

Implements Redis::Provider.

Definition at line 244 of file m_redis.cpp.

void MyRedisService::Pack ( std::vector< char > &  buffer,
const char *  buf,
size_t  sz = 0 
)
inlineprivate

Definition at line 118 of file m_redis.cpp.

void MyRedisService::Send ( RedisSocket s,
Interface i,
const std::vector< std::pair< const char *, size_t > > &  args 
)
inlineprivate
void MyRedisService::Send ( Interface i,
const std::vector< std::pair< const char *, size_t > > &  args 
)
inline
void MyRedisService::SendCommand ( RedisSocket s,
Interface i,
const std::vector< Anope::string > &  cmds 
)
inline

Definition at line 162 of file m_redis.cpp.

References Mail::Send().

Referenced by RedisSocket::OnConnect().

void MyRedisService::SendCommand ( RedisSocket s,
Interface i,
const Anope::string str 
)
inline

Definition at line 170 of file m_redis.cpp.

References sepstream::GetTokens().

void MyRedisService::SendCommand ( Interface i,
const std::vector< Anope::string > &  cmds 
)
inlinevirtual

Implements Redis::Provider.

Definition at line 188 of file m_redis.cpp.

References Mail::Send().

void MyRedisService::SendCommand ( Interface i,
const Anope::string str 
)
inlinevirtual

Implements Redis::Provider.

Definition at line 196 of file m_redis.cpp.

References sepstream::GetTokens().

void MyRedisService::StartTransaction ( )
inlinevirtual

Implements Redis::Provider.

Definition at line 235 of file m_redis.cpp.

void MyRedisService::Subscribe ( Interface i,
const Anope::string pattern 
)
inlinevirtual
void MyRedisService::Unsubscribe ( const Anope::string pattern)
inlinevirtual

Implements Redis::Provider.

Definition at line 229 of file m_redis.cpp.

References RedisSocket::subinterfaces.

Field Documentation

unsigned MyRedisService::db

Definition at line 85 of file m_redis.cpp.

Referenced by RedisSocket::OnConnect().

Anope::string MyRedisService::host

Definition at line 83 of file m_redis.cpp.

bool MyRedisService::in_transaction

Definition at line 90 of file m_redis.cpp.

int MyRedisService::port

Definition at line 84 of file m_redis.cpp.

RedisSocket* MyRedisService::sock
RedisSocket * MyRedisService::sub
Transaction MyRedisService::ti

Definition at line 89 of file m_redis.cpp.

Referenced by ModuleRedis::OnModuleUnload().


The documentation for this class was generated from the following file: