Public Member Functions | Private Member Functions | Private Attributes

events::cmd_arg_parser Class Reference

Collaboration diagram for events::cmd_arg_parser:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 cmd_arg_parser ()
 cmd_arg_parser (const std::string &str)
void parse (const std::string &str)
const std::string & get_str () const
std::string get_arg (unsigned n) const
std::string get_data (unsigned n) const
std::string get_cmd () const

Private Member Functions

cmd_arg_parseroperator= (const cmd_arg_parser &)
 cmd_arg_parser (const cmd_arg_parser &)
void advance_to_arg (unsigned n) const

Private Attributes

std::string str_
std::vector< size_t > args
bool args_end

Detailed Description

Definition at line 1885 of file menu_events.cpp.


Constructor & Destructor Documentation

events::cmd_arg_parser::cmd_arg_parser (  )  [inline]

Definition at line 1888 of file menu_events.cpp.

events::cmd_arg_parser::cmd_arg_parser ( const std::string &  str  )  [inline, explicit]

Definition at line 1895 of file menu_events.cpp.

events::cmd_arg_parser::cmd_arg_parser ( const cmd_arg_parser  )  [private]

Member Function Documentation

void events::cmd_arg_parser::advance_to_arg ( unsigned  n  )  const [inline, private]

Definition at line 1940 of file menu_events.cpp.

References args, args_end, and str_.

Referenced by get_arg(), and get_data().

Here is the caller graph for this function:

std::string events::cmd_arg_parser::get_arg ( unsigned  n  )  const [inline]

Definition at line 1914 of file menu_events.cpp.

References advance_to_arg(), args, and str_.

Referenced by events::map_command_handler< chat_command_handler >::get_arg(), and get_cmd().

Here is the call graph for this function:

Here is the caller graph for this function:

std::string events::cmd_arg_parser::get_cmd (  )  const [inline]

Definition at line 1933 of file menu_events.cpp.

References get_arg().

Referenced by events::map_command_handler< chat_command_handler >::get_cmd().

Here is the call graph for this function:

Here is the caller graph for this function:

std::string events::cmd_arg_parser::get_data ( unsigned  n  )  const [inline]

Definition at line 1923 of file menu_events.cpp.

References advance_to_arg(), args, str_, and utils::strip().

Referenced by events::map_command_handler< chat_command_handler >::get_data().

Here is the call graph for this function:

Here is the caller graph for this function:

const std::string& events::cmd_arg_parser::get_str (  )  const [inline]

Definition at line 1910 of file menu_events.cpp.

References str_.

cmd_arg_parser& events::cmd_arg_parser::operator= ( const cmd_arg_parser  )  [private]
void events::cmd_arg_parser::parse ( const std::string &  str  )  [inline]

Definition at line 1902 of file menu_events.cpp.

References args, args_end, and str_.

Referenced by events::map_command_handler< chat_command_handler >::parse_cmd().

Here is the caller graph for this function:


Member Data Documentation

std::vector<size_t> events::cmd_arg_parser::args [mutable, private]

Definition at line 1953 of file menu_events.cpp.

Referenced by advance_to_arg(), get_arg(), get_data(), and parse().

bool events::cmd_arg_parser::args_end [mutable, private]

Definition at line 1954 of file menu_events.cpp.

Referenced by advance_to_arg(), and parse().

std::string events::cmd_arg_parser::str_ [private]

Definition at line 1952 of file menu_events.cpp.

Referenced by advance_to_arg(), get_arg(), get_data(), get_str(), and parse().


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Thu May 24 2012 01:20:11 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs