LLVM  3.7.0
Public Member Functions | Friends | List of all members
llvm::sys::path::const_iterator Class Reference

Path iterator. More...

#include <Path.h>

Inheritance diagram for llvm::sys::path::const_iterator:
[legend]
Collaboration diagram for llvm::sys::path::const_iterator:
[legend]

Public Member Functions

reference operator* () const
 
pointer operator-> () const
 
const_iteratoroperator++ ()
 
const_iteratoroperator++ (int)
 
bool operator== (const const_iterator &RHS) const
 
bool operator!= (const const_iterator &RHS) const
 
ptrdiff_t operator- (const const_iterator &RHS) const
 Difference in bytes between this and RHS. More...
 

Friends

const_iterator begin (StringRef path)
 Get begin iterator over path. More...
 
const_iterator end (StringRef path)
 Get end iterator over path. More...
 

Detailed Description

Path iterator.

This is an input iterator that iterates over the individual components in path. The traversal order is as follows:

Iteration examples. Each component is separated by ',':

/ => /
/foo => /,foo
foo/ => foo,.
/foo/bar => /,foo,bar
../ => ..,.
C:\foo\bar => C:,/,foo,bar

Definition at line 50 of file Path.h.

Member Function Documentation

bool llvm::sys::path::const_iterator::operator!= ( const const_iterator RHS) const
inline

Definition at line 66 of file Path.h.

reference llvm::sys::path::const_iterator::operator* ( ) const
inline

Definition at line 61 of file Path.h.

const_iterator & llvm::sys::path::const_iterator::operator++ ( )

Definition at line 247 of file Path.cpp.

References llvm::sys::path::is_separator().

const_iterator& llvm::sys::path::const_iterator::operator++ ( int  )
ptrdiff_t llvm::sys::path::const_iterator::operator- ( const const_iterator RHS) const

Difference in bytes between this and RHS.

Definition at line 304 of file Path.cpp.

pointer llvm::sys::path::const_iterator::operator-> ( ) const
inline

Definition at line 62 of file Path.h.

bool llvm::sys::path::const_iterator::operator== ( const const_iterator RHS) const

Definition at line 300 of file Path.cpp.

References llvm::StringRef::begin().

Friends And Related Function Documentation

const_iterator begin ( StringRef  path)
friend

Get begin iterator over path.

Parameters
pathInput path.
Returns
Iterator initialized with the first component of path.

Definition at line 232 of file Path.cpp.

const_iterator end ( StringRef  path)
friend

Get end iterator over path.

Parameters
pathInput path.
Returns
Iterator initialized to the end of path.

Definition at line 240 of file Path.cpp.

Referenced by llvm::MipsRegisterInfo::getReservedRegs(), getStruct(), getStructOrErr(), llvm::opt::OptTable::PrintHelp(), llvm::UnrollLoop(), and llvm::UnrollRuntimeLoopProlog().


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