Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7371 in orxonox.OLD for trunk/src/lib/shell/shell_completion.h


Ignore:
Timestamp:
Apr 26, 2006, 2:12:45 AM (18 years ago)
Author:
bensch
Message:

orxonox/trunk: better completion-algos

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/shell/shell_completion.h

    r7343 r7371  
    2020#endif
    2121
    22 //! an enumerator for different types the Shell can complete.
    23 typedef enum {
    24   SHELLC_NONE        = 0,
    25   SHELLC_CLASS       = 1,
    26   SHELLC_OBJECT      = 2,
    27   SHELLC_FUNCTION    = 4,
    28   SHELLC_ALIAS       = 8,
    29 } SHELLC_TYPE;
    30 
    31 //! A struct for ShellElements (these are used as containers to identify an Input for what it is)
    32 struct ShellC_Element{
    33   std::string     name;     //!< the Name of the Element to be completed.
    34   SHELLC_TYPE     type;     //!< the type of the Element
    35 };
    3622
    3723//! A class for ...
    3824class ShellCompletion {
     25
     26  //! an enumerator for different types the Shell can complete.
     27  typedef enum {
     28    SHELLC_NONE        = 0,
     29    SHELLC_CLASS       = 1,
     30    SHELLC_OBJECT      = 2,
     31    SHELLC_FUNCTION    = 4,
     32    SHELLC_ALIAS       = 8,
     33  } SHELLC_TYPE;
     34
     35//! A struct for ShellElements (these are used as containers to identify an Input for what it is)
     36  struct ShellC_Element{
     37    std::string     name;     //!< the Name of the Element to be completed.
     38    SHELLC_TYPE     type;     //!< the type of the Element
     39  };
    3940
    4041 public:
     
    5556                       const std::string& addBack = "", const std::string& addFront = "");
    5657
    57   bool addToCompleteList(const std::list<std::string>* inputList, const std::string& completionBegin, SHELLC_TYPE type);
    58   bool addToCompleteList(const std::list<BaseObject*>* inputList, const std::string& completionBegin, SHELLC_TYPE type);
    59   void emptyCompletionList();
     58
     59  bool addToCompleteList(const std::list<std::string>& inputList, const std::string& completionBegin, SHELLC_TYPE type);
     60  bool addToCompleteList(const std::list<BaseObject*>& inputList, const std::string& completionBegin, SHELLC_TYPE type);
     61  void clearCompletionList();
    6062
    6163  static const char* ShellCompletion::typeToString(SHELLC_TYPE type);
Note: See TracChangeset for help on using the changeset viewer.