23 #ifndef PRINTABLE_OBJECT_HPP 24 #define PRINTABLE_OBJECT_HPP 42 virtual void print(std::ostream &stream=std::cout)
const;
46 virtual void repr(std::ostream &stream=std::cout)
const;
63 std::string __repr__() {
return $self->getRepresentation(); }
70 #endif // PRINTABLE_OBJECT_HPP friend std::ostream & operator<<(std::ostream &stream, const PrintableObject &obj)
Print a representation of the object to a stream.
std::string getDescription() const
Return a string with a destription (for SWIG)
std::string getRepresentation() const
Return a string with a representation (for SWIG)
Base class for objects that have a natural string representation.
virtual void repr(std::ostream &stream=std::cout) const
Print a representation of the object.
virtual void print(std::ostream &stream=std::cout) const
Print a destription of the object.