MCPcopy Create free account
hub / github.com/apache/cloudberry / Find

Method Find

src/backend/gporca/libgpos/src/string/CWStringBase.cpp:134–149  ·  view source on GitHub ↗

--------------------------------------------------------------------------- @function: CWStringBase::Find @doc: Returns the index of the first occurrence of a character, -1 if not found ---------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

132//
133//---------------------------------------------------------------------------
134INT
135CWStringBase::Find(WCHAR wc) const
136{
137 const WCHAR *w_str = GetBuffer();
138 const ULONG length = Length();
139
140 for (ULONG i = 0; i < length; i++)
141 {
142 if (wc == w_str[i])
143 {
144 return i;
145 }
146 }
147
148 return -1;
149}
150
151
152//---------------------------------------------------------------------------

Callers 15

GetAttnoForColIdMethod · 0.45
CCTEListEntryMethod · 0.45
GetCTEProducerMethod · 0.45
AddCTEProducerMethod · 0.45
GetTargetEntryMethod · 0.45
ForEachFunction · 0.45
GetColIdMethod · 0.45
CopyRemapColIdMethod · 0.45

Calls

no outgoing calls