Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The nested class describes an object whose declaration structures the formatted and unformatted input functions.
class sentry {
public:
explicit sentry(
basic_istream<Elem, Tr>& _Istr,
bool _Noskip = false
);
operator bool( ) const;
};
Remarks
If _Istr.good is true, the constructor:
If, after any such preparation, _Istr.good is false, the constructor calls _Istr.setstate(failbit). In any case, the constructor stores the value returned by _Istr.good in status. A later call to operator bool delivers this stored value.
Requirements
Header: <istream>
Namespace: std