名前空間
変種
操作

「cpp/utility/functional/greater equal」の版間の差分

提供: cppreference.com
< cpp‎ | utility‎ | functional
(r2.7.3) (ロボットによる 追加: de, en, es, fr, it, pt, ru, zh)
(Use {{lc}}. Update links. Various fixes.)
2行: 2行:
 
{{cpp/title|greater_equal}}
 
{{cpp/title|greater_equal}}
 
{{cpp/utility/functional/navbar}}
 
{{cpp/utility/functional/navbar}}
{{ddcl list begin}}
+
{{begin}}
{{ddcl list header | functional }}
+
{{header | functional }}
{{ddcl list item |
+
{{|
 
template< class T >
 
template< class T >
 
struct greater_equal;
 
struct greater_equal;
 
}}
 
}}
{{ddcl list end}}
+
{{end}}
  
 
{{tr|比較を行うための関数オブジェクト。タイプ{{c|operator>{{=}}}}に{{tt|T}}を実装しています.|Function object for performing comparisons. Implements {{c|operator>{{=}}}} on type {{tt|T}}.}}
 
{{tr|比較を行うための関数オブジェクト。タイプ{{c|operator>{{=}}}}に{{tt|T}}を実装しています.|Function object for performing comparisons. Implements {{c|operator>{{=}}}} on type {{tt|T}}.}}
16行: 16行:
  
 
===メンバータイプ===
 
===メンバータイプ===
{{dcl list begin}}
+
{{begin}}
{{dcl list hitem |{{tr| タイプ | type }}| definition }}
+
{{hitem |{{tr| タイプ | type }}| definition }}
{{dcl list item | {{tt|result_type}} | {{tt|bool}}}}
+
{{| {{tt|result_type}} | {{tt|bool}}}}
{{dcl list item | {{tt|first_argument_type}} | {{tt|T}} }}
+
{{| {{tt|first_argument_type}} | {{tt|T}} }}
{{dcl list item | {{tt|second_argument_type}} | {{tt|T}} }}
+
{{| {{tt|second_argument_type}} | {{tt|T}} }}
{{dcl list end}}
+
{{end}}
  
 
===メンバ関数===
 
===メンバ関数===
{{dcl list begin}}
+
{{begin}}
{{dcl list mem fun | operator() | nolink=true |{{tr| 最初の引数があるかどうかをチェック''大きい''よりまたは第二に'''​​'等しい| checks if the first argument is ''greater'' than or ''equal'' to the second}}}}
+
{{mem fun | operator() | nolink=true |{{tr| 最初の引数があるかどうかをチェック''大きい''よりまたは第二に'''​​'等しい| checks if the first argument is ''greater'' than or ''equal'' to the second}}}}
{{dcl list end}}
+
{{end}}
  
 
{{member | {{small|{{tr|のstd :: greater_equal ::|std::greater_equal::}}}}operator() | 2=
 
{{member | {{small|{{tr|のstd :: greater_equal ::|std::greater_equal::}}}}operator() | 2=
36行: 36行:
  
 
===Parameters===
 
===Parameters===
{{param list begin}}
+
{{begin}}
{{param list item | lhs, rhs |{{tr| 比較する値| values to compare}}}}
+
{{| lhs, rhs |{{tr| 比較する値| values to compare}}}}
{{param list end}}
+
{{end}}
  
 
===Return value===
 
===Return value===

2013年7月2日 (火) 16:24時点における版

 
 
ユーティリティライブラリ
汎用ユーティリティ
日付と時間
関数オブジェクト
書式化ライブラリ (C++20)
(C++11)
関係演算子 (C++20で非推奨)
整数比較関数
(C++20)
スワップと型操作
(C++14)
(C++11)
(C++11)
(C++11)
(C++17)
一般的な語彙の型
(C++11)
(C++17)
(C++17)
(C++17)
(C++17)

初等文字列変換
(C++17)
(C++17)
 
関数オブジェクト
関数ラッパー
(C++11)
(C++11)
関数の部分適用
(C++20)
(C++11)
関数呼び出し
(C++17)
恒等関数オブジェクト
(C++20)
参照ラッパー
(C++11)(C++11)
演算子ラッパー
否定子
(C++17)
検索子
制約付き比較子
古いバインダとアダプタ
(C++17未満)
(C++17未満)
(C++17未満)
(C++17未満)
(C++17未満)(C++17未満)(C++17未満)(C++17未満)
(C++20未満)
(C++20未満)
(C++17未満)(C++17未満)
(C++17未満)(C++17未満)

(C++17未満)
(C++17未満)(C++17未満)(C++17未満)(C++17未満)
(C++20未満)
(C++20未満)
 
ヘッダ <functional> で定義
template< class T >
struct greater_equal;
比較を行うための関数オブジェクト。タイプoperator>=Tを実装しています.
Original:
Function object for performing comparisons. Implements operator>= on type T.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

目次

ノート

任意のポインタ型に対する std::greater_equal の特殊化は、たとえ組み込みの operator<= がそうでなくても、狭義全順序を生成します。 狭義全順序はそのポインタ型に対する std::lessstd::greaterstd::less_equal および std::greater_equal の特殊化に渡って一貫しており、また対応する組み込みの演算子 (<><= および >=) によって与えられる部分順序とも一貫しています。

特殊化 std::greater_equal<void> の関数呼び出し演算子がポインタを比較する組み込みの演算子を呼ぶ場合、たとえ組み込みの operator<= がそうでなくても、狭義全順序を生成します。 この狭義全順序は特殊化 std::less<void>std::greater<void>std::less_equal<void> および std::greater_equal<void> に渡って一貫しており、また対応する組み込みの演算子によって与えられる部分順序とも一貫しています。

(C++14以上)

メンバータイプ

タイプ
Original:
type
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
definition
result_type bool
first_argument_type T
second_argument_type T

メンバ関数

operator()
最初の引数があるかどうかをチェック大きいよりまたは第二に​​'等しい
Original:
checks if the first argument is greater than or equal to the second
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)

のstd :: greater_equal ::
Original:
std::greater_equal::
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
operator()

bool operator()( const T& lhs, const T& rhs ) const;

Checks whether lhs is greater than or equal to rhs.

Parameters

lhs, rhs -
比較する値
Original:
values to compare
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Return value

true if lhs >= rhs, false otherwise.

Exceptions

(none)

Possible implementation

bool operator()(const T &lhs, const T &rhs) const 
{
    return lhs >= rhs;
}