From 60a9969b9471dec190d5526b79cb731ea2e1b751 Mon Sep 17 00:00:00 2001 From: brain Date: Wed, 7 Apr 2004 18:21:29 +0000 Subject: Added new documentation git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@424 e03df62e-2008-0410-955e-edbf42e46eb7 --- docs/module-doc/modules_8cpp-source.html | 756 ++++++++++++++++--------------- 1 file changed, 393 insertions(+), 363 deletions(-) (limited to 'docs/module-doc/modules_8cpp-source.html') diff --git a/docs/module-doc/modules_8cpp-source.html b/docs/module-doc/modules_8cpp-source.html index a6398c94a..38b2bb45b 100644 --- a/docs/module-doc/modules_8cpp-source.html +++ b/docs/module-doc/modules_8cpp-source.html @@ -19,376 +19,406 @@ 00011 #include "modules.h" 00012 #include "ctables.h" 00013 #include "inspircd_io.h" -00014 -00015 // class type for holding an extended mode character - internal to core -00016 -00017 class ExtMode -00018 { -00019 public: -00020 char modechar; -00021 int type; -00022 int params_when_on; -00023 int params_when_off; -00024 bool needsoper; -00025 ExtMode(char mc, int ty, bool oper, int p_on, int p_off) : modechar(mc), type(ty), needsoper(oper), params_when_on(p_on), params_when_off(p_off) { }; -00026 }; -00027 -00028 typedef std::vector<ExtMode> ExtModeList; -00029 typedef ExtModeList::iterator ExtModeListIter; -00030 -00031 ExtModeList EMode; -00032 -00033 // returns true if an extended mode character is in use -00034 bool ModeDefined(char modechar, int type) -00035 { -00036 log(DEBUG,"Size of extmodes vector is %d",EMode.size()); -00037 for (ExtModeListIter i = EMode.begin(); i < EMode.end(); i++) -00038 { -00039 log(DEBUG,"i->modechar==%c, modechar=%c, i->type=%d, type=%d",i->modechar,modechar,i->type,type); -00040 if ((i->modechar == modechar) && (i->type == type)) -00041 { -00042 return true; -00043 } -00044 } -00045 return false; -00046 } -00047 -00048 bool ModeDefinedOper(char modechar, int type) -00049 { -00050 log(DEBUG,"Size of extmodes vector is %d",EMode.size()); -00051 for (ExtModeListIter i = EMode.begin(); i < EMode.end(); i++) -00052 { -00053 log(DEBUG,"i->modechar==%c, modechar=%c, i->type=%d, type=%d",i->modechar,modechar,i->type,type); -00054 if ((i->modechar == modechar) && (i->type == type) && (i->needsoper == true)) -00055 { -00056 return true; -00057 } -00058 } -00059 return false; -00060 } -00061 -00062 // returns number of parameters for a custom mode when it is switched on -00063 int ModeDefinedOn(char modechar, int type) -00064 { -00065 for (ExtModeListIter i = EMode.begin(); i < EMode.end(); i++) -00066 { -00067 if ((i->modechar == modechar) && (i->type == type)) -00068 { -00069 return i->params_when_on; -00070 } -00071 } -00072 return 0; -00073 } -00074 -00075 // returns number of parameters for a custom mode when it is switched on -00076 int ModeDefinedOff(char modechar, int type) -00077 { -00078 for (ExtModeListIter i = EMode.begin(); i < EMode.end(); i++) -00079 { -00080 if ((i->modechar == modechar) && (i->type == type)) -00081 { -00082 return i->params_when_off; -00083 } -00084 } -00085 return 0; -00086 } -00087 -00088 // returns true if an extended mode character is in use -00089 bool DoAddExtendedMode(char modechar, int type, bool requires_oper, int params_on, int params_off) -00090 { -00091 if (ModeDefined(modechar,type)) { -00092 return false; -00093 } -00094 EMode.push_back(ExtMode(modechar,type,requires_oper,params_on,params_off)); -00095 return true; -00096 } -00097 +00014 #include "wildcard.h" +00015 +00016 // class type for holding an extended mode character - internal to core +00017 +00018 class ExtMode +00019 { +00020 public: +00021 char modechar; +00022 int type; +00023 int params_when_on; +00024 int params_when_off; +00025 bool needsoper; +00026 ExtMode(char mc, int ty, bool oper, int p_on, int p_off) : modechar(mc), type(ty), needsoper(oper), params_when_on(p_on), params_when_off(p_off) { }; +00027 }; +00028 +00029 typedef std::vector<ExtMode> ExtModeList; +00030 typedef ExtModeList::iterator ExtModeListIter; +00031 +00032 ExtModeList EMode; +00033 +00034 // returns true if an extended mode character is in use +00035 bool ModeDefined(char modechar, int type) +00036 { +00037 log(DEBUG,"Size of extmodes vector is %d",EMode.size()); +00038 for (ExtModeListIter i = EMode.begin(); i < EMode.end(); i++) +00039 { +00040 log(DEBUG,"i->modechar==%c, modechar=%c, i->type=%d, type=%d",i->modechar,modechar,i->type,type); +00041 if ((i->modechar == modechar) && (i->type == type)) +00042 { +00043 return true; +00044 } +00045 } +00046 return false; +00047 } +00048 +00049 bool ModeDefinedOper(char modechar, int type) +00050 { +00051 log(DEBUG,"Size of extmodes vector is %d",EMode.size()); +00052 for (ExtModeListIter i = EMode.begin(); i < EMode.end(); i++) +00053 { +00054 log(DEBUG,"i->modechar==%c, modechar=%c, i->type=%d, type=%d",i->modechar,modechar,i->type,type); +00055 if ((i->modechar == modechar) && (i->type == type) && (i->needsoper == true)) +00056 { +00057 return true; +00058 } +00059 } +00060 return false; +00061 } +00062 +00063 // returns number of parameters for a custom mode when it is switched on +00064 int ModeDefinedOn(char modechar, int type) +00065 { +00066 for (ExtModeListIter i = EMode.begin(); i < EMode.end(); i++) +00067 { +00068 if ((i->modechar == modechar) && (i->type == type)) +00069 { +00070 return i->params_when_on; +00071 } +00072 } +00073 return 0; +00074 } +00075 +00076 // returns number of parameters for a custom mode when it is switched on +00077 int ModeDefinedOff(char modechar, int type) +00078 { +00079 for (ExtModeListIter i = EMode.begin(); i < EMode.end(); i++) +00080 { +00081 if ((i->modechar == modechar) && (i->type == type)) +00082 { +00083 return i->params_when_off; +00084 } +00085 } +00086 return 0; +00087 } +00088 +00089 // returns true if an extended mode character is in use +00090 bool DoAddExtendedMode(char modechar, int type, bool requires_oper, int params_on, int params_off) +00091 { +00092 if (ModeDefined(modechar,type)) { +00093 return false; +00094 } +00095 EMode.push_back(ExtMode(modechar,type,requires_oper,params_on,params_off)); +00096 return true; +00097 } 00098 -00099 // version is a simple class for holding a modules version number -00100 -00101 Version::Version(int major, int minor, int revision, int build) : Major(major), Minor(minor), Revision(revision), Build(build) { }; -00102 -00103 // admin is a simple class for holding a server's administrative info -00104 -00105 Admin::Admin(std::string name, std::string email, std::string nick) : Name(name), Email(email), Nick(nick) { }; -00106 -00107 Module::Module() { } -00108 Module::~Module() { } -00109 void Module::OnUserConnect(userrec* user) { } -00110 void Module::OnUserQuit(userrec* user) { } -00111 void Module::OnUserJoin(userrec* user, chanrec* channel) { } -00112 void Module::OnUserPart(userrec* user, chanrec* channel) { } -00113 void Module::OnPacketTransmit(char *p) { } -00114 void Module::OnPacketReceive(char *p) { } -00115 void Module::OnRehash() { } -00116 void Module::OnServerRaw(std::string &raw, bool inbound) { } -00117 int Module::OnUserPreJoin(userrec* user, chanrec* chan, const char* cname) { return 0; } -00118 bool Module::OnExtendedMode(userrec* user, void* target, char modechar, int type, bool mode_on, string_list &params) { } -00119 Version Module::GetVersion() { return Version(1,0,0,0); } -00120 void Module::OnOper(userrec* user) { }; -00121 void Module::OnInfo(userrec* user) { }; -00122 void Module::OnWhois(userrec* source, userrec* dest) { }; -00123 int Module::OnUserPreMessage(userrec* user,void* dest,int target_type, std::string text) { return 0; }; -00124 int Module::OnUserPreNotice(userrec* user,void* dest,int target_type, std::string text) { return 0; }; -00125 -00126 // server is a wrapper class that provides methods to all of the C-style -00127 // exports in the core -00128 // -00129 -00130 Server::Server() -00131 { -00132 } -00133 -00134 Server::~Server() -00135 { -00136 } -00137 -00138 void Server::SendOpers(std::string s) -00139 { -00140 WriteOpers("%s",s.c_str()); -00141 } -00142 -00143 void Server::SendToModeMask(std::string modes, int flags, std::string text) -00144 { -00145 WriteMode(modes.c_str(),flags,"%s",text.c_str()); -00146 } -00147 -00148 chanrec* Server::JoinUserToChannel(userrec* user, std::string cname, std::string key) -00149 { -00150 return add_channel(user,cname.c_str(),key.c_str()); -00151 } -00152 -00153 chanrec* Server::PartUserFromChannel(userrec* user, std::string cname, std::string reason) -00154 { -00155 return del_channel(user,cname.c_str(),reason.c_str()); -00156 } -00157 -00158 void Server::ChangeUserNick(userrec* user, std::string nickname) -00159 { -00160 force_nickchange(user,nickname.c_str()); -00161 } -00162 -00163 void Server::QuitUser(userrec* user, std::string reason) -00164 { -00165 kill_link(user,reason.c_str()); -00166 } -00167 -00168 -00169 void Server::Log(int level, std::string s) -00170 { -00171 log(level,"%s",s.c_str()); -00172 } -00173 -00174 void Server::AddCommand(char* cmd, handlerfunc f, char flags, int minparams) -00175 { -00176 createcommand(cmd,f,flags,minparams); -00177 } -00178 -00179 void Server::SendMode(char **parameters, int pcnt, userrec *user) -00180 { -00181 server_mode(parameters,pcnt,user); -00182 } -00183 -00184 void Server::Send(int Socket, std::string s) -00185 { -00186 Write(Socket,"%s",s.c_str()); -00187 } -00188 -00189 void Server::SendServ(int Socket, std::string s) -00190 { -00191 WriteServ(Socket,"%s",s.c_str()); -00192 } -00193 -00194 void Server::SendFrom(int Socket, userrec* User, std::string s) -00195 { -00196 WriteFrom(Socket,User,"%s",s.c_str()); -00197 } -00198 -00199 void Server::SendTo(userrec* Source, userrec* Dest, std::string s) -00200 { -00201 WriteTo(Source,Dest,"%s",s.c_str()); -00202 } -00203 -00204 void Server::SendChannel(userrec* User, chanrec* Channel, std::string s,bool IncludeSender) -00205 { -00206 if (IncludeSender) -00207 { -00208 WriteChannel(Channel,User,"%s",s.c_str()); -00209 } -00210 else +00099 +00100 // version is a simple class for holding a modules version number +00101 +00102 Version::Version(int major, int minor, int revision, int build) : Major(major), Minor(minor), Revision(revision), Build(build) { }; +00103 +00104 // admin is a simple class for holding a server's administrative info +00105 +00106 Admin::Admin(std::string name, std::string email, std::string nick) : Name(name), Email(email), Nick(nick) { }; +00107 +00108 Module::Module() { } +00109 Module::~Module() { } +00110 void Module::OnUserConnect(userrec* user) { } +00111 void Module::OnUserQuit(userrec* user) { } +00112 void Module::OnUserJoin(userrec* user, chanrec* channel) { } +00113 void Module::OnUserPart(userrec* user, chanrec* channel) { } +00114 void Module::OnPacketTransmit(char *p) { } +00115 void Module::OnPacketReceive(char *p) { } +00116 void Module::OnRehash() { } +00117 void Module::OnServerRaw(std::string &raw, bool inbound) { } +00118 int Module::OnUserPreJoin(userrec* user, chanrec* chan, const char* cname) { return 0; } +00119 bool Module::OnExtendedMode(userrec* user, void* target, char modechar, int type, bool mode_on, string_list &params) { } +00120 Version Module::GetVersion() { return Version(1,0,0,0); } +00121 void Module::OnOper(userrec* user) { }; +00122 void Module::OnInfo(userrec* user) { }; +00123 void Module::OnWhois(userrec* source, userrec* dest) { }; +00124 int Module::OnUserPreMessage(userrec* user,void* dest,int target_type, std::string text) { return 0; }; +00125 int Module::OnUserPreNotice(userrec* user,void* dest,int target_type, std::string text) { return 0; }; +00126 +00127 // server is a wrapper class that provides methods to all of the C-style +00128 // exports in the core +00129 // +00130 +00131 Server::Server() +00132 { +00133 } +00134 +00135 Server::~Server() +00136 { +00137 } +00138 +00139 void Server::SendOpers(std::string s) +00140 { +00141 WriteOpers("%s",s.c_str()); +00142 } +00143 +00144 bool Server::MatchText(std::string sliteral, std::string spattern) +00145 { +00146 char literal[MAXBUF],pattern[MAXBUF]; +00147 strncpy(literal,sliteral.c_str(),MAXBUF); +00148 strncpy(pattern,spattern.c_str(),MAXBUF); +00149 return match(literal,pattern); +00150 } +00151 +00152 void Server::SendToModeMask(std::string modes, int flags, std::string text) +00153 { +00154 WriteMode(modes.c_str(),flags,"%s",text.c_str()); +00155 } +00156 +00157 chanrec* Server::JoinUserToChannel(userrec* user, std::string cname, std::string key) +00158 { +00159 return add_channel(user,cname.c_str(),key.c_str()); +00160 } +00161 +00162 chanrec* Server::PartUserFromChannel(userrec* user, std::string cname, std::string reason) +00163 { +00164 return del_channel(user,cname.c_str(),reason.c_str()); +00165 } +00166 +00167 void Server::ChangeUserNick(userrec* user, std::string nickname) +00168 { +00169 force_nickchange(user,nickname.c_str()); +00170 } +00171 +00172 void Server::QuitUser(userrec* user, std::string reason) +00173 { +00174 kill_link(user,reason.c_str()); +00175 } +00176 +00177 +00178 void Server::Log(int level, std::string s) +00179 { +00180 log(level,"%s",s.c_str()); +00181 } +00182 +00183 void Server::AddCommand(char* cmd, handlerfunc f, char flags, int minparams) +00184 { +00185 createcommand(cmd,f,flags,minparams); +00186 } +00187 +00188 void Server::SendMode(char **parameters, int pcnt, userrec *user) +00189 { +00190 server_mode(parameters,pcnt,user); +00191 } +00192 +00193 void Server::Send(int Socket, std::string s) +00194 { +00195 Write(Socket,"%s",s.c_str()); +00196 } +00197 +00198 void Server::SendServ(int Socket, std::string s) +00199 { +00200 WriteServ(Socket,"%s",s.c_str()); +00201 } +00202 +00203 void Server::SendFrom(int Socket, userrec* User, std::string s) +00204 { +00205 WriteFrom(Socket,User,"%s",s.c_str()); +00206 } +00207 +00208 void Server::SendTo(userrec* Source, userrec* Dest, std::string s) +00209 { +00210 if (!Source) 00211 { -00212 ChanExceptSender(Channel,User,"%s",s.c_str()); -00213 } -00214 } -00215 -00216 bool Server::CommonChannels(userrec* u1, userrec* u2) -00217 { -00218 return (common_channels(u1,u2) != 0); -00219 } -00220 -00221 void Server::SendCommon(userrec* User, std::string text,bool IncludeSender) -00222 { -00223 if (IncludeSender) -00224 { -00225 WriteCommon(User,"%s",text.c_str()); -00226 } -00227 else -00228 { -00229 WriteCommonExcept(User,"%s",text.c_str()); -00230 } -00231 } -00232 -00233 void Server::SendWallops(userrec* User, std::string text) -00234 { -00235 WriteWallOps(User,"%s",text.c_str()); -00236 } -00237 -00238 bool Server::IsNick(std::string nick) -00239 { -00240 return (isnick(nick.c_str()) != 0); -00241 } -00242 -00243 userrec* Server::FindNick(std::string nick) -00244 { -00245 return Find(nick); -00246 } -00247 -00248 chanrec* Server::FindChannel(std::string channel) -00249 { -00250 return FindChan(channel.c_str()); -00251 } -00252 -00253 std::string Server::ChanMode(userrec* User, chanrec* Chan) -00254 { -00255 return cmode(User,Chan); -00256 } -00257 -00258 std::string Server::GetServerName() -00259 { -00260 return getservername(); -00261 } -00262 -00263 std::string Server::GetNetworkName() -00264 { -00265 return getnetworkname(); -00266 } -00267 -00268 Admin Server::GetAdmin() -00269 { -00270 return Admin(getadminname(),getadminemail(),getadminnick()); -00271 } -00272 -00273 -00274 -00275 bool Server::AddExtendedMode(char modechar, int type, bool requires_oper, int params_when_on, int params_when_off) -00276 { -00277 if (type == MT_SERVER) -00278 { -00279 log(DEBUG,"*** API ERROR *** Modes of type MT_SERVER are reserved for future expansion"); -00280 return false; -00281 } -00282 if (((params_when_on>0) || (params_when_off>0)) && (type == MT_CLIENT)) -00283 { -00284 log(DEBUG,"*** API ERROR *** Parameters on MT_CLIENT modes are not supported"); -00285 return false; -00286 } -00287 if ((params_when_on>1) || (params_when_off>1)) -00288 { -00289 log(DEBUG,"*** API ERROR *** More than one parameter for an MT_CHANNEL mode is not yet supported"); -00290 return false; -00291 } -00292 return DoAddExtendedMode(modechar,type,requires_oper,params_when_on,params_when_off); -00293 } -00294 -00295 -00296 ConfigReader::ConfigReader() -00297 { -00298 fname = CONFIG_FILE; -00299 } -00300 -00301 -00302 ConfigReader::~ConfigReader() -00303 { -00304 } -00305 -00306 -00307 ConfigReader::ConfigReader(std::string filename) : fname(filename) { }; -00308 -00309 std::string ConfigReader::ReadValue(std::string tag, std::string name, int index) -00310 { -00311 char val[MAXBUF]; -00312 ReadConf(fname.c_str(),tag.c_str(),name.c_str(),index,val); -00313 return val; -00314 } -00315 -00316 -00317 int ConfigReader::Enumerate(std::string tag) -00318 { -00319 return EnumConf(fname.c_str(),tag.c_str()); -00320 } -00321 -00322 -00323 bool ConfigReader::Verify() -00324 { -00325 return true; -00326 } -00327 -00328 -00329 FileReader::FileReader(std::string filename) -00330 { -00331 file_cache c; -00332 readfile(c,filename.c_str()); -00333 this->fc = c; -00334 } -00335 -00336 FileReader::FileReader() -00337 { -00338 } -00339 -00340 void FileReader::LoadFile(std::string filename) -00341 { -00342 file_cache c; -00343 readfile(c,filename.c_str()); -00344 this->fc = c; -00345 } +00212 // if source is NULL, then the message originates from the local server +00213 Write(Dest->fd,":%s %s",this->GetServerName().c_str(),s.c_str()); +00214 } +00215 else +00216 { +00217 // otherwise it comes from the user specified +00218 WriteTo(Source,Dest,"%s",s.c_str()); +00219 } +00220 } +00221 +00222 void Server::SendChannel(userrec* User, chanrec* Channel, std::string s,bool IncludeSender) +00223 { +00224 if (IncludeSender) +00225 { +00226 WriteChannel(Channel,User,"%s",s.c_str()); +00227 } +00228 else +00229 { +00230 ChanExceptSender(Channel,User,"%s",s.c_str()); +00231 } +00232 } +00233 +00234 bool Server::CommonChannels(userrec* u1, userrec* u2) +00235 { +00236 return (common_channels(u1,u2) != 0); +00237 } +00238 +00239 void Server::SendCommon(userrec* User, std::string text,bool IncludeSender) +00240 { +00241 if (IncludeSender) +00242 { +00243 WriteCommon(User,"%s",text.c_str()); +00244 } +00245 else +00246 { +00247 WriteCommonExcept(User,"%s",text.c_str()); +00248 } +00249 } +00250 +00251 void Server::SendWallops(userrec* User, std::string text) +00252 { +00253 WriteWallOps(User,"%s",text.c_str()); +00254 } +00255 +00256 bool Server::IsNick(std::string nick) +00257 { +00258 return (isnick(nick.c_str()) != 0); +00259 } +00260 +00261 userrec* Server::FindNick(std::string nick) +00262 { +00263 return Find(nick); +00264 } +00265 +00266 chanrec* Server::FindChannel(std::string channel) +00267 { +00268 return FindChan(channel.c_str()); +00269 } +00270 +00271 std::string Server::ChanMode(userrec* User, chanrec* Chan) +00272 { +00273 return cmode(User,Chan); +00274 } +00275 +00276 std::string Server::GetServerName() +00277 { +00278 return getservername(); +00279 } +00280 +00281 std::string Server::GetNetworkName() +00282 { +00283 return getnetworkname(); +00284 } +00285 +00286 Admin Server::GetAdmin() +00287 { +00288 return Admin(getadminname(),getadminemail(),getadminnick()); +00289 } +00290 +00291 +00292 +00293 bool Server::AddExtendedMode(char modechar, int type, bool requires_oper, int params_when_on, int params_when_off) +00294 { +00295 if (type == MT_SERVER) +00296 { +00297 log(DEBUG,"*** API ERROR *** Modes of type MT_SERVER are reserved for future expansion"); +00298 return false; +00299 } +00300 if (((params_when_on>0) || (params_when_off>0)) && (type == MT_CLIENT)) +00301 { +00302 log(DEBUG,"*** API ERROR *** Parameters on MT_CLIENT modes are not supported"); +00303 return false; +00304 } +00305 if ((params_when_on>1) || (params_when_off>1)) +00306 { +00307 log(DEBUG,"*** API ERROR *** More than one parameter for an MT_CHANNEL mode is not yet supported"); +00308 return false; +00309 } +00310 return DoAddExtendedMode(modechar,type,requires_oper,params_when_on,params_when_off); +00311 } +00312 +00313 int Server::CountUsers(chanrec* c) +00314 { +00315 return usercount(c); +00316 } +00317 +00318 +00319 ConfigReader::ConfigReader() +00320 { +00321 this->cache = new std::stringstream(stringstream::in | stringstream::out); +00322 this->error = LoadConf(CONFIG_FILE,this->cache); +00323 } +00324 +00325 +00326 ConfigReader::~ConfigReader() +00327 { +00328 if (this->cache) +00329 delete this->cache; +00330 } +00331 +00332 +00333 ConfigReader::ConfigReader(std::string filename) +00334 { +00335 this->cache = new std::stringstream(stringstream::in | stringstream::out); +00336 this->error = LoadConf(filename.c_str(),this->cache); +00337 }; +00338 +00339 std::string ConfigReader::ReadValue(std::string tag, std::string name, int index) +00340 { +00341 char val[MAXBUF]; +00342 ReadConf(cache,tag.c_str(),name.c_str(),index,val); +00343 return val; +00344 } +00345 00346 -00347 -00348 FileReader::~FileReader() -00349 { +00347 int ConfigReader::Enumerate(std::string tag) +00348 { +00349 return EnumConf(cache,tag.c_str()); 00350 } 00351 -00352 bool FileReader::Exists() -00353 { -00354 if (fc.size() == 0) -00355 { -00356 return(false); -00357 } -00358 else -00359 { -00360 return(true); -00361 } -00362 } -00363 -00364 std::string FileReader::GetLine(int x) -00365 { -00366 if ((x<0) || (x>fc.size())) -00367 return ""; -00368 return fc[x]; -00369 } -00370 -00371 int FileReader::FileSize() -00372 { -00373 return fc.size(); -00374 } -00375 +00352 +00353 bool ConfigReader::Verify() +00354 { +00355 return this->error; +00356 } +00357 +00358 +00359 FileReader::FileReader(std::string filename) +00360 { +00361 file_cache c; +00362 readfile(c,filename.c_str()); +00363 this->fc = c; +00364 } +00365 +00366 FileReader::FileReader() +00367 { +00368 } +00369 +00370 void FileReader::LoadFile(std::string filename) +00371 { +00372 file_cache c; +00373 readfile(c,filename.c_str()); +00374 this->fc = c; +00375 } 00376 -00377 std::vector<Module*> modules(255); -00378 std::vector<ircd_module*> factory(255); -00379 -00380 int MODCOUNT = -1; +00377 +00378 FileReader::~FileReader() +00379 { +00380 } 00381 -00382 -
Generated on Tue Apr 6 21:13:19 2004 for InspIRCd by +00382 bool FileReader::Exists() +00383 { +00384 if (fc.size() == 0) +00385 { +00386 return(false); +00387 } +00388 else +00389 { +00390 return(true); +00391 } +00392 } +00393 +00394 std::string FileReader::GetLine(int x) +00395 { +00396 if ((x<0) || (x>fc.size())) +00397 return ""; +00398 return fc[x]; +00399 } +00400 +00401 int FileReader::FileSize() +00402 { +00403 return fc.size(); +00404 } +00405 +00406 +00407 std::vector<Module*> modules(255); +00408 std::vector<ircd_module*> factory(255); +00409 +00410 int MODCOUNT = -1; +00411 +00412 +
Generated on Wed Apr 7 19:20:14 2004 for InspIRCd by doxygen1.3-rc3
-- cgit v1.2.3