CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Sym.h
Go to the documentation of this file.
1 #ifndef FWCore_Services_Sym_h
2 #define FWCore_Services_Sym_h
3 
4 #include <iosfwd>
5 #include <string>
6 
7 #include <dlfcn.h>
8 
9 struct Sym {
10  typedef void* address_type;
11 
12  Sym(Dl_info const& /*info*/, void* addr) :
13  name_(),
14  library_(),
15  id_(),
16  addr_(reinterpret_cast<address_type>(addr)) {
17  }
18 
19  Sym() :
20  name_(),
21  library_(),
22  id_(),
23  addr_()
24  { }
25 
26  explicit Sym(int id) :
27  name_(),
28  library_(),
29  id_(id),
30  addr_()
31  { }
32 
35  int id_;
37 
38  static int next_id_;
39 
40  bool
42  { return addr_ < b; }
43 
44  bool
45  operator<(const Sym& b) const
46  { return addr_ < b.addr_; }
47 };
48 
49 std::ostream&
50 operator<<(std::ostream& os, Sym const& s);
51 
52 inline
53 bool
55 { return a < b.addr_; }
56 
57 #endif
Definition: Sym.h:9
Sym()
Definition: Sym.h:19
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Definition: ALILine.cc:187
void * address_type
Definition: Sym.h:10
bool operator<(const FedChannelConnection &, const FedChannelConnection &)
std::string library_
Definition: Sym.h:34
Sym(Dl_info const &, void *addr)
Definition: Sym.h:12
std::string name_
Definition: Sym.h:33
double b
Definition: hdecay.h:120
address_type addr_
Definition: Sym.h:36
static int next_id_
Definition: Sym.h:38
double a
Definition: hdecay.h:121
bool operator<(address_type b) const
Definition: Sym.h:41
Sym(int id)
Definition: Sym.h:26
int id_
Definition: Sym.h:35