Jpp 19.3.0-rc.2
the software that should make you happy
Loading...
Searching...
No Matches
std Namespace Reference

Classes

struct  array
 
class  initializer_list
 
struct  iterator
 
class  list
 
class  map
 
class  multimap
 
class  multiset
 
class  pair
 
class  set
 
class  vector
 

Functions

std::istream & operator>> (std::istream &in, std::vector< int > &object)
 Read std::vector<int> from input.
 
std::ostream & operator<< (std::ostream &out, const std::vector< int > &object)
 Write std::vector<int> to output.
 

Function Documentation

◆ operator>>()

std::istream & std::operator>> ( std::istream & in,
std::vector< int > & object )
inline

Read std::vector<int> from input.

Parameters
ininput stream
objectobject
Returns
input stream

Definition at line 56 of file JStreamAvailable.cc.

57 {
58 for (int value; in >> value; ) {
59 object.push_back(value);
60 }
61
62 return in;
63 }

◆ operator<<()

std::ostream & std::operator<< ( std::ostream & out,
const std::vector< int > & object )
inline

Write std::vector<int> to output.

Parameters
outoutput stream
objectobject
Returns
output stream

Definition at line 73 of file JStreamAvailable.cc.

74 {
75 for (std::vector<int>::const_iterator i = object.begin(); i != object.end(); ++i) {
76 out << ' ' << *i;
77 }
78
79 return out;
80 }