istream File Reference

#include <ios>
#include <limits>

Include dependency graph for istream:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  std


Detailed Description

This is a Standard C++ Library header. You should #include this header in your programs, rather than any of the "st[dl]_*.h" implementation files.

Definition in file istream.


Function Documentation

template<class Traits>
basic_istream<char,Traits>& operator>> basic_istream< char, Traits > &  in,
signed char *  s
 

Character string extractors.

Parameters:
in An input stream.
s A pointer to a character array.
Returns:
in
Behaves like one of the formatted arithmetic extractors described in std::basic_istream. After constructing a sentry object with good status, this function extracts up to n characters and stores them into the array starting at s. n is defined as:

  • if width() is greater than zero, n is width()
  • otherwise n is "the number of elements of the largest array of char_type that can store a terminating eos." [27.6.1.2.3]/6

Characters are extracted and stored until one of the following happens:

  • n-1 characters are stored
  • EOF is reached
  • the next character is whitespace according to the current locale
  • the next character is a null byte (i.e., charT() )

width(0) is then called for the input stream.

If no characters are extracted, sets failbit.

Definition at line 689 of file istream.

template<class Traits>
basic_istream<char,Traits>& operator>> basic_istream< char, Traits > &  in,
unsigned char *  s
 

Character string extractors.

Parameters:
in An input stream.
s A pointer to a character array.
Returns:
in
Behaves like one of the formatted arithmetic extractors described in std::basic_istream. After constructing a sentry object with good status, this function extracts up to n characters and stores them into the array starting at s. n is defined as:

  • if width() is greater than zero, n is width()
  • otherwise n is "the number of elements of the largest array of char_type that can store a terminating eos." [27.6.1.2.3]/6

Characters are extracted and stored until one of the following happens:

  • n-1 characters are stored
  • EOF is reached
  • the next character is whitespace according to the current locale
  • the next character is a null byte (i.e., charT() )

width(0) is then called for the input stream.

If no characters are extracted, sets failbit.

Definition at line 684 of file istream.

template<class Traits>
basic_istream<char, Traits>& operator>> basic_istream< char, Traits > &  in,
signed char &  c
 

Character extractors.

Parameters:
in An input stream.
c A character reference.
Returns:
in
Behaves like one of the formatted arithmetic extractors described in std::basic_istream. After constructing a sentry object with good status, this function extracts a character (if one is available) and stores it in c. Otherwise, sets failbit in the input stream.

Definition at line 648 of file istream.

template<class Traits>
basic_istream<char, Traits>& operator>> basic_istream< char, Traits > &  in,
unsigned char &  c
 

Character extractors.

Parameters:
in An input stream.
c A character reference.
Returns:
in
Behaves like one of the formatted arithmetic extractors described in std::basic_istream. After constructing a sentry object with good status, this function extracts a character (if one is available) and stores it in c. Otherwise, sets failbit in the input stream.

Definition at line 643 of file istream.


Generated on Thu Feb 10 23:23:20 2005 for libstdc++-v3 Source by  doxygen 1.4.0