SUMO - Simulation of Urban MObility
BinaryInputDevice.cpp File Reference
#include <config.h>
#include <string>
#include "BinaryInputDevice.h"

Go to the source code of this file.

Defines

#define BUF_MAX   1000

Functions

BinaryInputDeviceoperator>> (BinaryInputDevice &os, int &i)
BinaryInputDeviceoperator>> (BinaryInputDevice &os, unsigned int &i)
BinaryInputDeviceoperator>> (BinaryInputDevice &os, SUMOReal &f)
BinaryInputDeviceoperator>> (BinaryInputDevice &os, bool &b)
BinaryInputDeviceoperator>> (BinaryInputDevice &os, std::string &s)
BinaryInputDeviceoperator>> (BinaryInputDevice &os, long &l)

Detailed Description

Author:
Daniel Krajzewicz
Michael Behrisch
Date:
2005-09-15
Version:
Id:
BinaryInputDevice.cpp 11671 2012-01-07 20:14:30Z behrisch

Definition in file BinaryInputDevice.cpp.


Define Documentation

#define BUF_MAX   1000

Definition at line 42 of file BinaryInputDevice.cpp.

Referenced by operator>>().


Function Documentation

BinaryInputDevice& operator>> ( BinaryInputDevice os,
int i 
)
Parameters:
[in,out]osThe BinaryInputDevice to read the int from
[in]iThe int to store the read value into
Returns:
The used BinaryInputDevice for further processing

Definition at line 62 of file BinaryInputDevice.cpp.

References BinaryInputDevice::myStream.

BinaryInputDevice& operator>> ( BinaryInputDevice os,
unsigned int i 
)
Parameters:
[in,out]osThe BinaryInputDevice to read the unsigned int from
[in]iThe unsigned int to store the read value into
Returns:
The used BinaryInputDevice for further processing

Definition at line 69 of file BinaryInputDevice.cpp.

References BinaryInputDevice::myStream.

BinaryInputDevice& operator>> ( BinaryInputDevice os,
SUMOReal f 
)
Parameters:
[in,out]osThe BinaryInputDevice to read the SUMOReal from
[in]iThe SUMOReal to store the read value into
Returns:
The used BinaryInputDevice for further processing

Definition at line 76 of file BinaryInputDevice.cpp.

References BinaryInputDevice::myStream, and SUMOReal.

BinaryInputDevice& operator>> ( BinaryInputDevice os,
bool b 
)
Parameters:
[in,out]osThe BinaryInputDevice to read the bool from
[in]iThe bool to store the read value into
Returns:
The used BinaryInputDevice for further processing

Definition at line 83 of file BinaryInputDevice.cpp.

References BinaryInputDevice::myStream.

BinaryInputDevice& operator>> ( BinaryInputDevice os,
std::string &  s 
)

Reads the length of the string as an unsigned 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.

Parameters:
[in,out]osThe BinaryInputDevice to read the string from
[in]iThe string to store the read value into
Returns:
The used BinaryInputDevice for further processing
Todo:
Use either a buffer with a flexible size or report an error if the buffer is too small!

Definition at line 91 of file BinaryInputDevice.cpp.

References BUF_MAX, BinaryInputDevice::myBuffer, and BinaryInputDevice::myStream.

BinaryInputDevice& operator>> ( BinaryInputDevice os,
long l 
)
Parameters:
[in,out]osThe BinaryInputDevice to read the long from
[in]iThe int to store the read value into
Returns:
The used BinaryInputDevice for further processing

Definition at line 105 of file BinaryInputDevice.cpp.

References BinaryInputDevice::myStream.

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Defines