MCPcopy Create free account
hub / github.com/SmingHub/Sming / indexOf

Method indexOf

Sming/Core/Data/CStringArray.cpp:54–67  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

52}
53
54int CStringArray::indexOf(const char* str, bool ignoreCase) const
55{
56 for(auto it = begin(); it != end(); ++it) {
57 if(ignoreCase) {
58 if(it.equalsIgnoreCase(str)) {
59 return it.index();
60 }
61 } else if(it.equals(str)) {
62 return it.index();
63 }
64 }
65
66 return -1;
67}
68
69const char* CStringArray::getValue(unsigned index) const
70{

Callers 5

fromFileExtensionFunction · 0.45
fromStringFunction · 0.45
evaluateMethod · 0.45
getValueMethod · 0.45
getValueMethod · 0.45

Calls 3

indexMethod · 0.80
equalsIgnoreCaseMethod · 0.45
equalsMethod · 0.45

Tested by

no test coverage detected