BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
Calibration/facilities/include/facilities/Converter.h
Go to the documentation of this file.
1// $Id: Converter.h,v 1.1.1.1 2005/10/17 06:11:40 maqm Exp $
2//
3// Original author: Sawyer Gillespie
4// hgillesp@u.washington.edu
5//
6
7#ifndef _H_Converter_facilities_
8#define _H_Converter_facilities_
9
10// class Converter
11// Template class to define the converter behavior. This is really just
12// specifying a pattern.
13//
14template <class Ty1, class Ty2> class Converter {
15public:
16 // type declarations
17 typedef Ty1 source;
18 typedef Ty2 destination;
19
20 // declare the forward method
21 inline destination* operator( const source& ) const;
22
23protected:
24 // do the actual conversion here
25 virtual destination* convert( const source& ) const = 0;
26};
27
28// inline declarations
29
30template <class Ty1, class Ty2>
33 return convert( s );
34}
35
36#endif // _H_Converter_facilities_
XmlRpcServer s
virtual destination * convert(const source &) const =0
destination * operator(const source &) const