SimpleWindow
载入中...
搜索中...
未找到
sw::IComparable< TDerived, TOther > 模板类 参考

全序比较接口 更多...

#include <IComparable.h>

类 sw::IComparable< TDerived, TOther > 继承关系图:
sw::IEqualityComparable< TDerived, TOther >

Public 成员函数

int CompareTo (TOther other) const
 比较当前对象与另一个对象的大小关系
 
bool Equals (TOther other) const
 判断当前对象与另一个对象是否相等
 
bool operator< (TOther other) const
 判断当前对象是否小于另一个对象
 
bool operator<= (TOther other) const
 判断当前对象是否小于或等于另一个对象
 
bool operator> (TOther other) const
 判断当前对象是否大于另一个对象
 
bool operator>= (TOther other) const
 判断当前对象是否大于或等于另一个对象
 
- Public 成员函数 继承自 sw::IEqualityComparable< TDerived, TOther >
bool Equals (TOther other) const
 判断当前对象与另一个对象是否相等
 
bool operator== (TOther other) const
 判断当前对象是否与另一个对象相等
 
bool operator!= (TOther other) const
 判断当前对象是否与另一个对象不相等
 

详细描述

template<typename TDerived, typename TOther = const TDerived &>
class sw::IComparable< TDerived, TOther >

全序比较接口

成员函数说明

◆ CompareTo()

template<typename TDerived , typename TOther = const TDerived &>
int sw::IComparable< TDerived, TOther >::CompareTo ( TOther  other) const
inline

比较当前对象与另一个对象的大小关系

返回
若当前对象小于另一个对象,返回负数;若等于,返回0;若大于,返回正数

该类的文档由以下文件生成: