// return the number of classes and total members int Clause::getTotalMembers() const { int memberno = 0; for (ClauseIterator thisIter(*this); !thisIter.done(); thisIter++) { memberno += thisIter().data.getCount(); } return(memberno); }
int LClause::operator>=(const Clause &rhs) const { ClauseIterator thisIter(*this); for (int thislen = 0; !thisIter.done(); thislen++, thisIter++); ClauseIterator rhsIter(rhs); for (int rhslen = 0; !rhsIter.done(); rhslen++, rhsIter++); return(thislen >= rhslen); }
int Clause::getTotalSets() const { int setno = 0; for (ClauseIterator thisIter(*this); !thisIter.done(); thisIter++) { setno += 1; } return(setno); }
//////////////////////////////////////////////////////////////////////////// // path.comparisons int path::__compare(const value_type* __s) const { path_view_iterator thisIter(this->native()); path_view_iterator sIter(__s); while (!thisIter.is_end() && !sIter.is_end()) { int res = (*thisIter).compare(*sIter); if (res != 0) return res; ++thisIter; ++sIter; } if (thisIter.is_end() && sIter.is_end()) return 0; if (thisIter.is_end()) return -1; return 1; }