6 #include "knowrob/formulas/PredicateIndicator.h"
7 #include "knowrob/terms/Function.h"
8 #include "knowrob/terms/Numeric.h"
9 #include "knowrob/integration/python/utils.h"
14 return arity_ == other.arity_ && *functor_ == *other.functor_;
18 if (arity_ != other.arity_) {
19 return arity_ < other.arity_;
21 return functor_->stringForm() < other.functor_->stringForm();
25 os << *functor_ <<
'/' << arity_;
29 return std::make_shared<Function>(
Function(
"/", {
31 std::make_shared<Long>(
arity())
39 class_<PredicateIndicator, std::shared_ptr<PredicateIndicator>>
40 (
"PredicateIndicator", init<const std::string &, unsigned int>())
41 .def(init<AtomPtr, unsigned int>())
42 .def(
"__eq__", &PredicateIndicator::operator==)
bool operator<(const PredicateIndicator &other) const
void write(std::ostream &os) const override
std::shared_ptr< Term > toTerm() const
bool operator==(const PredicateIndicator &other) const
void createType< PredicateIndicator >()