![]() |
SUMO - Simulation of Urban MObility
|
#include <config.h>
#include <string>
#include <utils/common/StdDefs.h>
#include <utils/geom/Position.h>
#include "BinaryFormatter.h"
#include "BinaryInputDevice.h"
Go to the source code of this file.
Macros | |
#define | BUF_MAX 10000 |
Functions | |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, char &c) |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, unsigned char &c) |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, int &i) |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, double &f) |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, bool &b) |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, std::string &s) |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, std::vector< std::string > &v) |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, std::vector< int > &v) |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, std::vector< std::vector< int > > &v) |
BinaryInputDevice & | operator>> (BinaryInputDevice &os, Position &p) |
#define BUF_MAX 10000 |
Definition at line 34 of file BinaryInputDevice.cpp.
Referenced by operator>>().
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
char & | c | ||
) |
[in,out] | os | The BinaryInputDevice to read the char from |
[in] | c | The char to store the read value into |
Definition at line 89 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_BYTE, BinaryInputDevice::checkType(), and BinaryInputDevice::myStream.
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
unsigned char & | c | ||
) |
[in,out] | os | The BinaryInputDevice to read the char from |
[in] | c | The char to store the read value into |
Definition at line 97 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_BYTE, BinaryInputDevice::checkType(), and BinaryInputDevice::myStream.
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
int & | i | ||
) |
[in,out] | os | The BinaryInputDevice to read the int from |
[in] | i | The int to store the read value into |
Definition at line 105 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_INTEGER, BinaryInputDevice::checkType(), and BinaryInputDevice::myStream.
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
double & | f | ||
) |
[in,out] | os | The BinaryInputDevice to read the double from |
[in] | i | The double to store the read value into |
Definition at line 113 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_FLOAT, BinaryFormatter::BF_SCALED2INT, BinaryInputDevice::checkType(), and BinaryInputDevice::myStream.
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
bool & | b | ||
) |
[in,out] | os | The BinaryInputDevice to read the bool from |
[in] | i | The bool to store the read value into |
Definition at line 127 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_BYTE, BinaryInputDevice::checkType(), and BinaryInputDevice::myStream.
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
std::string & | s | ||
) |
Reads the length of the string as an int, first. Reads then the specified number of chars into "myBuffer". Please note that the buffer has a fixed size - longer strings will cause an error.
[in,out] | os | The BinaryInputDevice to read the string from |
[in] | s | The string to store the read value into |
Definition at line 136 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_STRING, BUF_MAX, BinaryInputDevice::checkType(), MIN2(), BinaryInputDevice::myBuffer, and BinaryInputDevice::myStream.
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
std::vector< std::string > & | v | ||
) |
Reads the length of the vector as an int, first. Reads then the specified number of strings using the string input operator. Please note that the buffer has a fixed size - longer strings will cause an error.
[in,out] | os | The BinaryInputDevice to read the string from |
[in] | v | The string vector to store the read value into |
Definition at line 153 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_LIST, BinaryInputDevice::checkType(), and BinaryInputDevice::myStream.
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
std::vector< int > & | v | ||
) |
Reads the length of the vector as an int, first. Reads then the specified number of strings using the string input operator. Please note that the buffer has a fixed size - longer strings will cause an error.
[in,out] | os | The BinaryInputDevice to read the string from |
[in] | v | The string vector to store the read value into |
Definition at line 168 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_LIST, BinaryInputDevice::checkType(), and BinaryInputDevice::myStream.
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
std::vector< std::vector< int > > & | v | ||
) |
Reads the length of the vector as an int, first. Reads then the specified number of strings using the string input operator. Please note that the buffer has a fixed size - longer strings will cause an error.
[in,out] | os | The BinaryInputDevice to read the string from |
[in] | v | The string vector to store the read value into |
Definition at line 183 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_LIST, BinaryInputDevice::checkType(), and BinaryInputDevice::myStream.
BinaryInputDevice& operator>> | ( | BinaryInputDevice & | os, |
Position & | p | ||
) |
[in,out] | os | The BinaryInputDevice to read the Position from |
[in] | p | The Position to store the read value into |
Definition at line 198 of file BinaryInputDevice.cpp.
References BinaryFormatter::BF_POSITION_2D, BinaryFormatter::BF_POSITION_3D, BinaryFormatter::BF_SCALED2INT_POSITION_2D, BinaryFormatter::BF_SCALED2INT_POSITION_3D, BinaryInputDevice::checkType(), BinaryInputDevice::myStream, and Position::set().