28 #ifndef _util_ref_identity_h
29 #define _util_ref_identity_h
79 void print(std::ostream&)
const;
82 std::ostream & operator << (std::ostream &o,
const Identifier &i);
97 inline int lt(
const Identity*i,
const Identity*j) {
return i < j; }
99 inline int gt(
const Identity*i,
const Identity*j) {
return i > j; }
101 inline int le(
const Identity*i,
const Identity*j) {
return i <= j; }
103 inline int ge(
const Identity*i,
const Identity*j) {
return i >= j; }
105 inline int eq(
const Identity*i,
const Identity*j) {
return i == j; }
107 inline int ne(
const Identity*i,
const Identity*j) {
return i != j; }
110 inline int cmp(
const Identity*i,
const Identity*j)
112 return (i==j)?0:((i<j)?-1:1);
Identity gives objects a unique identity and ordering relationship relative to all other objects.
Definition: identity.h:89
int operator==(const Identifier &i) const
Equal.
Definition: identity.h:71
Identifier(const Identifier &i)
Create an Identifier for the given object.
Definition: identity.h:59
~Identifier()
The destructor does nothing.
Definition: identity.h:61
void operator=(const Identifier &i)
Assign to the given Identifier.
Definition: identity.h:64
int operator>=(const Identifier &i) const
Greater than or equal.
Definition: identity.h:75
int operator!=(const Identifier &i) const
Not equal.
Definition: identity.h:77
Identifier(const Identity *i)
Create an Identifier for the given object.
Definition: identity.h:57
int operator<(const Identifier &i) const
Less than.
Definition: identity.h:67
Identifier identifier()
Return the Identifier for this argument.
Definition: identity.h:94
int operator<=(const Identifier &i) const
Less than or equal.
Definition: identity.h:73
Identifier's are used to distinguish and order objects.
Definition: identity.h:50
Identifier()
Create an Identifier for a null object.
Definition: identity.h:55
int operator>(const Identifier &i) const
Greater than.
Definition: identity.h:69
Generated at Sun Jan 26 2020 23:33:03 for MPQC
2.3.1 using the documentation package Doxygen
1.8.16.