cgv
|
#include <action.h>
Public Member Functions | |
matched_method_action (T1 _v1, R1(X::*_on_begin)(T1), R2(X::*_on_end)(T1), bool _default_result_begin, bool _default_result_end) | |
construct from signature, method pointers and default result values | |
bool | begin () |
uses call_method of base class method_action to call the method refered to by the stored method pointer | |
bool | end () |
uses call_method of base class method_action to call the method refered to by the stored method pointer | |
void | set_signature (T1 _v1) |
set a new signature with which the methods of the traversed nodes are called | |
bool | call_method (void(X::*mp)(T1), bool default_result) |
call a void method given a default return value | |
bool | call_method (bool(X::*mp)(T1), bool default_result) |
call a bool method given a default return value | |
void | select (base_ptr p) |
implement the select method and store pointers of type X* and traverse_policy* | |
bool | implements_action () const |
simply return whether the stored pointer of type X* is not 0 | |
traverse_policy * | get_policy () const |
simply return the stored pointer of type traverse_policy* | |
void | set_default_results (bool _default_result) |
sets the value that is returned, whenever no result is obtained from the traversed methods | |
void | set_default_result_begin (bool _default_result_begin) |
sets the value that is returned for on_begin events | |
void | set_default_result_end (bool _default_result_end) |
sets the value that is returned for on_end events | |
virtual bool | has_begin_only () const |
check whether the action has registered a single begin method or both begin and end methods | |
complete implementation of method actions that call a begin and end method when entering and leaving a node