operator<<,>>(std::independent_bits_engine)
提供: cppreference.com
template< class CharT, class Traits, class Engine, size_t w, class UIntType > std::basic_ostream<CharT,Traits>& operator<<( std::basic_ostream<CharT,Traits>& ost, const std::independent_bits_engine<Engine,w,UIntType>& e ); |
(1) | (C++11以上) |
template< class CharT, class Traits, class Engine, size_t w, class UIntType > std::basic_istream<CharT,Traits>& operator>>( std::basic_istream<CharT,Traits>& ist, std::independent_bits_engine<Engine,w,UIntType>& e ); |
(2) | (C++11以上) |
1) 擬似乱数エンジンアダプタの内部状態を、1個以上の空白で区切られた10進数の並びとしてシリアライズし、それをストリーム
ost に挿入します。 ストリームのフィル文字および書式フラグは無視され、影響を受けません。2) 同じロケールが設定された同じ
CharT および Traits のストリームを使用して以前に operator<< を呼んで作成されたシリアライズ表現から、擬似乱数エンジンアダプタ e の内部状態を復元します。 入力がデシリアライズできない場合、 e は変更されず、 ist の failbit がセットされます。os << x を使用してテキスト表現が書き込まれ、同じ型の同じまたは別のオブジェクト y に is >> y を使用してその表現が復元された場合、 x==y になります。
| This section is incomplete Reason: standard also defines what the textual representation consists of |
引数
| ost | - | データを挿入する出力ストリーム |
| ist | - | データを抽出する入力ストリーム |
| e | - | シリアライズまたは復元するエンジンアダプタ |
戻り値
1)
ost。2)
ist。計算量
| This section is incomplete |
例外
1) (なし)
2)
failbit をセットしたときに std::ios::failure を投げるかもしれません。