1.00.15
C++ Simulated Revenue Accounting (RAC) System Library
Toggle main menu visibility
Loading...
Searching...
No Matches
YieldParser.cpp
Go to the documentation of this file.
1
// //////////////////////////////////////////////////////////////////////
2
// Import section
3
// //////////////////////////////////////////////////////////////////////
4
// STL
5
#include <cassert>
6
#include <string>
7
// StdAir
8
#include <stdair/basic/BasFileMgr.hpp>
9
// AirRAC
10
#include <
airrac/command/YieldParserHelper.hpp
>
11
#include <
airrac/command/YieldParser.hpp
>
12
13
namespace
AIRRAC
{
14
15
// //////////////////////////////////////////////////////////////////////
16
void
YieldParser::generateYieldStore
(
const
YieldFilePath
& iYieldFilename,
17
stdair::BomRoot& ioBomRoot) {
18
19
const
stdair::Filename_T lFilename = iYieldFilename.name();
20
21
// Check that the file path given as input corresponds to an actual file
22
const
bool
doesExistAndIsReadable =
23
stdair::BasFileMgr::doesExistAndIsReadable (lFilename);
24
if
(doesExistAndIsReadable ==
false
) {
25
STDAIR_LOG_ERROR (
"The yield input file, '"
<< lFilename
26
<<
"', can not be retrieved on the file-system"
);
27
throw
YieldInputFileNotFoundException
(
"The yield file '"
+ lFilename
28
+
"' does not exist or can not "
29
"be read"
);
30
}
31
32
// Initialise the yield file parser.
33
YieldFileParser
lYieldParser (ioBomRoot, lFilename);
34
35
// Parse the CSV-formatted yield store input file, and generate the
36
// corresponding Yield-related objects.
37
lYieldParser.
generateYieldStore
();
38
}
39
}
YieldParserHelper.hpp
YieldParser.hpp
AIRRAC::YieldFileParser
Definition
YieldParserHelper.hpp:202
AIRRAC::YieldFileParser::generateYieldStore
void generateYieldStore()
Definition
YieldParserHelper.cpp:529
AIRRAC::YieldFilePath
Definition
AIRRAC_Types.hpp:82
AIRRAC::YieldInputFileNotFoundException
Definition
AIRRAC_Types.hpp:61
AIRRAC::YieldParser::generateYieldStore
static void generateYieldStore(const YieldFilePath &, stdair::BomRoot &)
Definition
YieldParser.cpp:16
AIRRAC
Definition
AIRRAC_Service.hpp:22
Generated on
for AirRAC by
1.17.0