2006-11-27から1日間の記事一覧

command さらにもういっちょ

I am copying this example from the other example I posted a day or two ago. Requirements are very simliliar... template <class T> class Method { public: typedef int (T::* MemFunPtr)(char* []); Method(MemFunPtr pMethod) : mpMethod(pMethod) { } int I</class>…

command もういっちょ

How about using a template? Something similar to the mem_fun() adapter. // Totally untested code follows template <class T> MemFunCommand : public Command { T* mpHost; void (T::* mpMemFun)(); public: explicit MemFunCommand(T* pHost, void (T::* pMem</class>…

command

Yes, it's possible, use map<string, boost::function<void()> >. void quit(); struct X { void set_visible(bool visible); }; X x; std::map< std::string, boost::function<void()> > commands; int main() { commands["quit"] = &quit; commands["show"] = boost::bind(&X::set_visible, &x, tr</void()></string,>…

upgrade today ;)

[ebuild U ] sys-devel/autoconf-wrapper-4-r3 [4-r2] 0 kB [ebuild U ] sys-devel/m4-1.4.8 [1.4.7] USE="-nls" 567 kB [ebuild U ] sys-devel/binutils-config-1.9-r3 [1.9-r2] 0 kB [ebuild U ] sys-apps/pciutils-2.2.3-r2 [2.2.3-r1] 1,096 kB [ebuild …

札幌 3 - 2 柏

逆転勝利!すなおに喜ぼう!