Logo Search packages:      
Sourcecode: condor version File versions  Download package

int MyString::FindChar ( int  Char,
int  FirstPos = 0 
) const

Returns the position at which a character is first found. Begins counting from FirstPos. Returns -1 if it's not found.

Definition at line 394 of file MyString.cpp.

Referenced by Job::declare_file(), EscapeChars(), and JobDisconnectedEvent::readEvent().

{
    if (!Data || FirstPos >= Len || FirstPos < 0) {
            return -1;
      }
    char* tmp = strchr(Data + FirstPos, Char);
    if (!tmp) {
            return -1;
      }
    return tmp-Data;
}


Generated by  Doxygen 1.6.0   Back to index