All Classes Namespaces Functions Variables Typedefs Enumerations
xmlflateval.h
1 #ifndef _MBXMLUTILS_XMLFLATEVAL_H_
2 #define _MBXMLUTILS_XMLFLATEVAL_H_
3 
4 #include "eval.h"
5 
6 namespace MBXMLUtils {
7 
12 class XMLFlatEval : public Eval {
13  friend class Eval;
14  protected:
15  XMLFlatEval(std::vector<boost::filesystem::path> *dependencies_=NULL);
16  public:
17  ~XMLFlatEval();
18  static std::string getNameStatic() { return "xmlflat"; }
19  virtual std::string getName() const { return getNameStatic(); }
20  virtual void addImport(const std::string &code, const xercesc::DOMElement *e);
21  virtual bool valueIsOfType(const Value &value, ValueType type) const;
22  virtual std::map<boost::filesystem::path, std::pair<boost::filesystem::path, bool> >& requiredFiles() const;
23  virtual void convertIndex(Value &v, bool evalTo1Based) {}
24  protected:
25  virtual Value createSwigByTypeName(const std::string &typeName) const;
26  virtual Value callFunction(const std::string &name, const std::vector<Value>& args) const;
27  virtual Value fullStringToValue(const std::string &str, const xercesc::DOMElement *e=NULL) const;
28  virtual void* getSwigThis(const Value &value) const;
29  virtual std::string getSwigType(const Value &value) const;
30  private:
31  virtual double cast_double (const Value &value) const;
32  virtual std::vector<double> cast_vector_double (const Value &value) const;
33  virtual std::vector<std::vector<double> >cast_vector_vector_double (const Value &value) const;
34  virtual std::string cast_string (const Value &value) const;
35  virtual Value create_double (const double& v) const;
36  virtual Value create_vector_double (const std::vector<double>& v) const;
37  virtual Value create_vector_vector_double(const std::vector<std::vector<double> >& v) const;
38  virtual Value create_string (const std::string& v) const;
39 };
40 
41 } // end namespace MBXMLUtils
42 
43 #endif
Definition: eval.h:76
virtual void convertIndex(Value &v, bool evalTo1Based)
Definition: xmlflateval.h:23
virtual std::map< boost::filesystem::path, std::pair< boost::filesystem::path, bool > > & requiredFiles() const
return a list of all required files of the evaluator (excluding dependent files of libraries) ...
Definition: xmlflateval.cc:45
virtual std::string getSwigType(const Value &value) const
get the SWIG type (class name) of this value.
Definition: xmlflateval.cc:66
virtual void addImport(const std::string &code, const xercesc::DOMElement *e)
Definition: xmlflateval.cc:30
virtual Value callFunction(const std::string &name, const std::vector< Value > &args) const
Definition: xmlflateval.cc:54
virtual Value createSwigByTypeName(const std::string &typeName) const
create a SWIG object of name typeName.
Definition: xmlflateval.cc:50
virtual Value fullStringToValue(const std::string &str, const xercesc::DOMElement *e=NULL) const
evaluate the string str using the current parameters and return the result.
Definition: xmlflateval.cc:58
Definition: xmlflateval.h:12
virtual std::string getName() const
Get the type of this evaluator.
Definition: xmlflateval.h:19
virtual bool valueIsOfType(const Value &value, ValueType type) const
Definition: xmlflateval.cc:34
virtual void * getSwigThis(const Value &value) const
get the SWIG pointer of this value.
Definition: xmlflateval.cc:62
ValueType
Definition: eval.h:82

Impressum / Disclaimer / Datenschutz Generated by doxygen 1.8.5 Valid HTML