wibble 1.1
Classes | Public Member Functions | List of all members
wibble::str::Split Class Reference

Split a string where a given substring is found. More...

#include <string.h>

Classes

class  const_iterator
 

Public Member Functions

 Split (const std::string &sep, const std::string &str)
 Create a splitter that uses the given regular expression to find tokens.
 
const_iterator begin () const
 Split the string and iterate the resulting tokens.
 
const_iterator end () const
 

Detailed Description

Split a string where a given substring is found.

This does a similar work to the split functions of perl, python and ruby.

Example code:

std::copy(splitter.begin(), splitter.end(), back_inserter(split));
Split a string where a given substring is found.
Definition string.h:315
Definition amorph.h:30

Constructor & Destructor Documentation

◆ Split()

wibble::str::Split::Split ( const std::string &  sep,
const std::string &  str 
)
inline

Create a splitter that uses the given regular expression to find tokens.

Member Function Documentation

◆ begin()

const_iterator wibble::str::Split::begin ( ) const
inline

Split the string and iterate the resulting tokens.

◆ end()

const_iterator wibble::str::Split::end ( ) const
inline

The documentation for this class was generated from the following file: