Changeset 715 for trunk/yat/utility/Option.h
- Timestamp:
- Dec 22, 2006, 9:42:39 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/yat/utility/Option.h
r687 r715 56 56 Option(char short_name, std::string long_name, 57 57 argument_type arg, std::string desc); 58 59 58 60 59 /// 61 60 /// @return argument type for option 62 61 /// 63 inline const argument_type& arg_type(void) const { return arg_type_; }62 argument_type arg_type(void) const; 64 63 64 /// 65 /// @return long name 66 /// 67 std::string long_name(void) const; 68 65 69 /// 66 70 /// @return long name unless long name is empty in which case the 67 71 /// short one character name is returned. 68 72 /// 69 inline std::string name(void) const 70 { return !long_name_.empty() ? long_name_ : std::string(&short_name_) ; } 73 std::string name(void) const; 71 74 72 75 /// 73 /// @ return short name76 /// @brief Get or set the present status. 74 77 /// 75 inline char short_name(void) const { return short_name_; } 76 78 /// @return true if option has been detected in parsing 77 79 /// 78 /// @return long name 79 /// 80 inline const std::string& long_name(void) const { return long_name_; } 80 bool& present(void); 81 81 82 82 /// … … 88 88 89 89 /// 90 /// @return true if option has been detected in parsing90 /// @return short name 91 91 /// 92 inline bool& present(void) { return present_; }92 char short_name(void) const; 93 93 94 94 /// 95 95 /// @return argument value 96 96 /// 97 inline std::string& value(void) { return value_; }97 std::string value(void); 98 98 99 99
Note: See TracChangeset
for help on using the changeset viewer.