classad_functional_tester.h

00001 /***************************************************************
00002  *
00003  * Copyright (C) 1990-2007, Condor Team, Computer Sciences Department,
00004  * University of Wisconsin-Madison, WI.
00005  * 
00006  * Licensed under the Apache License, Version 2.0 (the "License"); you
00007  * may not use this file except in compliance with the License.  You may
00008  * obtain a copy of the License at
00009  * 
00010  *    http://www.apache.org/licenses/LICENSE-2.0
00011  * 
00012  * Unless required by applicable law or agreed to in writing, software
00013  * distributed under the License is distributed on an "AS IS" BASIS,
00014  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00015  * See the License for the specific language governing permissions and
00016  * limitations under the License.
00017  *
00018  ***************************************************************/
00019 
00020 
00021 #include <map>
00022 #include "classad/classad_distribution.h"
00023 
00024 #ifdef WANT_CLASSAD_NAMESPACE
00025 using namespace classad;
00026 #endif
00027 
00028 class Variable
00029 {
00030 public:
00031     // When you give a Variable an ExprTree, it owns it. You don't. 
00032     Variable(std::string &name, ExprTree *tree);
00033     Variable(std::string &name, Value &value);
00034     ~Variable();
00035 
00036     void GetStringRepresentation(std::string &representation);
00037 
00038 private:
00039     std::string   _name;
00040     bool          _is_tree; // If false, then is value
00041     ExprTree      *_tree;
00042     Value         _value;
00043 };
00044 
 All Classes Functions Variables Typedefs Enumerations Enumerator Friends