EIC Software
Reference for
EIC
simulation and reconstruction software on GitHub
|
#include <EicRoot/blob/master/PndTools/generalTools/PndStringSeparator.h>
Public Member Functions | |
PndStringSeparator () | |
~PndStringSeparator () | |
PndStringSeparator (std::string AInput, std::string ADelimiter=" ") | |
void | SetInput (std::string AInput) |
void | SetDelimiter (std::string ADelimiter) |
void | ResetVector () |
std::vector< std::string > | GetStringVector (void) |
void | TestFirst () |
void | TestLast () |
bool | GetIfFirst () |
bool | GetIfLast () |
std::string | Replace (std::string from, std::string to) |
void | Print () |
Private Member Functions | |
std::string | GetString (void) |
Private Attributes | |
std::string::size_type | fStartPos |
std::vector< std::string > | fStrings |
std::string | fInput |
std::string | fDelimiter |
std::string | fOutput |
bool | fFirstDel |
bool | fLastDel |
PndStringSeparator Version 1.0 by Tobias Stockmanns
Seperates an input string into substrings and stores them in a string vector. The seperation criteria is a string of characters. If no delimiters are given the default delimiter " " is used.
Example: std::vector<std::string> fOutput TPndStringVector fInput("Column:Row Type: Test ", ": "); fOutput = fInput.GetStringVector();
fOutput[0] = "Column" fOutput[1] = "Row" fOutput[2] = "Type" fOutput[3] = "Test"
Definition at line 30 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 30 of file PndStringSeparator.h
|
inline |
Definition at line 33 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 33 of file PndStringSeparator.h
|
inline |
Definition at line 34 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 34 of file PndStringSeparator.h
PndStringSeparator::PndStringSeparator | ( | std::string | AInput, |
std::string | ADelimiter = " " |
||
) |
Definition at line 6 of file PndStringSeparator.cxx.
View newest version in sPHENIX GitHub at line 6 of file PndStringSeparator.cxx
|
inline |
Definition at line 42 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 42 of file PndStringSeparator.h
References fFirstDel.
Referenced by Replace().
|
inline |
Definition at line 43 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 43 of file PndStringSeparator.h
References fLastDel.
Referenced by Replace().
|
private |
Definition at line 11 of file PndStringSeparator.cxx.
View newest version in sPHENIX GitHub at line 11 of file PndStringSeparator.cxx
References fDelimiter, fInput, fStartPos, and pos().
Referenced by GetStringVector().
std::vector< std::string > PndStringSeparator::GetStringVector | ( | void | ) |
Definition at line 35 of file PndStringSeparator.cxx.
View newest version in sPHENIX GitHub at line 35 of file PndStringSeparator.cxx
References fStartPos, fStrings, GetString(), ResetVector(), TestFirst(), TestLast(), and value.
Referenced by PndGeoHandling::DiveDownToFillSensNamePar(), PndFileNameCreator::GetFileName(), PndFileNameCreator::GetPath(), Replace(), PndFileNameCreator::TruncateFileName(), and PndFileNameCreator::TruncateInitial().
void PndStringSeparator::Print | ( | void | ) |
Definition at line 68 of file PndStringSeparator.cxx.
View newest version in sPHENIX GitHub at line 68 of file PndStringSeparator.cxx
References fInput, and fStrings.
Referenced by PndFileNameCreator::GetPath().
std::string PndStringSeparator::Replace | ( | std::string | from, |
std::string | to | ||
) |
Definition at line 51 of file PndStringSeparator.cxx.
View newest version in sPHENIX GitHub at line 51 of file PndStringSeparator.cxx
References fDelimiter, GetIfFirst(), GetIfLast(), GetStringVector(), and SetDelimiter().
|
inline |
Definition at line 38 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 38 of file PndStringSeparator.h
References fStrings.
Referenced by GetStringVector().
|
inline |
Definition at line 37 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 37 of file PndStringSeparator.h
References fDelimiter.
Referenced by Replace().
|
inline |
Definition at line 36 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 36 of file PndStringSeparator.h
References fInput.
|
inline |
Definition at line 40 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 40 of file PndStringSeparator.h
References fDelimiter, fFirstDel, and fInput.
Referenced by GetStringVector().
|
inline |
Definition at line 41 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 41 of file PndStringSeparator.h
References fDelimiter, fInput, and fLastDel.
Referenced by GetStringVector().
|
private |
Definition at line 51 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 51 of file PndStringSeparator.h
Referenced by GetString(), Replace(), SetDelimiter(), TestFirst(), and TestLast().
|
private |
Definition at line 54 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 54 of file PndStringSeparator.h
Referenced by GetIfFirst(), and TestFirst().
|
private |
Definition at line 50 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 50 of file PndStringSeparator.h
Referenced by GetString(), Print(), SetInput(), TestFirst(), and TestLast().
|
private |
Definition at line 55 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 55 of file PndStringSeparator.h
Referenced by GetIfLast(), and TestLast().
|
private |
Definition at line 52 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 52 of file PndStringSeparator.h
|
private |
Definition at line 48 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 48 of file PndStringSeparator.h
Referenced by GetString(), and GetStringVector().
|
private |
Definition at line 49 of file PndStringSeparator.h.
View newest version in sPHENIX GitHub at line 49 of file PndStringSeparator.h
Referenced by GetStringVector(), Print(), and ResetVector().