#include <vv2.h>
Public Methods | |
void | visit (ArgBase &ob) |
Performs the VirtualVisitor's action on the given object. | |
void | visit (ArgBase &ob) |
Performs the VirtualVisitor's action on the given object. | |
Protected Types | |
typedef P | Parent |
The parent of this SV. | |
typedef Parent::ArgBase | ArgBase |
The base class of the argument. | |
typedef S | ArgSub |
The subclass that the argument may or may not be. | |
typedef P | Parent |
The parent of this SV. | |
typedef S | ArgSub |
The subclass that the argument may or may not be. | |
typedef Parent::ArgBase | ArgBase |
The base class of ArgSub. | |
Protected Methods | |
void | try_visit (ArgBase &ob) |
If ob can be cast to ArgSub, call do_visit, otherwise try the parent. | |
virtual void | do_visit (ArgSub &ob)=0 |
Do the action on objects of type SubType. | |
void | try_visit (ArgBase &ob) |
If ob can be cast to ArgSub, call do_visit, otherwise try this SV's parent. | |
virtual void | do_visit (ArgSub &ob)=0 |
Add the requirement to define do_visit(ArgSub &). |
Supplies an implementation of try_visit() and visit(), and adds the requirement to provide a do_visit<S>() in subclasses
S | The subclass of ArgBase to perform operations on |
P | The parent class (either another SV or a Visitor) |
|
The parent of this SV.
|
|
The base class of the argument.
|
|
The subclass that the argument may or may not be.
|
|
The parent of this SV.
|
|
The subclass that the argument may or may not be.
|
|
The base class of ArgSub.
|
|
If ob can be cast to ArgSub, call do_visit, otherwise try the parent.
|
|
Do the action on objects of type SubType.
|
|
Performs the VirtualVisitor's action on the given object.
00097 { 00098 try_visit(ob); 00099 } |
|
If ob can be cast to ArgSub, call do_visit, otherwise try this SV's parent.
|
|
Add the requirement to define do_visit(ArgSub &).
|
|
Performs the VirtualVisitor's action on the given object.
00098 { 00099 try_visit(ob); 00100 } |