Notify_Constraint_Interpreter.cpp

Go to the documentation of this file.
00001 // $Id: Notify_Constraint_Interpreter.cpp 81621 2008-05-06 12:51:22Z parsons $
00002 
00003 #include "orbsvcs/Notify/Notify_Constraint_Interpreter.h"
00004 #include "orbsvcs/Notify/Notify_Constraint_Visitors.h"
00005 
00006 ACE_RCSID (Notify,
00007            NS_Constraint_Interpreter,
00008            "$Id: Notify_Constraint_Interpreter.cpp 81621 2008-05-06 12:51:22Z parsons $")
00009 
00010 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00011 
00012 TAO_Notify_Constraint_Interpreter::TAO_Notify_Constraint_Interpreter (void)
00013 {
00014 }
00015 
00016 TAO_Notify_Constraint_Interpreter::~TAO_Notify_Constraint_Interpreter (void)
00017 {
00018 }
00019 
00020 void
00021 TAO_Notify_Constraint_Interpreter::build_tree (
00022     const char *constraints
00023   )
00024 {
00025   if (ETCL_Interpreter::is_empty_string (constraints))
00026     {
00027       // Root is deleted in the TAO_Interpreter's destructor.
00028       ACE_NEW_THROW_EX (this->root_,
00029                         ETCL_Literal_Constraint (true),
00030                         CORBA::NO_MEMORY ());
00031     }
00032   else
00033     {
00034       // root_ is set in this base class call.
00035       if (ETCL_Interpreter::build_tree (constraints) != 0)
00036         {
00037           throw CosNotifyFilter::InvalidConstraint ();
00038         }
00039     }
00040 }
00041 
00042 CORBA::Boolean
00043 TAO_Notify_Constraint_Interpreter::evaluate (TAO_Notify_Constraint_Visitor &evaluator)
00044 {
00045   return evaluator.evaluate_constraint (this->root_);
00046 }
00047 
00048 TAO_END_VERSIONED_NAMESPACE_DECL

Generated on Tue Feb 2 17:45:29 2010 for TAO_CosNotification by  doxygen 1.4.7