From 6dd331262aa8f989657891e27b8891ee6a00016c Mon Sep 17 00:00:00 2001 From: danieldg Date: Wed, 13 May 2009 05:27:39 +0000 Subject: Create subclass of User for FakeClient, to allow for use as command source git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11375 e03df62e-2008-0410-955e-edbf42e46eb7 --- include/fakeuser.h | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 include/fakeuser.h (limited to 'include/fakeuser.h') diff --git a/include/fakeuser.h b/include/fakeuser.h new file mode 100644 index 000000000..5d62b7060 --- /dev/null +++ b/include/fakeuser.h @@ -0,0 +1,31 @@ +/* +------------------------------------+ + * | Inspire Internet Relay Chat Daemon | + * +------------------------------------+ + * + * InspIRCd: (C) 2002-2009 InspIRCd Development Team + * See: http://wiki.inspircd.org/Credits + * + * This program is free but copyrighted software; see + * the file COPYING for details. + * + * --------------------------------------------------- + */ + +#ifndef __FAKEUSER_H__ +#define __FAKEUSER_H__ + +#include "users.h" + +class CoreExport FakeUser : public User +{ + public: + FakeUser(InspIRCd* Instance) : User(Instance, "!") + { + SetFd(FD_MAGIC_NUMBER); + } + + virtual const std::string GetFullHost() { return server; } + virtual const std::string GetFullRealHost() { return server; } +}; + +#endif -- cgit v1.2.3