27 #include "../dataaccess/query/LiteralByteArray.h" 
   28 #include "../dataaccess/query/LiteralDateTime.h" 
   29 #include "../dataaccess/query/LiteralEnvelope.h" 
   30 #include "../dataaccess/query/LiteralGeom.h" 
   31 #include "../dataaccess/query/PropertyName.h" 
   32 #include "../dataaccess/query/ST_EnvelopeIntersects.h" 
   33 #include "../geometry/Envelope.h" 
   41 #include <boost/lexical_cast.hpp> 
   66   m_sql += 
" lower_x = " + boost::lexical_cast<std::string>(env->getLowerLeftX());
 
   67   m_sql += 
" upper_x = " + boost::lexical_cast<std::string>(env->getUpperRightX());
 
   68   m_sql += 
" lower_y = " + boost::lexical_cast<std::string>(env->getLowerLeftY());
 
   69   m_sql += 
" upper_y = " + boost::lexical_cast<std::string>(env->getUpperRightY());
 
   82   if(envIntersects == 0)
 
  105   std::string lowerX = 
"lower_x";
 
  106   std::string upperX = 
"upper_x";
 
  107   std::string lowerY = 
"lower_y";
 
  108   std::string upperY = 
"upper_y";
 
  110   m_sql += 
"NOT("+ lowerX +
" > " + boost::lexical_cast<std::string>(e->
m_urx) + 
" OR ";
 
  111   m_sql += upperX +
" < " + boost::lexical_cast<std::string>(e->
m_llx) + 
" OR ";
 
  112   m_sql += lowerY +
" > " + boost::lexical_cast<std::string>(e->
m_ury) + 
" OR ";
 
  113   m_sql += upperY +
" < " + boost::lexical_cast<std::string>(e->
m_lly) + 
")";
 
  118   std::vector<std::string> values;
 
  121   if(values.size() == 1)
 
  124     m_sql += values[values.size() - 1];
 
Utility functions for ADO. 
 
Expression * getFirst() const 
It returns the first function argument. 
 
SQLVisitor(const te::da::SQLDialect &dialect, std::string &sql, _ConnectionPtr conn)
Default constructor. 
 
A class that models a literal for Date and Time values. 
 
const std::string & getName() const 
It returns the property name. 
 
A class that models the name of any property of an object. 
 
An operator that considers the intersection among approximations or envelopes of geometries. 
 
A class that models a literal for Geometry values. 
 
It represents the SQL query dialect accepted by a given data source. 
 
A visitor for building an SQL statement using ADO dialect. 
 
double m_lly
Lower left corner y-coordinate. 
 
virtual void visit(const Expression &visited)
 
A class that models a literal for ByteArray values. 
 
void visit(const te::da::Function &visited)
 
double m_ury
Upper right corner y-coordinate. 
 
A visitor for building an SQL statement using ADO dialect. 
 
A class that models a literal for Envelope values. 
 
double m_urx
Upper right corner x-coordinate. 
 
void Tokenize(const std::string &str, std::vector< std::string > &tokens, const std::string &delimiters=" ")
It tokenizes a given string with a delimiter of your own choice. 
 
Expression * getSecond() const 
It returns the second function argument. 
 
double m_llx
Lower left corner x-coordinate. 
 
A class that models a Function expression. 
 
An Envelope defines a 2D rectangular region. 
 
te::gm::Envelope * getValue() const 
It returns the associated envelope value. 
 
te::dt::AbstractData * getValue() const 
It returns the value associated to the literal.