prop_or.cpp
Go to the documentation of this file.
00001 
00025 #include <predicate_manager/prop_or.h>
00026 
00027 
00028 
00029 using namespace predicate_manager;
00030 using namespace std;
00031 
00032 
00033 
00034 bool
00035 Or::
00036 evaluate ( boost::function<bool ( NameID ) > f ) const
00037 {
00038     foreach ( children_type::value_type c, children_ )
00039     {
00040         if ( c->evaluate ( f ) == true )
00041         {
00042             return true;
00043         }
00044     }
00045 
00046     return false;
00047 }
00048 
00049 
00050 
00051 boost::shared_ptr<PropLogic>
00052 Or::
00053 clone() const
00054 {
00055     boost::shared_ptr<Or> p ( new Or ( *this ) );
00056     return ( boost::dynamic_pointer_cast<PropLogic> ( p ) );
00057 }


predicate_manager
Author(s): Joao Reis and Joao Messias
autogenerated on Wed Aug 26 2015 12:28:34