Storm
A Modern Probabilistic Model Checker
|
#include <string.h>
Public Member Functions | |
SimilarStrings (std::string reference, double similarityFactor=0.6, bool caseSensitive=true) | |
Gathers strings that are similar to the given reference string. | |
bool | isSimilar (std::string const &string) const |
bool | add (std::string const &string) |
Adds the given string to the set of similar strings (if it is similar) | |
std::vector< std::string > | toList () const |
Gets a list of all added strings that are similar to the reference string. | |
std::string | toDidYouMeanString () const |
Returns a "Did you mean abc?" string. | |
storm::utility::string::SimilarStrings::SimilarStrings | ( | std::string | reference, |
double | similarityFactor = 0.6 , |
||
bool | caseSensitive = true |
||
) |
Gathers strings that are similar to the given reference string.
reference | |
similarityFactor | controls how similar the strings need to be (0 means any string is similar, 1 means only the reference string is similar) |
caseSensitive | if false, lower/upper case is ignored |
Definition at line 8 of file string.cpp.
bool storm::utility::string::SimilarStrings::add | ( | std::string const & | string | ) |
Adds the given string to the set of similar strings (if it is similar)
Definition at line 18 of file string.cpp.
bool storm::utility::string::SimilarStrings::isSimilar | ( | std::string const & | string | ) | const |
Definition at line 13 of file string.cpp.
std::string storm::utility::string::SimilarStrings::toDidYouMeanString | ( | ) | const |
std::vector< std::string > storm::utility::string::SimilarStrings::toList | ( | ) | const |
Gets a list of all added strings that are similar to the reference string.
Definition at line 26 of file string.cpp.