libsmbios_c library
IFactory.h
Go to the documentation of this file.
1 // vim:expandtab:autoindent:tabstop=4:shiftwidth=4:filetype=c:
2 /*
3  * Copyright (C) 2005 Dell Inc.
4  * by Michael Brown <Michael_E_Brown@dell.com>
5  * Licensed under the Open Software License version 2.1
6  *
7  * Alternatively, you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published
9  * by the Free Software Foundation; either version 2 of the License,
10  * or (at your option) any later version.
11 
12  * This program is distributed in the hope that it will be useful, but
13  * WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15  * See the GNU General Public License for more details.
16  */
17 
18 //
19 
20 #ifndef IFACTORY_H_INCLUDED
21 #define IFACTORY_H_INCLUDED
22 
23 // compat header should always be first header
24 #include "smbios/compat.h"
25 
26 #include <string>
27 
28 // types.h should be first user-defined header.
29 #include "smbios/types.h"
30 
31 // abi_prefix should be last header included before declarations
33 
34 namespace factory
35 {
37 
39  class IFactory
40  {
41  public:
42  virtual ~IFactory();
43 
44  // Set Methods
45  virtual void setParameter( const std::string name, const std::string value) = 0;
46  virtual void setParameter( const std::string name, const u32 value) = 0;
47  virtual void setMode( const int mode ) = 0;
48  virtual void reset() = 0;
49 
50  // CONST Methods
51  virtual std::string getParameterString( const std::string name ) const = 0;
52  virtual u32 getParameterNum( const std::string name ) const = 0;
53  virtual int getMode( ) const = 0;
54 
55  // DATA Definitions
56  // standard modes.
59  protected:
60  IFactory();
61  };
62 
63 }
64 
65 // always should be last thing in header file
67 
68 #endif /* IFACTORY_H_INCLUDED */