SUMO - Simulation of Urban MObility
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
OutputDevice_File.h
Go to the documentation of this file.
1 /****************************************************************************/
8 // An output device that encapsulates an ofstream
9 /****************************************************************************/
10 // SUMO, Simulation of Urban MObility; see http://sumo.dlr.de/
11 // Copyright (C) 2004-2015 DLR (http://www.dlr.de/) and contributors
12 /****************************************************************************/
13 //
14 // This file is part of SUMO.
15 // SUMO is free software: you can redistribute it and/or modify
16 // it under the terms of the GNU General Public License as published by
17 // the Free Software Foundation, either version 3 of the License, or
18 // (at your option) any later version.
19 //
20 /****************************************************************************/
21 #ifndef OutputDevice_File_h
22 #define OutputDevice_File_h
23 
24 
25 // ===========================================================================
26 // included modules
27 // ===========================================================================
28 #ifdef _MSC_VER
29 #include <windows_config.h>
30 #else
31 #include <config.h>
32 #endif
33 
34 #include <fstream>
35 #include "OutputDevice.h"
36 
37 
38 // ===========================================================================
39 // class definitions
40 // ===========================================================================
49 public:
54  OutputDevice_File(const std::string& fullName, const bool binary);
55 
56 
59 
60 
61 protected:
64 
68  std::ostream& getOStream();
70 
71 
72 private:
74  std::ofstream* myFileStream;
75 
76 };
77 
78 
79 #endif
80 
81 /****************************************************************************/
82 
std::ostream & getOStream()
Returns the associated ostream.
std::ofstream * myFileStream
The wrapped ofstream.
An output device that encapsulates an ofstream.
~OutputDevice_File()
Destructor.
OutputDevice_File(const std::string &fullName, const bool binary)
Constructor.
Static storage of an output device and its base (abstract) implementation.
Definition: OutputDevice.h:71