blob: 2aec6a518ba89168c44d39659308dacf96feea1f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
#include "orbsvcs/Log/Log_Constraint_Interpreter.h"
#include "orbsvcs/Log/Log_Constraint_Visitors.h"
TAO_BEGIN_VERSIONED_NAMESPACE_DECL
TAO_Log_Constraint_Interpreter::TAO_Log_Constraint_Interpreter (
const char *constraints
)
{
if (ETCL_Interpreter::is_empty_string (constraints))
{
// Root is deleted in the TAO_Interpreter's destructor.
ACE_NEW_THROW_EX (this->root_,
ETCL_Literal_Constraint (true),
CORBA::NO_MEMORY ());
}
else
{
// root_ is set in this base class call.
if (ETCL_Interpreter::build_tree (constraints) != 0)
{
throw DsLogAdmin::InvalidConstraint ();
}
}
}
TAO_Log_Constraint_Interpreter::~TAO_Log_Constraint_Interpreter ()
{
}
CORBA::Boolean
TAO_Log_Constraint_Interpreter::evaluate (
TAO_Log_Constraint_Visitor &evaluator
)
{
CORBA::Boolean retval =
evaluator.evaluate_constraint (this->root_);
return retval;
}
TAO_END_VERSIONED_NAMESPACE_DECL
|