Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7214 in orxonox.OLD for branches/std/src/lib/util/substring.h


Ignore:
Timestamp:
Mar 10, 2006, 7:18:03 PM (18 years ago)
Author:
bensch
Message:

orxonox/trunk: now the branche works again, as it did before

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/std/src/lib/util/substring.h

    r7212 r7214  
    3535
    3636  inline unsigned int getCount() { return this->strings.size(); };
    37   const std::string& getString(unsigned int i) { return this->strings[i]; };
     37  const std::string& getString(unsigned int i) { return (i < this->strings.size()) ? this->strings[i] : emptyString; };
    3838  unsigned int getOffset(unsigned int i);
    3939
     
    4848   std::vector<std::string>  strings;                      //!< strings produced from a single string splitted in multiple strings
    4949   std::vector<unsigned int> offsets;                      //!< offsets of the beginning of the input-string to the beginning of each substring.
     50
     51   static const std::string emptyString;
    5052};
    5153
Note: See TracChangeset for help on using the changeset viewer.