-
Notifications
You must be signed in to change notification settings - Fork 0
/
symbolic.h
90 lines (67 loc) · 2.01 KB
/
symbolic.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
//
// Classes for symbolic representations of switching functions
//
#ifndef Symbolic_h
#define Symbolic_h
#include <cstring.h>
#include <vector.h>
namespace swmin {
// Input descriptor
class DLLBLD_SWSYSTEM InputDesc : virtual TStreamableBase
{
public:
string name, desc;
InputDesc();
InputDesc(const string&, const string& = string(""));
~InputDesc();
bool operator==(const InputDesc&) const;
bool operator<(const InputDesc&) const;
DECLARE_STREAMABLE(DLLBLD_SWSYSTEM, InputDesc, 1);
};
#if defined(DLLUSE_SWSYSTEM) || defined(DLLBLD_SWSYSTEM_SYMBOLIC)
#pragma option -vi-
DLLBLD_STLVECTOR(DLLBLD_SWSYSTEM, swmin::InputDesc);
#pragma option -vi
#endif
class DLLBLD_SWSYSTEM InputVector : public std::vector<InputDesc>, virtual TStreamableBase
{
public:
InputVector();
// Generates a naming sequence, prefixed by the string parm, from
// indices specified. Numbers are appended to each input name starting at
// zero.
void Gen_Sequence(const string&, unsigned int, unsigned int);
DECLARE_STREAMABLE(DLLBLD_SWSYSTEM, InputVector, 1);
};
template class DLLBLD_SWSYSTEM std::binary_function<string, string, bool>;
struct DLLBLD_SWSYSTEM stringLess : public std::binary_function<string, string, bool>
{
bool operator() (const string& x, const string& y) const;
};
#if defined(DLLUSE_SWSYSTEM) || defined(DLLBLD_SWSYSTEM_SYMBOLIC)
#pragma option -vi-
DLLBLD_STLSET(DLLBLD_SWSYSTEM, string, swmin::stringLess);
#pragma option -vi
#endif
class DLLBLD_SWSYSTEM SymTerm : public std::set<string, stringLess >
{
public:
SymTerm();
SymTerm(const SymTerm&);
bool operator==(const SymTerm&) const;
bool operator<(const SymTerm&) const;
};
#if defined(DLLUSE_SWSYSTEM) || defined(DLLBLD_SWSYSTEM_SYMBOLIC)
#pragma option -vi-
DLLBLD_STLSET(DLLBLD_SWSYSTEM, swmin::SymTerm, std::less<swmin::SymTerm>);
#pragma option -vi
#endif
class DLLBLD_SWSYSTEM SymExpr : public std::set<SymTerm, std::less<SymTerm> >
{
public:
SymExpr();
SymExpr(const SymExpr&);
};
}
#endif
// EOF