26 #ifndef MLN_UTIL_ORD_PAIR_HH
27 # define MLN_UTIL_ORD_PAIR_HH
33 # include <mln/core/concept/object.hh>
34 # include <mln/util/ord.hh>
54 ord_pair(
const T& val1,
const T& val2);
59 const T&
first()
const;
100 bool operator< (const ord_pair<T>& lhs,
const ord_pair<T>& rhs);
102 template <
typename T>
103 bool operator<=(const ord_pair<T>& lhs,
const ord_pair<T>& rhs);
106 template <
typename T>
107 std::ostream& operator<<(std::ostream& ostr, const ord_pair<T>& op);
115 template <
typename T>
120 # ifndef MLN_INCLUDE_ONLY
129 template <
typename T>
131 ord_pair<T>::ord_pair()
135 template <
typename T>
137 ord_pair<T>::ord_pair(
const T& val1,
const T& val2)
139 change_both(val1, val2);
146 template <
typename T>
154 template <
typename T>
162 template <
typename T>
170 template <
typename T>
178 template <
typename T>
193 template <
typename T>
208 template <
typename T>
230 template <
typename T>
237 template <
typename T>
239 bool operator< (const ord_pair<T>& lhs,
const ord_pair<T>& rhs)
247 template <
typename T>
249 bool operator<=(const ord_pair<T>& lhs,
const ord_pair<T>& rhs)
261 template <
typename T>
263 std::ostream& operator<<(std::ostream& ostr, const ord_pair<T>& op)
265 return ostr <<
'(' << op.first() <<
',' << op.second() <<
')';
274 template <
typename T>
285 # endif // ! MLN_INCLUDE_ONLY
290 #endif // ! MLN_UTIL_ORD_PAIR_HH