Page Speed Optimization Libraries
1.5.27.2
|
Captures a delayed call to a 2-arg member function as a closure. More...
#include "function.h"
Public Types | |
typedef void(C::* | Func )(T1, T2) |
Public Member Functions | |
MemberFunction2 (Func f, C *c, T1 v1, T2 v2) | |
Constructor suppying a Run method, but no Cancel method. | |
MemberFunction2 (Func f, Func cancel, C *c, T1 v1, T2 v2) | |
Constructor suppying a Run method and a Cancel method. | |
Protected Member Functions | |
virtual void | Run () |
virtual void | Cancel () |
Captures a delayed call to a 2-arg member function as a closure.
virtual void net_instaweb::MemberFunction2< C, T1, T2 >::Cancel | ( | ) | [inline, protected, virtual] |
Informs a the Function that it is being shut down. If this is called, Run() should not be called. This should never be called while a function is running. See also set_quit_requested(), which can be called during Run(), so that Run() implementations can check quit_requested() at their convenience to stop the operation in progress.
Reimplemented from net_instaweb::Function.
virtual void net_instaweb::MemberFunction2< C, T1, T2 >::Run | ( | ) | [inline, protected, virtual] |
Callers must override this to define the action to take when a closure is run. If this is called, Cancel() should not be called. This is a convention that's expected of callers of Function objects, but is not enforced by the Function implementation.
Implements net_instaweb::Function.