checks if a fullString ends with a certain ending
| 442 | |
| 443 | /// checks if a fullString ends with a certain ending |
| 444 | bool StringEndsWith(const std::string& fullString, const std::string& ending) { |
| 445 | if (ending.size() > fullString.size()) return false; |
| 446 | return fullString.compare(fullString.size() - ending.size(), ending.size(), ending) == 0; |
| 447 | } |
| 448 | |
| 449 | /// <summary> |
| 450 | /// Check if file has a certain file extension (case insensitive) |