Limbo
3.5.4
Toggle main menu visibility
Loading...
Searching...
No Matches
test
parsers
tf
test_spirit.cpp
Go to the documentation of this file.
1
7
8
#include <iostream>
9
#include <string>
10
11
#include <
limbo/parsers/tf/spirit/TfParser.h
>
12
13
using
std::cout;
14
using
std::endl;
15
using
std::string;
16
19
struct
TfDataBase
:
public
TfParser::TfDataBase
20
{
25
void
add_tf_layer_id
(
string
const
& s1, int32_t
const
& s2,
string
const
& s3)
26
{
27
cout << __func__ << endl;
28
cout << s1 <<
", "
<< s2 <<
", "
<< s3 << endl;
29
}
30
};
31
33
void
test1
(
string
const
& filename)
34
{
35
cout <<
"////////////// test1 ////////////////"
<< endl;
36
TfDataBase
db;
37
TfParser::read
(db, filename);
38
}
39
44
int
main
(
int
argc,
char
** argv)
45
{
46
47
if
(argc > 1)
48
{
49
test1
(argv[1]);
50
}
51
else
52
cout <<
"at least 1 argument is required"
<< endl;
53
54
return
0;
55
}
TfParser.h
tf parser for technology file
TfDataBase
Custom class that inheritates TfParser::TfDataBase with all the required callbacks defined.
Definition
test_spirit.cpp:20
TfDataBase::add_tf_layer_id
void add_tf_layer_id(string const &s1, int32_t const &s2, string const &s3)
add layer name, layer id, layer abbreviation
Definition
test_spirit.cpp:25
TfParser::TfDataBase
Base class for tf database. Only pure virtual functions are defined. User needs to inheritate this ...
Definition
TfParser.h:62
TfParser::read
static bool read(DataBaseType &db, const string &tfFile)
API to read tf file.
Definition
TfParser.h:199
main
int main()
Definition
test_ChromaticNumber.cpp:78
test1
void test1()
test function API
Definition
test_solvers.cpp:11
Generated on
for Limbo by
1.17.0