72 if (
ext::type_index (
typeid ( *
this ) ) ==
ext::type_index (
typeid ( other ) ) )
return * this <=>
static_cast < decltype ( ( * this ) )
> ( other );
87 return m_id <=> other.m_id;
89 return std::strong_ordering::less;
91 return std::strong_ordering::greater;
98 if (
ext::type_index (
typeid ( *
this ) ) ==
ext::type_index (
typeid ( other ) ) )
return *
this ==
static_cast < decltype ( ( * this ) )
> ( other );
114 res = m_id == other.m_id;
127 explicit operator std::string ( )
const override;
162 return new AnyObject(std::move(*
this));
167 out << this->getData ( );
168 for (
unsigned i = 0;
i < m_id; ++
i )
174 return ext::to_string ( this->getData ( ) ) + std::string (
"'", m_id );
Definition: typeindex.h:37
Definition: AnyObjectBase.h:32
Represents an adaptor of any type to a class in type hierarchy of objects in the algorithms library.
Definition: AnyObject.h:37
std::strong_ordering operator<=>(const AnyObjectBase &other) const override
<=> ( const AnyObjectBase & ) const
Definition: AnyObject.h:71
void increment(unsigned by) override
Increments the unique counter of the object. ( ) const
Definition: AnyObject.h:132
AnyObjectBase * clone() const &override
Virtual copy constructor. ( ) const &
unsigned getId() const override
( ) const
Definition: AnyObject.h:146
AnyObject(T, unsigned id=0)
Constructor of the class based on the value of the wrapped object.
Definition: AnyObject.h:152
void operator>>(ext::ostream &out) const override
>> ( ext::ostream & ) const
Definition: AnyObject.h:166
const T & getData() const
Definition: AnyObject.h:178
bool operator==(const AnyObjectBase &other) const override
== ( const AnyObjectBase & ) const
Definition: AnyObject.h:97
int i
Definition: AllEpsilonClosure.h:118
return res
Definition: MinimizeByPartitioning.h:145
std::string to_string(const T &value)
To string method designated for objects that can be casted to string.
Definition: string.hpp:131
Definition: AnyObject.h:28
Definition: FordFulkerson.hpp:16