ROSE  0.11.98.0
Predicate.h
1 #ifndef ROSE_StringUtility_Predicate_H
2 #define ROSE_StringUtility_Predicate_H
3 
4 #include <rosedll.h>
5 
6 #include <string>
7 
8 namespace Rose {
9 namespace StringUtility {
10 
12 // Predicates
14 
18 inline bool isContainedIn(const std::string &longString, const std::string &shortString) {
19  return longString.find(shortString) != std::string::npos;
20 }
21 
25 ROSE_UTIL_API bool isLineTerminated(const std::string &s);
26 
27 } // namespace
28 } // namespace
29 
30 #endif
Main namespace for the ROSE library.
ROSE_UTIL_API bool isLineTerminated(const std::string &s)
Returns true if the string ends with line termination.
bool isContainedIn(const std::string &longString, const std::string &shortString)
Determines whether one string contains another.
Definition: Predicate.h:18