10 #ifndef _RD_QUERYATOM_H_ 11 #define _RD_QUERYATOM_H_ 35 dp_query = other.dp_query->
copy();
43 bool hasQuery()
const {
return dp_query != 0; };
51 QUERYATOM_QUERY *
getQuery()
const {
return dp_query; };
69 bool maintainOrder =
true);
80 QUERYATOM_QUERY *dp_query;
88 for (
unsigned int i = 0; i < depth; ++i) res +=
" ";
92 res +=
qhelper((*ci).get(), depth + 1);
100 std::string res =
"";
virtual QUERYATOM_QUERY * getQuery() const
NOT CALLABLE.
virtual std::string getFullDescription() const
returns a fuller text description
QUERYATOM_QUERY * getQuery() const
returns our current query
std::string qhelper(Atom::QUERYATOM_QUERY *q, unsigned int depth)
Class for storing atomic queries.
CHILD_VECT_CI endChildren() const
returns an iterator for the end of our child vector
void setQuery(QUERYATOM_QUERY *what)
replaces our current query with the value passed in
Queries::Query< int, Atom const *, true > QUERYATOM_QUERY
std::string describeQuery(const Atom *atom)
QueryAtom(const QueryAtom &other)
int getAtomicNum() const
returns our atomic number
T * makeAtomNumQuery(int what, const std::string &descr)
returns a Query for matching atomic number
virtual bool hasQuery() const
CHILD_VECT_CI beginChildren() const
returns an iterator for the beginning of our child vector
boost::shared_ptr< Atom > ATOM_SPTR
CHILD_VECT::const_iterator CHILD_VECT_CI
#define PRECONDITION(expr, mess)
bool Match(const Atom::ATOM_SPTR &what) const
returns true if we match Atom what
Defines the Atom class and associated typedefs.
Pulls in all the query types.
QueryAtom(const Atom &other)
Base class for all queries.
Atom * copy() const
returns a copy of this query, owned by the caller
The class for representing atoms.
void expandQuery(QUERYATOM_QUERY *what, Queries::CompositeQueryType how=Queries::COMPOSITE_AND, bool maintainOrder=true)
expands our current query
bool QueryMatch(QueryAtom const *what) const
returns true if our query details match those of QueryAtom what
virtual Query< MatchFuncArgType, DataFuncArgType, needsConversion > * copy() const
returns a copy of this Query