Elm  1.0
ELM is a library providing generic data structures, OS-independent interface, plugins and XML.
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IntOption.h
1 /*
2  * $Id$
3  * IntOption class interface
4  *
5  * This file is part of OTAWA
6  * Copyright (c) 2006-09, IRIT UPS.
7  *
8  * OTAWA is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; either version 2 of the License, or
11  * (at your option) any later version.
12  *
13  * OTAWA is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with OTAWA; if not, write to the Free Software
20  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
21  */
22 #ifndef ELM_OPTION_INT_OPTION_H
23 #define ELM_OPTION_INT_OPTION_H
24 
25 #include <elm/option/ValueOption.h>
26 
27 namespace elm { namespace option {
28 
29 // IntOption class
30 class IntOption: public ValueOption<int> {
31 public:
32  IntOption(
33  Manager& manager,
34  char short_name,
36  CString arg_description,
37  int value = 0);
38  IntOption(
39  Manager& manager,
40  CString long_name,
41  CString description,
42  CString arg_description,
43  int value = 0);
44  IntOption(
45  Manager& manager,
46  char short_name,
47  CString long_name,
48  CString description,
49  CString arg_description,
50  int value = 0);
51 
52  // Option overload
53  virtual void process(String arg);
54 };
55 
56 } } // elm::option
57 
58 #endif // ELM_OPTION_INT_OPTION_H
Definition: CString.h:17
Definition: IntOption.h:30
const int & value(void) const
Definition: ValueOption.h:124
Definition: Manager.h:59
virtual cstring description(void)
Definition: option_ValueOption.cpp:182
IntOption(Manager &manager, char short_name, CString description, CString arg_description, int value=0)
Definition: option_IntOption.cpp:46
virtual void process(String arg)
Definition: option_IntOption.cpp:96
Definition: String.h:31
Definition: ValueOption.h:73